From 19034d545f159f518874680b639918af9108d5af Mon Sep 17 00:00:00 2001 From: Dave Beazley Date: Thu, 1 May 2003 19:23:46 +0000 Subject: Fixed const-SwigValueWrapper<> bug. git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk/SWIG@4764 626c5289-ae23-0410-ae9c-e8d60b6d4f22 --- Source/Modules/lang.cxx | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'Source') diff --git a/Source/Modules/lang.cxx b/Source/Modules/lang.cxx index bf2ca3be1..a6b39868b 100644 --- a/Source/Modules/lang.cxx +++ b/Source/Modules/lang.cxx @@ -259,10 +259,12 @@ SwigType *cplus_value_type(SwigType *t) { Node *n; if (!CPlusPlus) return 0; if (SwigType_isclass(t)) { - SwigType *td = SwigType_typedef_resolve_all(t); + SwigType *ftd = SwigType_typedef_resolve_all(t); + SwigType *td = SwigType_strip_qualifiers(ftd); + Delete(ftd); if ((n = Swig_symbol_clookup(td,0))) { if ((Strcmp(nodeType(n),"class") == 0) && (!Getattr(n,"allocate:default_constructor") || (Getattr(n,"allocate:noassign")))) { - String *s = NewStringf("SwigValueWrapper< %s >",t); + String *s = NewStringf("SwigValueWrapper< %s >",SwigType_str(t,0)); Delete(td); return s; } else { @@ -270,7 +272,7 @@ SwigType *cplus_value_type(SwigType *t) { } } if (SwigType_issimple(td) && SwigType_istemplate(td)) { - String *s = NewStringf("SwigValueWrapper< %s >",t); + String *s = NewStringf("SwigValueWrapper< %s >",SwigType_str(t,0)); Delete(td); return s; } -- cgit v1.2.3