--- "Craig R. McClanahan" <[EMAIL PROTECTED]> wrote:
> My understanding is that this is exactly what you'll get from the
> auto-unboxing capability. The compiler will be able to see that the right
> hand side returns a Double, and generate the code to unbox it into a
> double primitive for you.
>
> This is separate from Generics because it also works in other scenarios:
>
> Double d1 = new Double(1.0); // A lowly scalar instance of the wrapper
> double d2 = d1; // But no cast here either!
> d1 = d2 + 0.5; // Or here ... it is bidirectional
IMO, that's even more useful than generics (or limited C++-style templates, if
you prefer to think of them that way). As a math-using person, I really never
wanted to have to make much of a distinction between a double and a Double
(although I somewhat understand the CS considerations that could make having
the distinction desirable).
Al
=====
Albert Davidson Chou
Get answers to Mac questions at http://www.Mac-Mgrs.org/ .
__________________________________
Do you Yahoo!?
SBC Yahoo! DSL - Now only $29.95 per month!
http://sbc.yahoo.com
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]