home.social

#gadt — Public Fediverse posts

Live and recent posts from across the Fediverse tagged #gadt, aggregated by home.social.

  1. Oh nice. Just found 2 #rustlang nightly features which look like they might bring us closer to one of the two major type level things Iam missing hard in #rust : "extistenia types" (the other one are #GADT)

    type_alias_impl_trait:
    doc.rust-lang.org/unstable-boo

    impl_trait_in_assoc_type:
    doc.rust-lang.org/nightly/unst

  2. Red-black tree in Lean 4 prover.

    I proved all needed properties, for example that resulting tree is sorted.

    I implemented one operation only: insertion. And I "cheat" by assuming that original tree is always black. My goal was not implementing everything, I just wanted to implement one simple operation and prove really everything about it.

    Proof of sorting (insert_sorted) turned out to be rather big. If someone knows how to make it smaller (possibly using mathlib), then, please, tell me that.

    rentry.co/8sfon8ez

    #types.pl #lean #plt #gadt

  3. react-book.melange.re/intro/
    I love .

    it has many superpowers
    - and with

    -
    -
    -
    -
    - pragmatic by default
    - pragmatic and optional laziness
    it gives confidence and correctness via type system and compiles
    shape languages like and also is just reincarnation of ocaml for dotnet
    Melange brings this power to developers.

  4. 🇫🇷 L'année passée, j'ai décris un usage du GADT `Eq` pour implémenter des méthodes gardées (et résoudre les méthodes `sum`, `prod` et `flatten`) en préservant la sémantique d'envoi de message !

    xvw.lol/pages/oop-refl.html

    N'hésitez pas à me faire des retours !
    #ocaml #gadt #oop

  5. It seems one can represent ZFC (or any other logic or type system) as Lean 3's GADT. Note that binder very elegantly represented as HOAS. Am I first who discovered this? #types.pl #plt #lean #lean3 #gadt #zfc #hoas

    lobste.rs/s/11k4ri/how_should_

  6. Implémenter des méthodes gardées en OCaml avec un témoin d'égalité explicite, un article de @xvw xvw.github.io/capsule/pages/oo #OCaml #OOP #GADT