From: James F. <Ja...@we...> - 2002-06-18 07:27:51
|
Hi, Below is what the java tools docs say regarding assertions.=20 "-source release Enables support for compiling source code containing assertions. When release is set to 1.4, the compiler accepts code containing = assertions. Assertions were introduced in J2SE 1.4. When release is set to 1.3, the compiler does not support = assertions. The compiler defaults to the 1.3 behavior if the=20 -source flag is not used. " However, you don't seem to be using the -source flag so it claims that = in that case it should default to 1.3 behaviour. If it doesn't trying to = force it might work. If it compiled before 1.4 then they must've only = reserved the assert keyword in 1.4(many of their keywords have been reserved but not implemented = previously). If '-source 1.3' doesn't work then I'm out of ideas sorry. James. > --__--__-- >=20 > Message: 9 > From: "Ryan Morillo" <sr...@op...> > To: jyt...@li... > Date: Thu, 13 Jun 2002 17:06:10 +0800 > Subject: [Jython-users] Sun SDK 1.4.0_01 and jythonc >=20 > =20 > Well, I have found a major (I think actually minor, but I=20 > don't know enough to fix it) issue with Jython and the new=20 > SDK from Sun (J2SDK1.4.0-01). It stops jythonc because=20 > "assert" is now a keyword. >=20 > Windows NT4.x > Jython_2.1 > J2SDK1.4.0-01 >=20 > Here is the begining of the compiler output: > Creating .java files: > jrolo module >=20 > Compiling .java to .class... > Compiling with args: ['D:\\j2sdk1.4.0_01\\bin\\javac',=20 > '-deprecation', '-classpath',=20 > 'C:\\WINNT\\Profiles\\rmorillo\\jython-2.1\\jython.jar;;.\\jpy > work;;C:\\WINNT\\Profiles\\rmorillo\\jython-2.1\\Tools\\jython > c;C:\\WINNT\\Profiles\\rmorillo\\jython-2.1\\.;C:\\WINNT\\Prof > iles\\rmorillo\\jython-2.1\\Lib;C:\\WINNT\\Profiles\\rmorillo\ > \jython-2.1', '.\\jpywork\\jrolo.java'] >=20 > 0 =20 > C:\WINNT\Profiles\rmorillo\jython-2.1\.\org\python\core\Py.jav > a:989: warning: as of release 1.4, assert is a keyword, and=20 > may not be used as an identifier public static void=20 > assert(PyObject test, PyObject message) { > ^ > if someone could tell me how to change this or submit a diff=20 > it would be greatly appreciated. > --=20 > _______________________________________________ > Download the free Opera browser at http://www.opera.com/ >=20 > Powered by Outblaze >=20 >=20 |