Re: [openjava-support] Overzealous attempts to resolve types?
Status: Beta
Brought to you by:
tatsubori
From: Michiaki T. <TA...@jp...> - 2003-11-09 22:42:35
|
Michael, You are on the sane way. Unfortunately, such error suppression is not yet supported in OpenJava. We should be able to do this by overriding OJClass.resolveError() or something. Thanks for your suggestion and I am going to provide it in OpenJava later (not in this week, sorry). Mich - Michiaki (Mich) Tatsubori, PhD. mi...@ac... IBM Tokyo Research Laboratory Michael Jarrett <msj...@uw...> Sent by: ope...@li... 2003/11/10 07:18 To: ope...@li... cc: Subject: [openjava-support] Overzealous attempts to resolve types? Hey all. Rather new to OpenJava, hope someone can give me some advice on this. (OpenJava Compiler Version 1.1 build 20030618) I am trying to write a metaclass to reproduce a method for a number of primitive types. Unfortunately, in the case of method parameters, the types are attempted to be resolved a bit too early, producing error messages both in initializing the parse tree and during my translateDefinition. For the latter, it appears for some strange reason that OJClass.removeMethod requires the ability to resolve the method parameter's types? None of this is a problem for the return type, which I suppose gets recognized as a keyword, or is not checked as often? In the end, it still generates the output correctly, but the errors are annoying. The errors are shown below. Is there a sane way in general to translate code where members/fields/ parameters/types are missing or invalid until after translateDefinition? Cheers, Michael Jarrett University of Waterloo Generating parse tree. ..done. Initializing parse tree. VariableBinder.bindName() openjava.mop.OJClassNotFoundException: typename : typename ClosedEnvironment class object table : {} binding table : {} parent env : ClassEnvironment class : blah member classes : [] parent env : FileEnvironment package : null main class : blah local classes : imported classes : imported packages : java.lang ca.uwaterloo.ece750.meta local class table : {} parent env : FileEnvironment package : null main class : blah local classes : imported classes : imported packages : java.lang ca.uwaterloo.ece750.meta local class table : {} parent env : GlobalEnvironment class object table : {char=char, long=long, ca.uwaterloo.ece750.meta.PrimitiveTemplate=class ca.uw aterloo.ece750.meta.PrimitiveTemplate, float=float, short=short, void=void, int=int, blah=class bl ah, java.lang.Object=class java.lang.Object, <type>null=<type>null, double=double, java.lang.Strin g=class java.lang.String, boolean=boolean, byte=byte} ..done. Translating callee side getTypename templated! OJClass.forNameAnyway() failed for : typename openjava.mop.OJClassNotFoundException: typename ClassEnvironment class : blah member classes : [] parent env : FileEnvironment package : null main class : blah local classes : imported classes : imported packages : java.lang ca.uwaterloo.ece750.meta local class table : {} parent env : GlobalEnvironment class object table : {char=char, long=long, ca.uwaterloo.ece750.meta.PrimitiveTemplate=class ca.uw aterloo.ece750.meta.PrimitiveTemplate, float=float, short=short, void=void, java.lang.System=class java.lang.System, int=int, blah=class blah, java.lang.Object=class java.lang.Object, java.lang.St ring[]=class java.lang.String[], <type>null=<type>null, double=double, java.lang.String=class java .lang.String, boolean=boolean, byte=byte} ------------------------------------------------------- This SF.Net email sponsored by: ApacheCon 2003, 16-19 November in Las Vegas. Learn firsthand the latest developments in Apache, PHP, Perl, XML, Java, MySQL, WebDAV, and more! http://www.apachecon.com/ _______________________________________________ openjava-support mailing list ope...@li... https://lists.sourceforge.net/lists/listinfo/openjava-support |