Fixed handling of constants. Previously if a %constant directive was defined before a #define it would not work correctly.

git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk/SWIG@7578 626c5289-ae23-0410-ae9c-e8d60b6d4f22
This commit is contained in:
Charlie Savage 2005-10-03 19:47:06 +00:00
commit 65a0a3b9f2
2 changed files with 4 additions and 3 deletions

View file

@ -1578,7 +1578,8 @@ public:
char *iname = GetChar(n,"sym:name");
SwigType *type = Getattr(n,"type");
char *value = GetChar(n,"value");
String *rawval = Getattr(n,"rawval");
String *value = rawval ? rawval : Getattr(n,"value");
if (current == CLASS_CONST) {
iname = klass->strip(iname);