This is the mail archive of the
java@gcc.gnu.org
mailing list for the Java project.
Re: Patch to avoid SegFault in natClass.cc
- To: martin dot kahlert at infineon dot com
- Subject: Re: Patch to avoid SegFault in natClass.cc
- From: Bryce McKinlay <bryce at waitaki dot otago dot ac dot nz>
- Date: Tue, 17 Jul 2001 12:59:48 +1200
- CC: java-patches at gcc dot gnu dot org, apbianco at cygnus dot com, java at gcc dot gnu dot org
- References: <20010713110609.A27763@keksy.muc.infineon.com> <15182.48112.995173.464369@fencer.cygnus.com> <20010716101628.A6825@keksy.muc.infineon.com>
Martin Kahlert wrote:
> Can you tell me, what i have to do in order to get an uninitialized
> class for an instanceof test?
Try using the three-argument Class.forName() with a value of false for the
"initalize" parameter.
> I wildly mixed abstract classes with .class calls but i had no success.
>
> Is there a deeper reason at all, why the classloader should be allowed to return
> an uninitialized class? If not, the _Jv_InitClass would be superflous.
Probibly for performance reasons, say to be able to reflect on some random class
without actually running its <clinit> code.
regards
[ bryce ]