diff --git a/SWIG/Source/Modules/typepass.cxx b/SWIG/Source/Modules/typepass.cxx index 3e4f74338..53ab6e225 100644 --- a/SWIG/Source/Modules/typepass.cxx +++ b/SWIG/Source/Modules/typepass.cxx @@ -73,6 +73,16 @@ class TypePass : public Dispatcher { while (p) { SwigType *ty = Getattr(p,"type"); normalize_type(ty); + + /* This is a check for a function type */ + { + SwigType *qty = SwigType_typedef_resolve_all(ty); + if (SwigType_isfunction(qty)) { + SwigType_add_pointer(ty); + } + Delete(qty); + } + String *value = Getattr(p,"value"); if (value) { Node *n = Swig_symbol_clookup(value,0);