Fix a bug found during review.
authormarkt <markt@13f79535-47bb-0310-9956-ffa450edef68>
Sun, 10 Jan 2010 12:47:49 +0000 (12:47 +0000)
committermarkt <markt@13f79535-47bb-0310-9956-ffa450edef68>
Sun, 10 Jan 2010 12:47:49 +0000 (12:47 +0000)
Whilst the old version is what is defined in the spec, the definition in the spec does not agree with the description and associatedcomments in the spec. I have raised this as https://uel.dev.java.net/issues/show_bug.cgi?id=10
Modify the parser on the basis that the textual description and comments in the spec are correct and the production for StringLiteral is wrong

git-svn-id: https://svn.apache.org/repos/asf/tomcat/trunk@897629 13f79535-47bb-0310-9956-ffa450edef68

java/org/apache/el/parser/ELParser.jjt

index d3c0f17..9bd62b5 100644 (file)
@@ -383,9 +383,9 @@ void Null() #Null : {}
     >
 |    < #EXPONENT: ["e","E"] (["+","-"])? (["0"-"9"])+ >
 |    < STRING_LITERAL: ("\"" ((~["\"","\\"])
-        | ("\\" ( ["\\","\""] )))* "\"")
+        | ("\\" ( ["\\","\"","\'"] )))* "\"")
         | ("\'" ((~["\'","\\"])
-        | ("\\" ( ["\\","\'"] )))* "\'")
+        | ("\\" ( ["\\","\"","\'"] )))* "\'")
     >
 |    < BADLY_ESCAPED_STRING_LITERAL: ("\"" (~["\"","\\"])* ("\\" ( ~["\\","\""] )))
         | ("\'" (~["\'","\\"])* ("\\" ( ~["\\","\'"] )))