From 7ae62f9936304331fccc8688c2873d3223c349e0 Mon Sep 17 00:00:00 2001 From: Alexey Andreev Date: Sun, 19 Oct 2014 19:23:18 +0400 Subject: [PATCH 1/4] Upgrade to version 0.2.1 --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 35bc3d9e0..8a017b1a5 100644 --- a/README.md +++ b/README.md @@ -28,7 +28,7 @@ The easiest way to create a new TeaVM project is to type in the command line: mvn -DarchetypeCatalog=local \ -DarchetypeGroupId=org.teavm \ -DarchetypeArtifactId=teavm-maven-webapp \ - -DarchetypeVersion=0.2.0 archetype:generate + -DarchetypeVersion=0.2.1 archetype:generate Now you can execute `mvn clean package` and get the generated `war` file. Deploy this `war` in Tomcat or another container, or simply unzip it and open the `index.html` page. From b151f709ee0b11bcc6ebec9dcea9196eb0fa0322 Mon Sep 17 00:00:00 2001 From: Alexey Andreev Date: Mon, 20 Oct 2014 00:31:28 +0400 Subject: [PATCH 2/4] Add feedback section to readme --- README.md | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/README.md b/README.md index 8a017b1a5..a56f09025 100644 --- a/README.md +++ b/README.md @@ -68,3 +68,9 @@ Another example is avaialble [here](http://graphhopper.com/teavm/). It uses [GraphHopper](https://github.com/graphhopper/graphhopper/) to build route in browser. Unlike original GraphHopper example it works completely in browser instead of querying server. Thanks to [Peter Karich](https://github.com/karussell). + + +Feedback +-------- + +Ask your questions by email: info@teavm.org. Also you can report issues on a project's [issue tracker](https://github.com/konsoletyper/teavm/issues). From 4a3e11d1af52cf098812612b7c43852523f14514 Mon Sep 17 00:00:00 2001 From: Alexey Andreev Date: Wed, 22 Oct 2014 22:49:47 +0400 Subject: [PATCH 3/4] Add test case for https://github.com/konsoletyper/teavm/issues/27 --- .../java/org/teavm/classlib/java/lang/VMTest.java | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/teavm-classlib/src/test/java/org/teavm/classlib/java/lang/VMTest.java b/teavm-classlib/src/test/java/org/teavm/classlib/java/lang/VMTest.java index a8963c000..bc77f5f6b 100644 --- a/teavm-classlib/src/test/java/org/teavm/classlib/java/lang/VMTest.java +++ b/teavm-classlib/src/test/java/org/teavm/classlib/java/lang/VMTest.java @@ -83,4 +83,17 @@ public class VMTest { public void surrogateInStringLiteralsWork() { assertEquals(0xDDC2, "a\uDDC2b".charAt(1)); } + + @Test + public void separatesExceptionAndVariable() { + int n = foo(); + try { + bar(); + } catch (RuntimeException e) { + assertEquals(RuntimeException.class, e.getClass()); + assertEquals(2, n); + } + } + private int foo() { return 2; } + private void bar() { throw new RuntimeException(); } } From 9bdd2f602058e090fcb02314928fee083141e64b Mon Sep 17 00:00:00 2001 From: konsoletyper Date: Sat, 25 Oct 2014 13:20:41 +0400 Subject: [PATCH 4/4] Fix https://github.com/konsoletyper/teavm/issues/27 --- .../java/org/teavm/model/util/InterferenceGraphBuilder.java | 3 +++ 1 file changed, 3 insertions(+) diff --git a/teavm-core/src/main/java/org/teavm/model/util/InterferenceGraphBuilder.java b/teavm-core/src/main/java/org/teavm/model/util/InterferenceGraphBuilder.java index e39480eaf..1ef421e12 100644 --- a/teavm-core/src/main/java/org/teavm/model/util/InterferenceGraphBuilder.java +++ b/teavm-core/src/main/java/org/teavm/model/util/InterferenceGraphBuilder.java @@ -41,6 +41,9 @@ class InterferenceGraphBuilder { for (BasicBlock succ : succExtractor.getTargets()) { liveOut.or(liveness.liveIn(succ.getIndex())); } + for (TryCatchBlock tryCatch : block.getTryCatchBlocks()) { + liveOut.or(liveness.liveIn(tryCatch.getHandler().getIndex())); + } live.clear(); for (int j = 0; j < liveOut.length(); ++j) { if (liveOut.get(j)) {