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

[Bug java/21115] false boolean argument passed from pre-compiled to interpreted method is true


------- Additional Comments From daney at gcc dot gnu dot org  2005-04-19 22:55 -------
Replacing Test.java with this seems to work:

import java.lang.reflect.*;

public abstract class Test
 {
   public static void main(String[] args) throws Exception
   {
     Class c = Class.forName("Invoke");
     Method m = c.getMethod ("test", new Class[]{String.class, Boolean.TYPE});
     Object o = c.newInstance();

     Object r = m.invoke(o, new Object[] {"FALSE", Boolean.FALSE});

     System.out.println("false == " + r);

     r = m.invoke(o, new Object[] {"TRUE", Boolean.TRUE});

     System.out.println("true == " + r);
   }
   public abstract boolean test(String s, boolean b);
 }

My tests were with 3.4.2 

-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=21115


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