3 ms·
> What's the point of having Nullables if we're still forced to do glorified if(*.isNull) ... else ... checks? I'd much rather use Scala's Option type that has
by gavinking 13y ago
> What's the point of having Nullables if we're still forced to do glorified if(*.isNull) ... else ... checks? I'd much rather use Scala's Option type that has Map and GetOrElse already baked in.
Sorry, but Option is just not better. One advantage of using a union type is that if I have a List<String?>, I just have a List<String|Null> (which maps to a plain List<String> at the JVM level) not a whole list of wrapper objects in a List<Option<String>>.
And of course Ceylon has sufficient syntax sugar so that you can write things like:
print(nameOrNull else "Gavin);
You definitely don't have to do an "if (exists...)" every time you encounter a null value.
> Also, the tooling around Scala is starting to mature. The Kotlins and Ceylons of the world are way behind Scala in this regard as well.
WDYM?! I strongly beg to differ. Have you seriously tried out Ceylon's IDE? Or are you just speculating?
- frowaway001 13y ago> I strongly beg to differ. Have you seriously tried out Ceylon's IDE? Or are you just speculating? He was probably just reading your own mailing list. Why speculate, if he can get the state of tooling right from the core developers? :-)
- gavinking 13y agoHeh, we'll have to post more commercials about how great we are, instead of always being so intensely self-critical ;-)
- lukaseder 13y agoI would agree to that. Given the excellent IDE support that is provided from the first release on, you have some killer platform there, quality-wise.