diff options
Diffstat (limited to 'OpenSim')
-rw-r--r-- | OpenSim/Region/ScriptEngine/Shared/CodeTools/Compiler.cs | 13 |
1 files changed, 10 insertions, 3 deletions
diff --git a/OpenSim/Region/ScriptEngine/Shared/CodeTools/Compiler.cs b/OpenSim/Region/ScriptEngine/Shared/CodeTools/Compiler.cs index db90f3e..6028179 100644 --- a/OpenSim/Region/ScriptEngine/Shared/CodeTools/Compiler.cs +++ b/OpenSim/Region/ScriptEngine/Shared/CodeTools/Compiler.cs | |||
@@ -543,6 +543,12 @@ namespace OpenSim.Region.ScriptEngine.Shared.CodeTools | |||
543 | string errtext = String.Empty; | 543 | string errtext = String.Empty; |
544 | foreach (CompilerError CompErr in results.Errors) | 544 | foreach (CompilerError CompErr in results.Errors) |
545 | { | 545 | { |
546 | string severity = "Error"; | ||
547 | if ( CompErr.IsWarning ) | ||
548 | { | ||
549 | severity = "Warning"; | ||
550 | } | ||
551 | |||
546 | if (m_UseCompiler) | 552 | if (m_UseCompiler) |
547 | { | 553 | { |
548 | KeyValuePair<int, int> lslPos; | 554 | KeyValuePair<int, int> lslPos; |
@@ -559,16 +565,17 @@ namespace OpenSim.Region.ScriptEngine.Shared.CodeTools | |||
559 | 565 | ||
560 | // The Second Life viewer's script editor begins | 566 | // The Second Life viewer's script editor begins |
561 | // countingn lines and columns at 0, so we subtract 1. | 567 | // countingn lines and columns at 0, so we subtract 1. |
562 | errtext += String.Format("Line {0}, column {1}, Error Number: {2}, '{3}'\r\n", lslPos.Key - 1, lslPos.Value - 1, CompErr.ErrorNumber, CompErr.ErrorText); | 568 | errtext += String.Format("Line {0}, column {1}, {4} Number: {2}, '{3}'\r\n", lslPos.Key - 1, lslPos.Value - 1, CompErr.ErrorNumber, CompErr.ErrorText, severity); |
569 | |||
563 | } | 570 | } |
564 | else | 571 | else |
565 | { | 572 | { |
566 | errtext += "Line number " + (CompErr.Line - LinesToRemoveOnError) + | 573 | errtext += "Line number " + (CompErr.Line - LinesToRemoveOnError) + |
567 | ", Error Number: " + CompErr.ErrorNumber + | 574 | ", " + severity + " Number: " + CompErr.ErrorNumber + |
568 | ", '" + CompErr.ErrorText + "'\r\n"; | 575 | ", '" + CompErr.ErrorText + "'\r\n"; |
569 | } | 576 | } |
570 | } | 577 | } |
571 | Console.WriteLine("[COMPILER ERROR]:" + errtext); | 578 | Console.WriteLine("[COMPILER MESSAGES]: " + errtext); |
572 | if (!File.Exists(OutFile)) | 579 | if (!File.Exists(OutFile)) |
573 | { | 580 | { |
574 | throw new Exception(errtext); | 581 | throw new Exception(errtext); |