Hey @seliopou, do you think you could help me understand polymorphic variants in OCaml? I struggle with the typing rules on open vs. closed
-
-
@FrancescoC@czaplic@avsm regular variants are closed type a = A | B poly variants are "stuck" with the a, can make them on the fly:like 'A -
@FrancescoC@czaplic I went over them at SF OCaml meetup in Jan, can do it again at next meetup -
@EdgarArout I get the idea, need to talk specifics. Interested in the particulars of the typing rules you'd use to gen type constraints -
@EdgarArout https://realworldocaml.org/v1/en/html/variants.html#polymorphic-variants … makes sense, but I'd like to see rules like "matching on `Tag produces constraint C". Is there a paper? - End of conversation
New conversation -
Loading seems to be taking a while.
Twitter may be over capacity or experiencing a momentary hiccup. Try again or visit Twitter Status for more information.