3 ms·
How is "opt-out option types" different from, say, Java, where everything is nullable and all the problems that come with that? Honest question, as I haven't h
by Arcsech 9y ago
How is "opt-out option types" different from, say, Java, where everything is nullable and all the problems that come with that?
Honest question, as I haven't had a chance to look into P6 as much as I would like. It looks pretty cool in a lot of ways, but I'm worried that all of the options available would create a confusing mess.
> Note that the author of the OP is well known in the Erlang community.
Yeah, my comment was directed at the parent who asked:
> I don't understand how some other language would not need to handle all the errors ?
And was intending to give a brief description of how other languages (possibly including P6, though I don't have the experience to say) handle errors differently from the languages they listed (go/java/php/python/js).
- raiph 9y ago> How is "opt-out option types" different from, say, Java, where everything is nullable and all the problems that come with that? Aiui the Java compiler and language constructs generally don't know the difference. The P6 Nothing isn't a null, it's a "type object" with memory- and type- safe behavior. There's a tiny bit more about this at: https://en.wikipedia.org/wiki/Option_type#Perl_6 https://en.wikipedia.org/wiki/Option_type#Perl_6