Re: Error handling without exceptions (was: Throwable)

2009-08-19 Thread John Rose
On Aug 19, 2009, at 1:27 PM, Helmut Eller wrote: > Is it possible to efficiently check the argument count and in case > of a > mismatch to call an error handler without unwinding the stack? You can build this sort of thing on top of the primitives supplied by JSR 292, but it doesn't need to b

Re: Throwable

2009-08-19 Thread John Rose
On Aug 19, 2009, at 3:54 AM, Raffaello Giulietti wrote: > Fortunately, the JVM doesn't know about checked exceptions. Let's hope > this will remain so even in the future. The Java language checks exceptions statically. The JVM doesn't. Neither of these facts will change in the foreseeable fut

Error handling without exceptions (was: Throwable)

2009-08-19 Thread Helmut Eller
Hello, I've been wondering if the java.dyn stuff will enable error handling which is not based on exceptions. For instance if a MethodHandle is called with the wrong number of arguments the current design seems to assume that throwing an exception is a sensible action to take. Throwing an except

Re: Throwable

2009-08-19 Thread Raffaello Giulietti
s with "292" in the title. > See for example this partial thread: > http://mail.openjdk.java.net/pipermail/coin-dev/2009-May/001647.html > > There's more there across several threads, sorry I don't have time to > filter it out, but basically, InvokeDynamic calls

Re: Throwable

2009-08-19 Thread Patrick Wright
example this partial thread: http://mail.openjdk.java.net/pipermail/coin-dev/2009-May/001647.html There's more there across several threads, sorry I don't have time to filter it out, but basically, InvokeDynamic calls from Java will be required to declare the Throwable. This also comes up in

Re: Throwable

2009-08-19 Thread Raffaello Giulietti
Charles Oliver Nutter wrote: > On Tue, Aug 18, 2009 at 6:29 AM, Raffaello > Giulietti wrote: >> The language compiler complains about an >> unreported exception Throwable; must be caught or declared to be thrown >> in using both InvokeDynamic and the (invisible) MethodHand

Re: Throwable

2009-08-18 Thread Charles Oliver Nutter
On Tue, Aug 18, 2009 at 6:29 AM, Raffaello Giulietti wrote: > The language compiler complains about an > unreported exception Throwable; must be caught or declared to be thrown > in using both InvokeDynamic and the (invisible) MethodHandle.invoke() > > Why is this so? > What a

Throwable

2009-08-18 Thread Raffaello Giulietti
The language compiler complains about an unreported exception Throwable; must be caught or declared to be thrown in using both InvokeDynamic and the (invisible) MethodHandle.invoke() Why is this so? What about an (unchecked) RuntimeException instead

hg: mlvm/mlvm/jdk: indy: implicit methods declare "throws Throwable"

2009-06-17 Thread john . rose
Changeset: a49af944ae8d Author:jrose Date: 2009-06-17 13:16 -0700 URL: http://hg.openjdk.java.net/mlvm/mlvm/jdk/rev/a49af944ae8d indy: implicit methods declare "throws Throwable" ! indy.patch ___ mlvm-dev mailing lis

Re: incompatible change coming in javac: invokedynamic calls will declare "throws Throwable"

2009-06-15 Thread Charles Oliver Nutter
hanging the implicit methods of > InvokeDynamic.foo and MethodHandle.invoke to include a static > declaration of "throws Throwable".  This aligns with the reality that > there is no framework of static checking for throws and catches that > applies to those calls; they are

hg: mlvm/mlvm: meth: implicit methods declare "throws Throwable"

2009-06-13 Thread john . rose
Changeset: 4a545756cc3d Author:jrose Date: 2009-06-12 23:59 -0700 URL: http://hg.openjdk.java.net/mlvm/mlvm/rev/4a545756cc3d meth: implicit methods declare "throws Throwable" ! netbeans/meth/test/jdk/java/dyn/MethodHandleBytecodeTest.java ! netbeans/meth/test/jd

hg: mlvm/mlvm/langtools: meth: implicit methods declare "throws Throwable"

2009-06-12 Thread john . rose
Changeset: 59a51c5edc25 Author:jrose Date: 2009-06-12 23:49 -0700 URL: http://hg.openjdk.java.net/mlvm/mlvm/langtools/rev/59a51c5edc25 meth: implicit methods declare "throws Throwable" + compile-error-tweak.patch ! meth.patch ! nb-javac/meth.patch ! nb-javac/ne

hg: mlvm/mlvm/jdk: meth: implicit methods declare "throws Throwable"

2009-06-12 Thread john . rose
Changeset: eeeae1443cc9 Author:jrose Date: 2009-06-12 23:49 -0700 URL: http://hg.openjdk.java.net/mlvm/mlvm/jdk/rev/eeeae1443cc9 meth: implicit methods declare "throws Throwable" ! indy.patch ___ mlvm-dev mailing lis

incompatible change coming in javac: invokedynamic calls will declare "throws Throwable"

2009-06-12 Thread John Rose
In response to comments on coin-...@openjdk.java.net about our proposed Java language changes, I am changing the implicit methods of InvokeDynamic.foo and MethodHandle.invoke to include a static declaration of "throws Throwable". This aligns with the reality that there is no fr