diff options
author | Olivier Thomann | 2005-11-23 17:15:57 +0000 |
---|---|---|
committer | Olivier Thomann | 2005-11-23 17:15:57 +0000 |
commit | c6ea2a72647dce31af35c91712fb9d7b45a7c96d (patch) | |
tree | 6979a911c9d89cab10827c3803282432ae52ea2f /org.eclipse.jdt.core.tests.compiler/src/org/eclipse/jdt/core | |
parent | 8970b012a4c030df2da75433f5a255c033afe448 (diff) | |
download | eclipse.jdt.core-c6ea2a72647dce31af35c91712fb9d7b45a7c96d.tar.gz eclipse.jdt.core-c6ea2a72647dce31af35c91712fb9d7b45a7c96d.tar.xz eclipse.jdt.core-c6ea2a72647dce31af35c91712fb9d7b45a7c96d.zip |
HEAD - Fix for 117495
Diffstat (limited to 'org.eclipse.jdt.core.tests.compiler/src/org/eclipse/jdt/core')
-rw-r--r-- | org.eclipse.jdt.core.tests.compiler/src/org/eclipse/jdt/core/tests/compiler/regression/ConstantTest.java | 27 |
1 files changed, 27 insertions, 0 deletions
diff --git a/org.eclipse.jdt.core.tests.compiler/src/org/eclipse/jdt/core/tests/compiler/regression/ConstantTest.java b/org.eclipse.jdt.core.tests.compiler/src/org/eclipse/jdt/core/tests/compiler/regression/ConstantTest.java index 31986ec731..ff042cef3c 100644 --- a/org.eclipse.jdt.core.tests.compiler/src/org/eclipse/jdt/core/tests/compiler/regression/ConstantTest.java +++ b/org.eclipse.jdt.core.tests.compiler/src/org/eclipse/jdt/core/tests/compiler/regression/ConstantTest.java @@ -1374,6 +1374,33 @@ public void test016() { assertTrue(false); } } +//http://bugs.eclipse.org/bugs/show_bug.cgi?id=117495 +public void test017() { + this.runConformTest( + new String[] { + "X.java", + "public class X {\n" + + " public static void main(String[] args) {\n" + + " int x = 2;\n" + + " System.out.println(\"n: \"+(x > 1 ? 2 : 1.0));\n" + + " }\n" + + "}", + }, + "n: 2.0"); +} +//http://bugs.eclipse.org/bugs/show_bug.cgi?id=117495 +public void test018() { + this.runConformTest( + new String[] { + "X.java", + "public class X {\n" + + " public static void main(String[] args) {\n" + + " System.out.println(\"n: \"+(true ? 2 : 1.0));\n" + + " }\n" + + "}", + }, + "n: 2.0"); +} public static Class testClass() { return ConstantTest.class; } |