Added workarounds for typical header defines that should not be present in the generated xml files (e.g. #define WIN32_LEAN_AND_MEAN 1).
This commit is contained in:
parent
6ec4026a5c
commit
f4e80dec64
1 changed files with 9 additions and 0 deletions
|
@ -153,6 +153,15 @@ namespace CHeaderToXML
|
|||
if (tokens[1].StartsWith("__"))
|
||||
return acc;
|
||||
|
||||
// Check whether this is a known header define like WIN32_LEAN_AND_MEAN
|
||||
switch (tokens[1])
|
||||
{
|
||||
case "WIN32_LEAN_AND_MEAN":
|
||||
case "APIENTRY":
|
||||
case "GLAPI":
|
||||
return acc;
|
||||
}
|
||||
|
||||
acc[acc.Count - 1].Add(new XElement("token",
|
||||
new XAttribute("name", tokens[1].Substring(Prefix.Length + 1)), // remove prefix
|
||||
new XAttribute("value", tokens[2])));
|
||||
|
|
Loading…
Reference in a new issue