From c0919870f84a4666677c7f4e760f13bbcac7c579 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Fri, 16 Nov 2012 19:37:40 +0000 Subject: [PATCH] Add assertion for possible failure displaying warning git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@13895 626c5289-ae23-0410-ae9c-e8d60b6d4f22 --- Source/CParse/templ.c | 1 + 1 file changed, 1 insertion(+) diff --git a/Source/CParse/templ.c b/Source/CParse/templ.c index 503f725cb..b14cd1e4d 100644 --- a/Source/CParse/templ.c +++ b/Source/CParse/templ.c @@ -766,6 +766,7 @@ static Node *template_locate(String *name, Parm *tparms, Symtab *tscope) { for (i = 1; i < posslen; i++) { String *templcsymname = Getattr(Getitem(possiblepartials, i), "templcsymname"); Node *ignored_node = Swig_symbol_clookup_local(templcsymname, primary_scope); + assert(ignored_node); Swig_warning(WARN_PARSE_TEMPLATE_AMBIG, Getfile(ignored_node), Getline(ignored_node), " instantiation '%s' ignored.\n", SwigType_namestr(Getattr(ignored_node, "name"))); } }