Merge branch 'director-return-const-pointer'
* director-return-const-pointer: Put test in alphabetical order Perform proper spacing in director method declarations
This commit is contained in:
commit
fe676f840a
3 changed files with 17 additions and 3 deletions
|
|
@ -5,6 +5,7 @@
|
|||
#endif
|
||||
|
||||
%warnfilter(SWIGWARN_TYPEMAP_THREAD_UNSAFE,SWIGWARN_TYPEMAP_DIRECTOROUT_PTR) MyClass::pmethod;
|
||||
%warnfilter(SWIGWARN_TYPEMAP_DIRECTOROUT_PTR) ConstPtrClass::getConstPtr;
|
||||
|
||||
%{
|
||||
#include <string>
|
||||
|
|
@ -174,7 +175,19 @@ public:
|
|||
}
|
||||
|
||||
};
|
||||
|
||||
%}
|
||||
%}
|
||||
|
||||
%template(MyClassT_i) MyClassT<int>;
|
||||
|
||||
%feature("director") ConstPtrClass;
|
||||
|
||||
%inline %{
|
||||
|
||||
class ConstPtrClass {
|
||||
public:
|
||||
virtual ~ConstPtrClass() {}
|
||||
virtual int *const getConstPtr() = 0;
|
||||
};
|
||||
|
||||
%}
|
||||
|
||||
|
|
|
|||
|
|
@ -51,6 +51,7 @@ ifeq (node,$(JSENGINE))
|
|||
# dunno... ignoring generously
|
||||
apply_signed_char.cpptest: GYP_CFLAGS = \"-Wno-ignored-qualifiers\"
|
||||
constant_pointers.cpptest: GYP_CFLAGS = \"-Wno-ignored-qualifiers\"
|
||||
director_basic.cpptest: GYP_CFLAGS = \"-Wno-ignored-qualifiers\"
|
||||
enum_thorough.cpptest: GYP_CFLAGS = \"-Wno-ignored-qualifiers\"
|
||||
|
||||
setup_node = \
|
||||
|
|
|
|||
|
|
@ -160,7 +160,7 @@ String *Swig_method_decl(SwigType *return_base_type, SwigType *decl, const_Strin
|
|||
SwigType *rettype_stripped = SwigType_strip_qualifiers(rettype);
|
||||
String *rtype = SwigType_str(rettype, 0);
|
||||
Append(result, rtype);
|
||||
if (SwigType_issimple(rettype_stripped) && return_base_type)
|
||||
if ((SwigType_issimple(rettype_stripped) && return_base_type) || SwigType_isqualifier(rettype))
|
||||
Append(result, " ");
|
||||
Delete(rtype);
|
||||
Delete(rettype_stripped);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue