Created
August 4, 2016 05:31
-
-
Save gurinderu/763a3da97ef781e07a5699648ee57b52 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class @ExceptionOne : @java.lang.RuntimeException | |
def @ExceptionOne::init_class.java.lang.String : (class @ExceptionOne, class @java.lang.String) => unit { | |
%src.2(%src.0: class @ExceptionOne, %src.1: class @java.lang.String): | |
%src.3 = call[(class @java.lang.RuntimeException, class @java.lang.String) => unit] @java.lang.RuntimeException::init_class.java.lang.String(%src.0: class @ExceptionOne, %src.1: class @java.lang.String) | |
ret unit | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class @ExceptionTwo : @java.lang.RuntimeException | |
def @ExceptionTwo::init_class.java.lang.String : (class @ExceptionTwo, class @java.lang.String) => unit { | |
%src.2(%src.0: class @ExceptionTwo, %src.1: class @java.lang.String): | |
%src.3 = call[(class @java.lang.RuntimeException, class @java.lang.String) => unit] @java.lang.RuntimeException::init_class.java.lang.String(%src.0: class @ExceptionTwo, %src.1: class @java.lang.String) | |
ret unit | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
pin(@Test$::init) module @Test$ : @java.lang.Object | |
def @Test$::throw1_nothing : (module @Test$) => nothing { | |
%src.1(%src.0: module @Test$): | |
%src.2 = module @scala.Predef$ | |
%src.3 = method[(module @scala.Predef$, class @java.lang.Object) => unit] %src.2: module @scala.Predef$, @scala.Predef$::println_class.java.lang.Object_unit | |
%src.4 = call[(module @scala.Predef$, class @java.lang.Object) => unit] %src.3: ptr(%src.2: module @scala.Predef$, "ex1") | |
%src.5 = classalloc @ExceptionOne | |
%src.6 = call[(class @ExceptionOne, class @java.lang.String) => unit] @ExceptionOne::init_class.java.lang.String(%src.5: class @ExceptionOne, "abc") | |
throw %src.5: class @ExceptionOne | |
} | |
def @Test$::throw2_nothing : (module @Test$) => nothing { | |
%src.1(%src.0: module @Test$): | |
%src.2 = module @scala.Predef$ | |
%src.3 = method[(module @scala.Predef$, class @java.lang.Object) => unit] %src.2: module @scala.Predef$, @scala.Predef$::println_class.java.lang.Object_unit | |
%src.4 = call[(module @scala.Predef$, class @java.lang.Object) => unit] %src.3: ptr(%src.2: module @scala.Predef$, "ex2") | |
%src.5 = classalloc @ExceptionTwo | |
%src.6 = call[(class @ExceptionTwo, class @java.lang.String) => unit] @ExceptionTwo::init_class.java.lang.String(%src.5: class @ExceptionTwo, "123") | |
throw %src.5: class @ExceptionTwo | |
} | |
def @Test$::main_class.ssnr.ObjectArray_unit : (module @Test$, class @scala.scalanative.runtime.ObjectArray) => unit { | |
%src.2(%src.0: module @Test$, %src.1: class @scala.scalanative.runtime.ObjectArray): | |
try succ %src.6 catch fail %src.9 | |
%src.6: | |
%src.7 = method[(module @Test$) => nothing] %src.0: module @Test$, @Test$::throw2_nothing | |
%src.8 = call[(module @Test$) => nothing] %src.7: ptr(%src.0: module @Test$) | |
jump %src.3(%src.8: nothing) | |
%src.9(%src.4: {ptr, i32}): | |
%src.10 = extract %src.4: {ptr, i32}, 0 | |
%src.11 = bitcast[ptr] %src.10: ptr | |
%src.12 = load[class @java.lang.Object] %src.11: ptr | |
%src.13 = is[class @ExceptionOne] %src.12: class @java.lang.Object | |
if %src.13: bool then %src.16 else %src.23 | |
%src.16: | |
%src.17 = as[class @ExceptionOne] %src.12: class @java.lang.Object | |
%src.18 = call[(ptr) => ptr] @scalanative_begin_catch(%src.10: ptr) | |
%src.19 = module @scala.Predef$ | |
%src.20 = method[(module @scala.Predef$, class @java.lang.Object) => unit] %src.19: module @scala.Predef$, @scala.Predef$::println_class.java.lang.Object_unit | |
%src.21 = call[(module @scala.Predef$, class @java.lang.Object) => unit] %src.20: ptr(%src.19: module @scala.Predef$, "catch ex1") | |
%src.22 = call[() => void] @scalanative_end_catch() | |
jump %src.14(%src.21: unit) | |
%src.23: | |
resume %src.4: {ptr, i32} | |
%src.14(%src.15: unit): | |
jump %src.3(%src.15: unit) | |
%src.3(%src.5: unit): | |
ret %src.5: unit | |
} | |
def @Test$::init : (module @Test$) => unit { | |
%src.1(%src.0: module @Test$): | |
%src.2 = call[(class @java.lang.Object) => unit] @java.lang.Object::init(%src.0: module @Test$) | |
ret unit | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment