C# -- the Java killer?

Kevin Smathers ks@micky.rgv.hp.com
Tue Jun 27 09:02:00 GMT 2000


On Mon, Jun 26, 2000 at 09:10:03PM -0700, mdw@cs.berkeley.edu wrote:
>> "Nic Ferrier" <nferrier@tapsellferrier.co.uk> writes:
> > >Overall it's a nice language -- 
> > 
> > Can't say I agree with you.
>> Let the flamewars begin! :-)
>> > 3. Same object map as Java
> > Which we all know is pants. That's why we're adding paramaterized
> > types to Java. You'd have thought MS would have learned from this. If
> > C# had parameterized types I'd seriously consider it.
>> Well, remember that not everyone thinks that parameterized types are
> a good idea.

The lack of typesafe collections is an annoyance in Java (as well as
having to downcast every reference you get back from a general collection),
but C++ style type safety is terribly expensive in causing code to be
reinstantiated for every new type that you declare.
A mixture of the two (implementation based on inheritance, but typesafety
from a compilation perspective) would suit me well. I certainly don't
have the patience to declare a new adapter class for each container.
>> > 4. "unsafe" memory areas
> > You bet! GC performance will presumably degrade at some balance of
> > "unsafe" to GCed.
>> True, but the same issue applies to JNI.
>
At one of the Javaone sessions they announced a similar extension for
Java. The Java extension was to declare certain memory regions 'immortal'
and therefor not subject to automatic GC. (In their case the extension
was added for support of real-time programming so that methods that use
only immortal data can reliably preempt the GC thread.)
Cheers,
-kls


More information about the Java mailing list

AltStyle によって変換されたページ (->オリジナル) /