mirror of
https://github.com/Ryujinx/Opentk.git
synced 2025-07-08 22:40:33 +00:00
Fix compile warnings in Converter.
This commit is contained in:
parent
54f1e575d0
commit
366eb921a7
|
@ -70,7 +70,9 @@ namespace CHeaderToXML
|
||||||
else
|
else
|
||||||
return t;
|
return t;
|
||||||
}
|
}
|
||||||
|
#pragma warning disable 0162 //CS0162: Unreachable code detected
|
||||||
/* gmcs bug 336258 */ return "";
|
/* gmcs bug 336258 */ return "";
|
||||||
|
#pragma warning restore 0162
|
||||||
}).ToArray();
|
}).ToArray();
|
||||||
|
|
||||||
Func<string[], string> get_name = tokens =>
|
Func<string[], string> get_name = tokens =>
|
||||||
|
|
|
@ -43,7 +43,6 @@ namespace CHeaderToXML
|
||||||
ParserModes CurrentMode;
|
ParserModes CurrentMode;
|
||||||
|
|
||||||
enum EntryModes { Core, Compatibility };
|
enum EntryModes { Core, Compatibility };
|
||||||
EntryModes CurrentEntryMode;
|
|
||||||
|
|
||||||
public override IEnumerable<XElement> Parse(string[] lines)
|
public override IEnumerable<XElement> Parse(string[] lines)
|
||||||
{
|
{
|
||||||
|
@ -67,7 +66,6 @@ namespace CHeaderToXML
|
||||||
new XAttribute("name", words[0]));
|
new XAttribute("name", words[0]));
|
||||||
|
|
||||||
CurrentMode = ParserModes.Enum;
|
CurrentMode = ParserModes.Enum;
|
||||||
CurrentEntryMode = EntryModes.Core;
|
|
||||||
}
|
}
|
||||||
else if (line.StartsWith(words[0] + "("))
|
else if (line.StartsWith(words[0] + "("))
|
||||||
{
|
{
|
||||||
|
@ -94,21 +92,15 @@ namespace CHeaderToXML
|
||||||
current.Add(new XElement("use",
|
current.Add(new XElement("use",
|
||||||
new XAttribute("enum", words[1]),
|
new XAttribute("enum", words[1]),
|
||||||
new XAttribute("token", words[2])));
|
new XAttribute("token", words[2])));
|
||||||
//new XAttribute("profile", CurrentEntryMode == EntryModes.Compatibility ?
|
|
||||||
// "compatibility" : "core")));
|
|
||||||
}
|
}
|
||||||
else if (words[1] == "=")
|
else if (words[1] == "=")
|
||||||
{
|
{
|
||||||
current.Add(new XElement("token",
|
current.Add(new XElement("token",
|
||||||
new XAttribute("name", words[0]),
|
new XAttribute("name", words[0]),
|
||||||
new XAttribute("value", words[2])));
|
new XAttribute("value", words[2])));
|
||||||
//new XAttribute("profile", CurrentEntryMode == EntryModes.Compatibility ?
|
|
||||||
// "compatibility" : "core")));
|
|
||||||
}
|
}
|
||||||
else if (words[0] == "profile:")
|
else if (words[0] == "profile:")
|
||||||
{
|
{
|
||||||
//CurrentEntryMode = words[1] == "compatibility" ?
|
|
||||||
// EntryModes.Compatibility : EntryModes.Core;
|
|
||||||
}
|
}
|
||||||
else if (words[0].Contains("future_use"))
|
else if (words[0].Contains("future_use"))
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in a new issue