Re: [kaffe] Should IllegalAccessException be thrown or not?

2005-12-20 Thread Ito Kazumitsu
From: Ito Kazumitsu <[EMAIL PROTECTED]> Date: Mon, 12 Dec 2005 13:21:59 +0900 (JST) > Sun's JDK (the test programs compiled with ecj): > > Call a private constructor in the same class > OK > Call a private constructor in the same pakeage > OK (*3) > Call a private constructor in another pakeage

Re: [kaffe] Should IllegalAccessException be thrown or not?

2005-12-11 Thread Ito Kazumitsu
From: Ito Kazumitsu <[EMAIL PROTECTED]> Date: Mon, 12 Dec 2005 15:21:26 +0900 (JST) > But I am afraid > >266 else if( (target->name->data[0] != '[') && >267 same_package && >268 (target->this_inner_index >= 0) ) >269 { >270

Re: [kaffe] Should IllegalAccessException be thrown or not?

2005-12-11 Thread Ito Kazumitsu
From: Ito Kazumitsu <[EMAIL PROTECTED]> Date: Mon, 12 Dec 2005 11:35:59 +0900 (JST) > kaffe/kaffevm/access.c has this code: > >261 else if( same_package && !(target_flags & ACC_PRIVATE) ) >262 { >263 /* Package. */ >264 slot_acc

Re: [kaffe] Should IllegalAccessException be thrown or not?

2005-12-11 Thread Ito Kazumitsu
From: Ito Kazumitsu <[EMAIL PROTECTED]> Date: Mon, 12 Dec 2005 11:35:59 +0900 (JST) > kaffe/kaffevm/access.c has this code: > >261 else if( same_package && !(target_flags & ACC_PRIVATE) ) >262 { >263 /* Package. */ >264 slot_acc

Re: [kaffe] Should IllegalAccessException be thrown or not?

2005-12-11 Thread Ito Kazumitsu
The test case attached below gives interesting results when run on various environments. It seems that kaffe, Sun's JDK, and ecj have some problem of their own. Kaffe: Call a private constructor in the same class OK Call a private constructor in the same pakeage OK (*1) Call a private constructor

Re: [kaffe] Should IllegalAccessException be thrown or not?

2005-12-11 Thread Ito Kazumitsu
From: Ito Kazumitsu <[EMAIL PROTECTED]> Date: Sun, 11 Dec 2005 10:51:52 +0900 (JST) > The next test case will illustrate this problem more clearly. > > $ cat A.java > public class A { > public static void main(String[] args) { > try { > B.getPrivateClass().newI

Re: [kaffe] Should IllegalAccessException be thrown or not?

2005-12-10 Thread Ito Kazumitsu
From: Ito Kazumitsu <[EMAIL PROTECTED]> Date: Sat, 10 Dec 2005 11:18:13 +0900 (JST) > public class TestPrivateClass { > private static class Test0001 { > } > > public static void main(String[] args) { > try { > Object obj = Test0001.class.newI

[kaffe] Should IllegalAccessException be thrown or not?

2005-12-09 Thread Ito Kazumitsu
From: Ito Kazumitsu <[EMAIL PROTECTED]> Subject: Re: [kaffe] ecj-compiled kaffe fails in regression tests Date: Fri, 09 Dec 2005 15:03:16 +0900 (JST) > Sun's JDK gives this (when DEBUG is set to true): > > Generating canonical stream > Serializing TestSerialFields$Test0001 > Exception: java