- // get DEFNAME
- wxString defname = defnameval.BeforeFirst(' ');
- if (defname.Contains("("))
- continue; // this is a macro, skip it!
-
- // get DEFVAL
- wxString defval = defnameval.AfterFirst(' ').Strip(wxString::both);
- if (defval.StartsWith("(") && defval.EndsWith(")"))
- defval = defval.Mid(1, defval.Len()-2);
-
- // store this pair in the doxygen interface, where it can be useful
- m_doxyInterface.AddPreprocessorValue(defname, defval);
- useful++;
+ if (defnameval.Contains(" "))
+ {
+ // get DEFNAME
+ wxString defname = defnameval.BeforeFirst(' ');
+ if (defname.Contains("("))
+ continue; // this is a macro, skip it!
+
+ // get DEFVAL
+ wxString defval = defnameval.AfterFirst(' ').Strip(wxString::both);
+ if (defval.StartsWith("(") && defval.EndsWith(")"))
+ defval = defval.Mid(1, defval.Len()-2);
+
+ // store this pair in the doxygen interface, where it can be useful
+ m_doxyInterface.AddPreprocessorValue(defname, defval);
+ useful++;
+ }
+ else
+ {
+ // it looks like the format of this line is:
+ // #define DEFNAME
+ // we are not interested to symbols #defined to nothing,
+ // so we just ignore this line.
+ }