I don't see that as a reason that holds water at all.  If the feature
is good and useful in Java code, there's no reason not to use it in
Java code.  Whether it's in the core isn't interesting at all, but if
there's a crippled version in the core that's a shame, as users of a
better version might end up always converting between Optional and
Option, or simply between Optional and Iterable, to get stuff done.

Not everyone who knows what Option is and wants to use it has a choice
over what language gets used.  Consider developing a library for use
by Java developers, if you write that library in Scala the users will
see classes whose names end in $ even if you're quite conservative
about the Scala features you use.

On Thu, Oct 25, 2012 at 11:00 AM, clay <[email protected]> wrote:
> On Thursday, October 25, 2012 5:48:30 AM UTC-5, Mario Fusco wrote:
>>
>> ... if Java 8 wants really do a step toward the functional world, I
>> honestly don't see why such a fundamental (and let me say trivial) thing
>> like an Option (and possibly an Either) shouldn't be available in the core
>> Java.
>
>
> I can give one extremely good reason that Java shouldn't have Option:
>
> Java is the JVM language that caters to those who demand more backward
> compatability and something more traditional and familiar, and has tons of
> legacy code and libraries already built around null, while those who demand
> more high level elegance and abstraction, such as Option, have Scala.
>
> Microsoft does the same thing with .NET: F# is the language that caters to
> those that demand more high level elegance and abstraction, while C# is
> their more traditional language. Microsoft added Option to F#, and
> purposefully did not add it to C#.
>
> If you take Option so seriously and are on the JVM, why not fully switch
> over to Scala?
>

-- 
You received this message because you are subscribed to the Google Groups "Java 
Posse" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/javaposse?hl=en.

Reply via email to