Remove incorrectly and newly introduced assert

Was failing in li_boost_shared_ptr.i for some languages. A similar
testcase has been added into naturalvar_more.i.
This commit is contained in:
William S Fulton 2013-10-05 02:16:02 +01:00
parent e186d2176a
commit 3fcbb40af9
2 changed files with 7 additions and 1 deletions

View File

@ -15,9 +15,15 @@
template <typename X> struct T {};
struct K {};
struct Hidden;
namespace Ace {
int glob;
}
%}
%{
struct Hidden {};
namespace Ace {
template<typename> struct NoIdea {};
}
%}
%inline %{
@ -40,6 +46,7 @@ struct S {
const std::vector<std::string>::value_type const_string_member; // check this resolves to std::string which has a naturalvar
std::vector<std::string>::value_type string_member; // check this resolves to std::string which has a naturalvar
Hidden hidden;
Ace::NoIdea<Hidden> noidea;
S() : const_te(), const_string_member("initial string value") {}
};
}

View File

@ -485,7 +485,6 @@ int Language::use_naturalvar_mode(Node *n) const {
Replaceall(tys, "class ", "");
}
Node *typenode = Swig_symbol_clookup(tys, 0);
assert(typenode);
if (typenode)
nvar = GetFlag(typenode, "feature:naturalvar");
Delete(tys);