Download
Getting Started
Members
Projects
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
More
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
Toggle navigation
Bugzilla – Attachment 106404 Details for
Bug 239198
[compiler] NegativeArraySizeException thrown for triple quotes
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
Log In
[x]
|
Terms of Use
|
Copyright Agent
[patch]
Proposed fix for 3.4.1
bug239198_341_001.txt (text/plain), 2.47 KB, created by
David Audel
on 2008-07-03 05:10:06 EDT
(
hide
)
Description:
Proposed fix for 3.4.1
Filename:
MIME Type:
Creator:
David Audel
Created:
2008-07-03 05:10:06 EDT
Size:
2.47 KB
patch
obsolete
>### Eclipse Workspace Patch 1.0 >#P org.eclipse.jdt.core >Index: compiler/org/eclipse/jdt/internal/compiler/parser/Parser.java >=================================================================== >RCS file: /cvsroot/eclipse/org.eclipse.jdt.core/compiler/org/eclipse/jdt/internal/compiler/parser/Parser.java,v >retrieving revision 1.387 >diff -u -r1.387 Parser.java >--- compiler/org/eclipse/jdt/internal/compiler/parser/Parser.java 7 May 2008 11:36:38 -0000 1.387 >+++ compiler/org/eclipse/jdt/internal/compiler/parser/Parser.java 3 Jul 2008 09:07:08 -0000 >@@ -9219,6 +9219,7 @@ > this.hasReportedError = true; > } > this.lastCheckPoint = this.scanner.currentPosition; >+ this.currentToken = 0; > this.restartRecovery = true; > } > if(this.statementRecoveryActivated) { >@@ -9247,6 +9248,7 @@ > this.hasReportedError = true; > } > this.lastCheckPoint = this.scanner.currentPosition; >+ this.currentToken = 0; > this.restartRecovery = true; > } > if(this.statementRecoveryActivated) { >#P org.eclipse.jdt.core.tests.compiler >Index: src/org/eclipse/jdt/core/tests/compiler/parser/ParserTest.java >=================================================================== >RCS file: /cvsroot/eclipse/org.eclipse.jdt.core.tests.compiler/src/org/eclipse/jdt/core/tests/compiler/parser/ParserTest.java,v >retrieving revision 1.23 >diff -u -r1.23 ParserTest.java >--- src/org/eclipse/jdt/core/tests/compiler/parser/ParserTest.java 10 Jun 2008 10:55:50 -0000 1.23 >+++ src/org/eclipse/jdt/core/tests/compiler/parser/ParserTest.java 3 Jul 2008 09:07:09 -0000 >@@ -742,4 +742,35 @@ > "----------\n" > ); > } >+/* >+ * https://bugs.eclipse.org/bugs/show_bug.cgi?id=239198 >+ */ >+public void test028() { >+ Map options = getCompilerOptions(); >+ options.put(CompilerOptions.OPTION_ReportNonExternalizedStringLiteral, CompilerOptions.ERROR); >+ runNegativeTest( >+ new String[] { >+ "X.java", >+ "class X {\n" + >+ " public static void foo(String param) {\n" + >+ " String foo= param;\n" + >+ " Srtring bar = \"\"\"\n" + >+ " }\n" + >+ "}" >+ }, >+ "----------\n" + >+ "1. ERROR in X.java (at line 4)\n" + >+ " Srtring bar = \"\"\"\n" + >+ " ^^\n" + >+ "Non-externalized string literal; it should be followed by //$NON-NLS-<n>$\n" + >+ "----------\n" + >+ "2. ERROR in X.java (at line 4)\n" + >+ " Srtring bar = \"\"\"\n" + >+ " ^\n" + >+ "String literal is not properly closed by a double-quote\n" + >+ "----------\n", >+ null, >+ true, >+ options); >+} > }
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 239198
:
106282
|
106402
| 106404