public ErrorMatch Match(ReadOnlyLineBuffer Input)
        {
            Match Match;

            if (Input.TryMatch(@"^(\s*)([a-zA-Z_][a-zA-Z0-9_]*):\s*(Error|Warning|Display): ", out Match))
            {
                int MaxOffset = Input.MatchForwards(0, String.Format(@"^({0} | *$)", Match.Groups[1].Value));

                ErrorSeverity Severity;
                switch (Match.Groups[3].Value)
                {
                case "Error":
                    Severity = ErrorSeverity.Error;
                    break;

                case "Warning":
                    Severity = ErrorSeverity.Warning;
                    break;

                default:
                    Severity = ErrorSeverity.Silent;
                    break;
                }

                ErrorMatch Error = new ErrorMatch(Severity, ErrorPriority.Low, "Log", Input, 0, MaxOffset);
                Error.Properties["Channel"] = Match.Groups[2].Value;
                return(Error);
            }
            return(null);
        }
Пример #2
0
        static ErrorMatch ParseClangMatch(ReadOnlyLineBuffer Input, ErrorSeverity Severity)
        {
            string Indent = ExtractIndent(Input[0]);

            int MinOffset = Input.MatchBackwards(0, String.Format(@"^(?:{0}).*(?:In (member )?function|In file included from)", Indent));
            int MaxOffset = Input.MatchForwards(0, String.Format(@"^({0} |{0}{1}\s*note:| *\$)", Indent, ClangFileLinePattern));

            return(new ErrorMatch(Severity, ErrorPriority.High, "Compile", Input, MinOffset, MaxOffset));
        }
Пример #3
0
 public ErrorMatch Match(ReadOnlyLineBuffer Input)
 {
     if (Input.IsMatch(@"\s*----+Build System Warning----+"))
     {
         int MaxOffset = Input.MatchForwards(0, @"^\s*[A-Za-z]");
         return(new ErrorMatch(ErrorSeverity.Warning, ErrorPriority.Normal, "Xoreax", Input, 0, MaxOffset));
     }
     return(null);
 }
Пример #4
0
 public ErrorMatch Match(ReadOnlyLineBuffer Input)
 {
     if (Input.IsMatch(@"^\s*Unhandled Exception: "))
     {
         int MaxOffset = Input.MatchForwards(0, @"^\s*at ");
         return(new ErrorMatch(ErrorSeverity.Error, ErrorPriority.Low, "Exception", Input, 0, MaxOffset));
     }
     return(null);
 }
Пример #5
0
        public ErrorMatch Match(ReadOnlyLineBuffer Input)
        {
            Match Match;

            if (Input.TryMatch(@"^(\s*)WARNING: ThreadSanitizer:", out Match))
            {
                int EndIdx = Input.MatchForwards(0, String.Format(@"^([ ]*|{0}  .*|{0}SUMMARY:.*)\$", Match.Groups[1].Value));
                return(new ErrorMatch(ErrorSeverity.Warning, ErrorPriority.Normal, "ThreadSanitizer", Input, 0, EndIdx));
            }
            return(null);
        }
Пример #6
0
 public ErrorMatch Match(ReadOnlyLineBuffer Input)
 {
     if (Input.IsMatch(@"^\s*FATAL:"))
     {
         return(new ErrorMatch(ErrorSeverity.Error, ErrorPriority.Low, "Generic", Input));
     }
     if (Input.IsMatch(@"(?<!\w)(ERROR|[Ee]rror)( (\([^)]+\)|\[[^\]]+\]))?: "))
     {
         int MaxOffset = Input.MatchForwards(0, String.Format(@"^({0} | *$)", ExtractIndent(Input[0])));
         return(new ErrorMatch(ErrorSeverity.Error, ErrorPriority.Lowest, "Generic", Input, 0, MaxOffset));
     }
     if (Input.IsMatch(@"(?<!\w)(WARNING|[Ww]arning)( (\([^)]+\)|\[[^\]]+\]))?: "))
     {
         int MaxOffset = Input.MatchForwards(0, String.Format(@"^({0} | *$)", ExtractIndent(Input[0])));
         return(new ErrorMatch(ErrorSeverity.Warning, ErrorPriority.Lowest, "Generic", Input, 0, MaxOffset));
     }
     if (Input.IsMatch(@"[Ee]rror [A-Z]\d+\s:"))
     {
         return(new ErrorMatch(ErrorSeverity.Error, ErrorPriority.Lowest, "Generic", Input));
     }
     return(null);
 }
Пример #7
0
 public ErrorMatch Match(ReadOnlyLineBuffer Input)
 {
     if (Regex.IsMatch(Input[0], "begin: stack for UAT"))
     {
         for (int Idx = 1; Idx < 100; Idx++)
         {
             if (Regex.IsMatch(Input[Idx], "end: stack for UAT"))
             {
                 return(new ErrorMatch(ErrorSeverity.Error, ErrorPriority.BelowNormal, "crash", Input, 0, Idx));
             }
         }
     }
     if (Input.IsMatch("AutomationTool: Stack:"))
     {
         int EndOffset = Input.MatchForwards(0, "AutomationTool: Stack:");
         return(new ErrorMatch(ErrorSeverity.Error, ErrorPriority.Low, "Crash", Input, 0, EndOffset));
     }
     if (Input.IsMatch("ExitCode=(3|139|255)"))
     {
         return(new ErrorMatch(ErrorSeverity.Error, ErrorPriority.Low, "Crash", Input));
     }
     return(null);
 }