News for hackers. Stuff that matters.
Re:OCaml 4.10 by yawaramin on Saturday February 22, 2020 @09:19PM (#22394667)
> list comprehension

Are you referring to F#'s computation expressions? If so, OCaml has a similar-in-power let-syntax now: http://jobjo.github.io/2019/04/24/ocaml-has-some-new-shiny-s...

> Ocaml and F# can (for the most part) easily be transpiled into one another,

Actually they can't. They are quite different languages in practice.

Re:OCaml 4.10 by nestorD on Sunday February 23, 2020 @03:19AM (#22395749)
No, I am referring to proper list comprehensions (as you would get in python): https://en.wikibooks.org/wiki/F_Sharp_Programming/Lists#Usin...

Its true that you can't literaly transpile very high order things such as GADT but the was majority of code is trivial to translate as both syntax and available constructs match.

I practice, I found translations between the two languages to be fairly easy (the same cannot be said for most language pairs).

(I was not aware of the new let-syntax, thats a nice addition (although computation expression did not make my list as they are more of an enabler for library authors than normal users). I will dig in to see what people build around it...)

Re:OCaml 4.10 by yawaramin on Sunday February 23, 2020 @10:31AM (#22397259)
> I am referring to proper list comprehensions

Oh cool, I'd forgotten F# had those (or maybe it got them recently?).

> Its true that you can't literaly transpile very high order things such as GADT but the was majority of code is trivial to translate

Would still have to disagree there; OCaml code heavily relies on modules/module types/functors, while F# code relies more on classes. In practice these are not trivially translateable.

> I will dig in to see what people build around it...

The major thing is getting an async/await-like syntax for concurrent operations. Super useful for literally everyone. E.g. my project https://github.com/yawaramin/re-web/blob/eb7ce8474d34c60f9f9...