This is the mail archive of the kawa@sources.redhat.com mailing list for the Kawa project.
| Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
|---|---|---|
| Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |
| Other format: | [Raw text] | |
Jim White wrote:
That to me looks like a bug in java.util.Hashtable, not Kawa ...
Actually that NPE is a null key parameter to Hashtable.get.
My point was that the specification Hashtable.get does not specify any "throws" nor does it say that null is disallowed. Of course Sun no longer believes in specification: The implementtion is the specification. (Sun people have told me this.)
A side note on the initialization of the mapNameToType static in Type. Using a static initializer would eliminate the null check and provide class loading synchronization for free.
That may be reasonable. I prefer to defer unneeded initialization, but that may make synchronization difficult. (There some example of "double-locking" in Kawa, which I now read is consider a dubious idiom.)
| Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
|---|---|---|
| Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |