You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@harmony.apache.org by "Alexey Varlamov (JIRA)" <ji...@apache.org> on 2007/05/15 07:57:16 UTC

[jira] Closed: (HARMONY-1857) [drlvm][jit] VM does not throw NoClassDefFoundError if class declares method as "throws exception" and there is no this exception class implementation (Jitrino OPT)

     [ https://issues.apache.org/jira/browse/HARMONY-1857?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Alexey Varlamov closed HARMONY-1857.
------------------------------------

    Resolution: Fixed
      Assignee: Alexey Varlamov

I've already added regtest for this in Feb 2007, just closing now.

> [drlvm][jit] VM does not throw NoClassDefFoundError if class declares method as "throws  exception" and there is no this exception class implementation (Jitrino OPT)
> ---------------------------------------------------------------------------------------------------------------------------------------------------------------------
>
>                 Key: HARMONY-1857
>                 URL: https://issues.apache.org/jira/browse/HARMONY-1857
>             Project: Harmony
>          Issue Type: Bug
>          Components: DRLVM
>         Environment: Linux IA-32, Windows IA-32
>            Reporter: Irina Arkhipets
>         Assigned To: Alexey Varlamov
>         Attachments: test.java
>
>
> If some class declares method as "throws  exception" and there is no implementation of this exception class then VM does not throw NoClassDefFoundError correctly  when it tries to create the instance of this class.
> This bug is reproducible with opt and server_static modes only.
> This bug is not reproducible with interpreter, jet, client and server.
> The following test example demonstrates the bug:
> --------- test.java ---------
> public class test {
>     public static void main(String [] args) {
>         try {
>             new TestClass();
>             System.out.println("FAILED");
>         } catch (NoClassDefFoundError e) {
>             System.out.println("PASSED");
>         }
>     }
> }
> class MyThrowable extends Throwable {}
> class TestClass {
>     public void run() throws MyThrowable {}
>     public void tryMe() {
>         try {
>             run();
>         } catch (MyThrowable e) {}
>     }
> }
> -------------------------------
> Please, do the following steps to reproduce the failure:
> 1. Compile test.java source using JDK1.5.0 javac
> 2. Remove MyThrowable.class file from the working directory
> 3. Run the test with "-Xem:opt" switch ("java -Xem:opt test")
> Sample output is:
> ...
> FAILED
> ...

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.