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 4259 Details for
Bug 35338
Cannot save file, "Save failed:null" error message received
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
Log In
[x]
|
Terms of Use
|
Copyright Agent
[patch]
Patch for Scanner
scan-patch.txt (text/plain), 2.68 KB, created by
Philipe Mulet
on 2003-03-20 08:43:35 EST
(
hide
)
Description:
Patch for Scanner
Filename:
MIME Type:
Creator:
Philipe Mulet
Created:
2003-03-20 08:43:35 EST
Size:
2.68 KB
patch
obsolete
>Index: Scanner.java >=================================================================== >RCS file: /data/cvs/eclipse/org.eclipse.jdt.core/compiler/org/eclipse/jdt/internal/compiler/parser/Scanner.java,v >retrieving revision 1.66 >diff -u -r1.66 Scanner.java >--- Scanner.java 11 Mar 2003 15:03:56 -0000 1.66 >+++ Scanner.java 20 Mar 2003 13:38:07 -0000 >@@ -209,7 +209,6 @@ > int foundTaskIndex = this.foundTaskCount; > nextChar: for (int i = commentStart; i < commentEnd && i < this.eofPosition; i++) { > >- int nextPos = -1; > char[] tag = null; > char[] priority = null; > >@@ -224,7 +223,6 @@ > for (int t = 0; t < tagLength; t++){ > if (this.source[i+t] != tag[t]) continue nextTag; > } >- nextPos = i + tagLength; > > if (this.foundTaskTags == null){ > this.foundTaskTags = new char[5][]; >@@ -239,39 +237,41 @@ > } > this.foundTaskTags[this.foundTaskCount] = tag; > this.foundTaskPriorities[this.foundTaskCount] = priority; >- this.foundTaskPositions[this.foundTaskCount] = new int[]{ i, -1 }; >+ this.foundTaskPositions[this.foundTaskCount] = new int[]{ i, i+tagLength-1 }; >+ this.foundTaskMessages[this.foundTaskCount] = CharOperation.NO_CHAR; > this.foundTaskCount++; > >- i = nextPos; >+ i += tagLength-1; // will be incremented when looping > } > } > > for (int i = foundTaskIndex; i < this.foundTaskCount; i++) { > // retrieve message start and end positions > int msgStart = this.foundTaskPositions[i][0] + this.foundTaskTags[i].length; >- int end; >+ int max_value = i + 1 < this.foundTaskCount ? this.foundTaskPositions[i + 1][0] - 1 : commentEnd-1; // at most beginning of next task >+ if (max_value < msgStart) max_value = msgStart; // would only occur if tag is before EOF. >+ int end = -1; > char c; >- int max_value = i + 1 < this.foundTaskCount ? this.foundTaskPositions[i + 1][0] - 1 : Integer.MAX_VALUE; > >- end = -1; >- for (int j = msgStart; j < commentEnd; j++){ >+ for (int j = msgStart; j < max_value; j++){ > if ((c = this.source[j]) == '\n' || c == '\r'){ >- end = j - 1; >+ end = j-1; > break; > } > } >- end = end < max_value ? end : max_value; > >- if (end < 0){ >- for (int j = commentEnd-1; j >= msgStart; j--){ >+ if (end == -1){ >+ for (int j = max_value; j > msgStart; j--){ > if ((c = this.source[j]) == '*') { > end = j-1; > break; > } > } >- if (end < 0) end = commentEnd-1; >+ if (end == -1) end = max_value; > } >- >+ >+ if (msgStart == end) continue; // empty >+ > // trim the message > while (CharOperation.isWhitespace(source[end]) && msgStart <= end) end--; > while (CharOperation.isWhitespace(source[msgStart]) && msgStart <= end) msgStart++;
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 35338
: 4259 |
4286