From eaff349201c1ff325147a8befec215a3a4e3aba6 Mon Sep 17 00:00:00 2001 From: Jarl Gullberg Date: Sun, 16 Jul 2017 15:40:22 +0200 Subject: [PATCH] Renamed "Parser" to "XmlParser" to not conflict with the command line parser. --- src/Generator.Converter/GLXmlParser.cs | 2 +- src/Generator.Converter/Generator.Convert.csproj | 2 +- src/Generator.Converter/Main.cs | 6 +++--- src/Generator.Converter/{Parser.cs => XmlParser.cs} | 6 +++--- 4 files changed, 8 insertions(+), 8 deletions(-) rename src/Generator.Converter/{Parser.cs => XmlParser.cs} (99%) diff --git a/src/Generator.Converter/GLXmlParser.cs b/src/Generator.Converter/GLXmlParser.cs index ccd6b2b..ef3cf7b 100644 --- a/src/Generator.Converter/GLXmlParser.cs +++ b/src/Generator.Converter/GLXmlParser.cs @@ -40,7 +40,7 @@ namespace OpenTK.Convert } } - class GLXmlParser : Parser + class GLXmlParser : XmlParser { static readonly Regex ExtensionRegex = new Regex( @"3DFX|(?!(?<=[1-4])D)[A-Z]{2,}$", diff --git a/src/Generator.Converter/Generator.Convert.csproj b/src/Generator.Converter/Generator.Convert.csproj index f0cd3f6..e4729b9 100644 --- a/src/Generator.Converter/Generator.Convert.csproj +++ b/src/Generator.Converter/Generator.Convert.csproj @@ -96,7 +96,7 @@ Code - + Code diff --git a/src/Generator.Converter/Main.cs b/src/Generator.Converter/Main.cs index d49af28..8835302 100644 --- a/src/Generator.Converter/Main.cs +++ b/src/Generator.Converter/Main.cs @@ -66,15 +66,15 @@ namespace OpenTK.Convert static void Main(string[] args) { - CommandLine.Parser.Default.ParseArguments(args) + Parser.Default.ParseArguments(args) .WithParsed(result => CLIOptions = result) .WithNotParsed(error => Environment.Exit(-1)); try { - Parser parser = new GLXmlParser { Prefix = CLIOptions.Prefix }; + XmlParser xmlParser = new GLXmlParser { Prefix = CLIOptions.Prefix }; - var sigs = CLIOptions.InputFiles.Select(h => parser.Parse(h)).ToList(); + var sigs = CLIOptions.InputFiles.Select(h => xmlParser.Parse(h)).ToList(); // Merge any duplicate enum entries (in case an enum is declared // in multiple files with different entries in each file). diff --git a/src/Generator.Converter/Parser.cs b/src/Generator.Converter/XmlParser.cs similarity index 99% rename from src/Generator.Converter/Parser.cs rename to src/Generator.Converter/XmlParser.cs index 0bf5c89..4b18e2d 100644 --- a/src/Generator.Converter/Parser.cs +++ b/src/Generator.Converter/XmlParser.cs @@ -8,10 +8,10 @@ // distribute, sublicense, and/or sell copies of the Software, and to // permit persons to whom the Software is furnished to do so, subject to // the following conditions: -// +// // The above copyright notice and this permission notice shall be // included in all copies or substantial portions of the Software. -// +// // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, // EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF // MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND @@ -29,7 +29,7 @@ using System.Xml.Linq; namespace OpenTK.Convert { // The base class for a parser. - abstract class Parser + abstract class XmlParser { // Defines a prefix that should be removed from methods and tokens in the XML files, e.g. "gl", "cl", etc. public string Prefix { get; set; } -- 2.7.4