This is the mail archive of the java@gcc.gnu.org mailing list for the Java 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]

Re: Can't find method `setDSTSavings(I)' in type `java.util.SimpleTimeZone'.


Hi Michael,

Compiling with gcj (both 3.3.1 and 3.4.0) results in the following
error:
DSTTest.java: In class `DSTTest':
DSTTest.java: In method `DSTTest.main(java.lang.String[])':
DSTTest.java:7: error: Can't find method `setDSTSavings(I)' in type
java.util.SimpleTimeZone'.
                stz.setDSTSavings( dtsInMillis );
                      ^
1 error
And if I actually did the 3.4.0 build correct I would have seen that wasn't the case for 3.4.x... :-)

However, if I look into the SimpleTimeZone class in libgcj.jar, I
can see that it's actually there:
$ javap -classpath /usr/share/java/libgcj-3.3.1.jar
java.util.SimpleTimeZone | grep setDST
    public void setDSTSavings(int);
This method doesnt existed in 3.3.x, in 3.4.0 it does and it works here locally with 3.4 cvs branch. You get wrong results with javap because it investigates SUN classes and dont uses libgcj.jar.
Doh! Of course, I had to use javap with "bootclasspath" instead...
Lesson learned... :o)

Thanks,
 Martin



Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]