Added Absoft error parser
diff --git a/org.eclipse.photran.core/errorparsers/org/eclipse/photran/internal/errorparsers/AbsoftErrorParser.java b/org.eclipse.photran.core/errorparsers/org/eclipse/photran/internal/errorparsers/AbsoftErrorParser.java
new file mode 100644
index 0000000..feea587
--- /dev/null
+++ b/org.eclipse.photran.core/errorparsers/org/eclipse/photran/internal/errorparsers/AbsoftErrorParser.java
@@ -0,0 +1,69 @@
+package org.eclipse.photran.internal.errorparsers;
+
+import org.eclipse.cdt.core.ErrorParserManager;
+import org.eclipse.cdt.core.IErrorParser;
+import org.eclipse.cdt.core.IMarkerGenerator;
+import org.eclipse.core.resources.IFile;
+
+import java.util.regex.*;
+
+/**
+* Absoft Error Parser -- An error parser for Absoft
+*
+* cf90-400 f90fe: ERROR $MAIN, File = f.f95, Line = 44, Column = 13
+* Oops!
+*
+* @author Jeff Overbey
+*/
+final public class AbsoftErrorParser implements IErrorParser
+{
+ /*
+ * Regex notes:
+ * \S matches any non-whitespace character
+ * \d matches [0-9]
+ * \w matches [A-Za-z_0-9]
+ * Parentheses define a capturing group
+ */
+ private Pattern errorLineRegex = Pattern.compile("\\S+ f90fe: ERROR \\S+, File = (\\S+), Line = (\\d+), Column = \\d+");
+
+ private boolean expectingErrorMessage = false;
+
+ private Matcher errorLineMatcher = null;
+ private String filename = null;
+ private int lineNum = 0;
+
+ public boolean processLine(String thisLine, ErrorParserManager eoParser)
+ {
+ if (isErrorLine(thisLine))
+ {
+ rememberInfoFromErrorLine(thisLine);
+ expectingErrorMessage = true;
+ }
+ else if (expectingErrorMessage)
+ {
+ generateMarker(thisLine, eoParser);
+ expectingErrorMessage = false;
+ }
+
+ return false;
+ }
+
+ private boolean isErrorLine(String thisLine)
+ {
+ errorLineMatcher = errorLineRegex.matcher(thisLine);
+ return errorLineMatcher.matches();
+ }
+
+ private void rememberInfoFromErrorLine(String thisLine)
+ {
+ filename = errorLineMatcher.group(1);
+ lineNum = Integer.parseInt(errorLineMatcher.group(2));
+ }
+
+ private void generateMarker(String lineContainingErrorMessage, ErrorParserManager eoParser)
+ {
+ String errorMessage = lineContainingErrorMessage.trim();
+ IFile file = eoParser.findFilePath(filename);
+ eoParser.generateMarker(file, lineNum, errorMessage, IMarkerGenerator.SEVERITY_ERROR_RESOURCE, null);
+ }
+}
\ No newline at end of file
diff --git a/org.eclipse.photran.core/plugin.xml b/org.eclipse.photran.core/plugin.xml
index 8ac49f7..f126e02 100644
--- a/org.eclipse.photran.core/plugin.xml
+++ b/org.eclipse.photran.core/plugin.xml
@@ -34,6 +34,14 @@
<!-- Define the list of Error Parsers provided by the FDT -->
<!-- =================================================================================== -->
<extension
+ id="AbsoftErrorParser"
+ name="Photran Error Parser for Absoft Fortran"
+ point="org.eclipse.cdt.core.ErrorParser">
+ <errorparser
+ class="org.eclipse.photran.internal.errorparsers.AbsoftErrorParser">
+ </errorparser>
+ </extension>
+ <extension
id="XLFErrorParser"
name="%FDTXLFErrorParser.name"
point="org.eclipse.cdt.core.ErrorParser">