1
0
Fork 0
mirror of https://github.com/eclipse-cdt/cdt synced 2025-04-29 19:45:01 +02:00

Follow up for 199245, because the sniffer no longer trims lines, the parsers have to.

This commit is contained in:
Markus Schorn 2007-08-24 09:34:05 +00:00
parent 605dd3ff71
commit d5715833cd
3 changed files with 5 additions and 2 deletions

View file

@ -114,6 +114,7 @@ public abstract class AbstractGCCBOPConsoleParser implements IScannerInfoConsole
bMultiline = false; bMultiline = false;
sMultiline = ""; //$NON-NLS-1$ sMultiline = ""; //$NON-NLS-1$
} }
line= line.trim();
TraceUtil.outputTrace("AbstractGCCBOPConsoleParser parsing line: [", line, "]"); //$NON-NLS-1$ //$NON-NLS-2$ TraceUtil.outputTrace("AbstractGCCBOPConsoleParser parsing line: [", line, "]"); //$NON-NLS-1$ //$NON-NLS-2$
// make\[[0-9]*\]: error_desc // make\[[0-9]*\]: error_desc
int firstColon= line.indexOf(':'); int firstColon= line.indexOf(':');
@ -135,7 +136,7 @@ public abstract class AbstractGCCBOPConsoleParser implements IScannerInfoConsole
} }
} }
// call sublclass to process a single line // call sublclass to process a single line
return processSingleLine(line); return processSingleLine(line.trim());
} }
private int getDirectoryLevel(String line) { private int getDirectoryLevel(String line) {

View file

@ -60,6 +60,7 @@ public class GCCPerFileSIPConsoleParser implements IScannerInfoConsoleParser {
*/ */
public boolean processLine(String line) { public boolean processLine(String line) {
boolean rc = false; boolean rc = false;
line= line.trim();
TraceUtil.outputTrace("GCCPerFileSIPConsoleParser parsing line: [", line, "]"); //$NON-NLS-1$//$NON-NLS-2$ TraceUtil.outputTrace("GCCPerFileSIPConsoleParser parsing line: [", line, "]"); //$NON-NLS-1$//$NON-NLS-2$
if (line.startsWith(COMMAND_ID_BEGIN)) { if (line.startsWith(COMMAND_ID_BEGIN)) {

View file

@ -54,6 +54,7 @@ public class GCCSpecsConsoleParser implements IScannerInfoConsoleParser {
*/ */
public boolean processLine(String line) { public boolean processLine(String line) {
boolean rc = false; boolean rc = false;
line= line.trim();
TraceUtil.outputTrace("GCCSpecsConsoleParser parsing line: [", line, "]"); //$NON-NLS-1$ //$NON-NLS-2$ TraceUtil.outputTrace("GCCSpecsConsoleParser parsing line: [", line, "]"); //$NON-NLS-1$ //$NON-NLS-2$
// contribution of -dD option // contribution of -dD option
@ -69,7 +70,7 @@ public class GCCSpecsConsoleParser implements IScannerInfoConsoleParser {
symbol = defineParts[1] + "=" + defineParts[2]; //$NON-NLS-1$ symbol = defineParts[1] + "=" + defineParts[2]; //$NON-NLS-1$
break; break;
} }
if (symbol != null && !symbols.contains(symbol)) { //$NON-NLS-1$ if (symbol != null && !symbols.contains(symbol)) {
symbols.add(symbol); symbols.add(symbol);
} }
} }