[ nice-Bugs-1222848 ] Illegal package name accepted by nicec
"SourceForge.net" <[email protected]> Sun, 25 Nov 2007 10:04:11 -0800
| Newsgroups | gmane.comp.lang.nice.devel |
|---|---|
| Message-ID | <[email protected]> |
Bugs item #1222848, was opened at 2005-06-17 20:57
Message generated for change (Comment added) made by bonniot
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=112788&aid=1222848&group_id=12788
Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: None
Group: None
>Status: Closed
>Resolution: Fixed
Priority: 5
Private: No
Submitted By: Ross Bamford (roscopeco)
Assigned to: Nobody/Anonymous (nobody)
Summary: Illegal package name accepted by nicec
Initial Comment:
The Nice compiler is accepting illegal package names containing hyphen
(-) characters. This is illegal according to the JVM spec. The compilation
works fine, but the resulting classes generate a ClassFormatException.
run:
[java] Exception in thread "main" java.lang.ClassFormatError: Method
"thingLevel" in class blank-nice/fun has illegal signature "blank-nice/
AnotherThing;)Ljava/lang/String;"
[java] at java.lang.ClassLoader.defineClass1(ClassLoader.java)
[java] at java.lang.ClassLoader.defineClass(ClassLoader.java:620)
[java] at java.security.SecureClassLoader.
defineClass(SecureClassLoader.java:124)
[java] at java.net.URLClassLoader.defineClass(URLClassLoader.java:
260)
[java] at java.net.URLClassLoader.access$100(URLClassLoader.
java:56)
[java] at java.net.URLClassLoader$1.run(URLClassLoader.java:195)
[java] at java.security.AccessController.
doPrivileged(AccessController.java)
[java] at java.net.URLClassLoader.findClass(URLClassLoader.java:
188)
[java] at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
[java] at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.
java:268)
[java] at java.lang.ClassLoader.loadClass(ClassLoader.java:251)
[java] at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:
319)
[java] at blank-nice.dispatch.main(Unknown Source)
The cause is obvious. Additionally, nice does not require package name
to match directory name, although I am not sure it should?
=== VERSIONS ===
[...@...]$ java -version
java version "1.5.0"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.5.0-b64)
Java HotSpot(TM) Client VM (build 1.5.0-b64, mixed mode, sharing)
[...@...]$ nicec --version
Nice compiler version 0.9.10 (build 2005.02.25, 16:35:29 UTC)
Compiled using JDK 1.4.2_04
Copyright (C) 2003 Daniel Bonniot
Visit the Nice homepage: http://nice.sourceforge.net
----------------------------------------------------------------------
>Comment By: Daniel Bonniot (bonniot)
Date: 2007-11-25 19:04
Message:
Logged In: YES
user_id=88952
Originator: NO
As far as I can see this is fixed.
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=112788&aid=1222848&group_id=12788
-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2005.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/