summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJason Peterson2013-08-23 12:35:55 (EDT)
committerChris Jaun2013-08-28 16:54:51 (EDT)
commit874834a756865b9d32ae15451fcc68eed34132d8 (patch)
tree69741e778e0ec738c92230fa0af7df52240933e6
parent57c5350ba96ed08268b2d066bfde3ee3a70733f3 (diff)
downloadwebtools.jsdt.tests-874834a756865b9d32ae15451fcc68eed34132d8.zip
webtools.jsdt.tests-874834a756865b9d32ae15451fcc68eed34132d8.tar.gz
webtools.jsdt.tests-874834a756865b9d32ae15451fcc68eed34132d8.tar.bz2
[326449] parser error on regular expression containing sequencev201308282108R3_5_1
Signed-off-by: Jason Peterson <jasonpet@us.ibm.com>
-rw-r--r--tests/org.eclipse.wst.jsdt.core.tests.compiler/src/org/eclipse/wst/jsdt/core/tests/compiler/parser/SyntaxErrorTest.java24
1 files changed, 24 insertions, 0 deletions
diff --git a/tests/org.eclipse.wst.jsdt.core.tests.compiler/src/org/eclipse/wst/jsdt/core/tests/compiler/parser/SyntaxErrorTest.java b/tests/org.eclipse.wst.jsdt.core.tests.compiler/src/org/eclipse/wst/jsdt/core/tests/compiler/parser/SyntaxErrorTest.java
index 678ed29..586f0d9 100644
--- a/tests/org.eclipse.wst.jsdt.core.tests.compiler/src/org/eclipse/wst/jsdt/core/tests/compiler/parser/SyntaxErrorTest.java
+++ b/tests/org.eclipse.wst.jsdt.core.tests.compiler/src/org/eclipse/wst/jsdt/core/tests/compiler/parser/SyntaxErrorTest.java
@@ -346,4 +346,28 @@ public void testWI106610() {
expectedSyntaxErrorDiagnosis,
testName);
}
+
+public void testRegExpression01() {
+ String s = "searchStr.replace( /([!\"#$%&'()*+,./:;<=>?@[\\]^`{|}~])/g, '//' )";
+ String expectedSyntaxErrorDiagnosis = "";
+ String testName = "<test>";
+
+ checkParse(
+ s.toCharArray(),
+ expectedSyntaxErrorDiagnosis,
+ testName);
+}
+
+public void testRegExpression02() {
+ String s = "searchStr.replace(/\\n( |\t)*[/][/]/g,'//')";
+ String expectedSyntaxErrorDiagnosis = "";
+ String testName = "<test>";
+
+ checkParse(
+ s.toCharArray(),
+ expectedSyntaxErrorDiagnosis,
+ testName);
+}
+
+
}