X-Git-Url: http://wien.tomnetworks.com/gitweb/?a=blobdiff_plain;f=mcs%2Fmcs%2Fsettings.cs;h=0c199017af9b1d4e3e19624afb3563ee9b7705ca;hb=209c8fc0ddee8575546ed0e8ee7fa9955e4126be;hp=42156d77ba9ab630a1abc513ac49c84cb28aee97;hpb=48992d4b3f8b568be17180372160d2f3e03b8ccb;p=mono.git diff --git a/mcs/mcs/settings.cs b/mcs/mcs/settings.cs index 42156d77ba9..0c199017af9 100644 --- a/mcs/mcs/settings.cs +++ b/mcs/mcs/settings.cs @@ -150,7 +150,7 @@ namespace Mono.CSharp { public bool BreakOnInternalError; #endregion - public string GetResourceStrings; + public List GetResourceStrings; public bool ShowFullPaths; @@ -583,15 +583,21 @@ namespace Mono.CSharp { { bool valid = true; foreach (string wid in text.Split (numeric_value_separator, StringSplitOptions.RemoveEmptyEntries)) { + var warning = wid; + if (warning.Length == 6 && warning [0] == 'C' && warning [1] == 'S') + warning = warning.Substring (2); + int id; - if (!int.TryParse (wid, NumberStyles.AllowLeadingWhite, CultureInfo.InvariantCulture, out id)) { - report.Error (1904, "`{0}' is not a valid warning number", wid); - valid = false; + if (!int.TryParse (warning, NumberStyles.AllowLeadingWhite, CultureInfo.InvariantCulture, out id)) { continue; } - if (report.CheckWarningCode (id, Location.Null)) + if (report.CheckWarningCode (id, Location.Null)) { action (id); + } else { + report.Error (1904, "`{0}' is not a valid warning number", wid); + valid = false; + } } return valid; @@ -1204,6 +1210,32 @@ namespace Mono.CSharp { settings.RuntimeMetadataVersion = value; return ParseResult.Success; + // csc options that we don't support + case "/analyzer": + case "/appconfig": + case "/baseaddress": + case "/deterministic": + case "/errorendlocation": + case "/errorlog": + case "/features": + case "/highentropyva": + case "/highentropyva+": + case "/highentropyva-": + case "/link": + case "/moduleassemblyname": + case "/nowin32manifest": + case "/pathmap": + case "/pdb": + case "/preferreduilang": + case "/publicsign": + case "/reportanalyzer": + case "/ruleset": + case "/sqmsessionguid": + case "/subsystemversion": + case "/utf8output": + case "/win32manifest": + return ParseResult.Success; + default: return ParseResult.UnknownOption; } @@ -1485,7 +1517,10 @@ namespace Mono.CSharp { return ParseResult.Error; } - settings.GetResourceStrings = file; + if (settings.GetResourceStrings == null) + settings.GetResourceStrings = new List (); + + settings.GetResourceStrings.Add (file); return ParseResult.Success; } @@ -1558,7 +1593,7 @@ namespace Mono.CSharp { " -help Lists all compiler options (short: -?)\n" + " -keycontainer:NAME The key pair container used to sign the output assembly\n" + " -keyfile:FILE The key file used to strongname the ouput assembly\n" + - " -langversion:TEXT Specifies language version: ISO-1, ISO-2, 3, 4, 5, Default or Future\n" + + " -langversion:TEXT Specifies language version: ISO-1, ISO-2, 3, 4, 5, Default or Experimental\n" + " -lib:PATH1[,PATHn] Specifies the location of referenced assemblies\n" + " -main:CLASS Specifies the class with the Main method (short: -m)\n" + " -noconfig Disables implicitly referenced assemblies\n" +