Ranter
Join devRant
Do all the things like
++ or -- rants, post your own rants, comment on others' rants and build your customized dev avatar
Sign Up
Pipeless API
From the creators of devRant, Pipeless lets you power real-time personalized recommendations and activity feeds using a simple API
Learn More
Comments
-
Snob20866yI considered learning Ocaml a few times... Is it really worth it? I heard that it is used in aviation in some places as a functional language.
-
sSam14836y@ganjaman pretty sure ocaml's json conversion code is a few thousand lines long too or does it use magic?
-
@wholl0p quickly becoming my favourite, worth picking up if you wanna substitute js with something sane
-
@sSam to be fair i didnt count typedef lines, but you have to write those anyway
-
Snob20866y@ganjaman I don't do JS, to be more precise: I hate JS.. But I love Python, may be a good addition or alternative. I'll have a look
-
sSam14836y@ganjaman I'm referring to your statement that in Java it's not one line because you have to include a library. Same is with Ocaml.
-
@sSam i dont really have to include yojson (thats the name btw, like 2k lines) to serialize a json string. I have to do it for other stuff, yeah but mapping a json to a hashtable in java would take a lot more, and making a general object would be really fucking long. Used java the past 4-5 years, i know what im talking about
-
sSam14836y@ganjaman you still have to use code, which is probably in standard library. It doesn't make much difference if it's in standard library or external one as it takes literally 1 minute to include a library in Java project.
Also you can parse json to object with a few lines?
Ocaml, the strictest language when it comes to types i have ever seen, parses a string to a general json object in around 5 loc.
Take notes java.
rant