diff options
author | Sylvestre Ledru <sylvestre.ledru@scilab-enterprises.com> | 2013-03-05 18:17:50 +0100 |
---|---|---|
committer | William S Fulton <wsf@fultondesigns.co.uk> | 2013-03-08 20:53:18 +0000 |
commit | e0b14786d6d22276dda85354babbfeffdfd78072 (patch) | |
tree | 85f86356ae498b03392e0370de252059d0496072 /Source/CParse | |
parent | 670962cfe8d951004f927c803e505f23ee373d3a (diff) | |
download | swig-e0b14786d6d22276dda85354babbfeffdfd78072.tar.gz |
Fix some useless code detected by scan-build (LLVM/Clang)
Diffstat (limited to 'Source/CParse')
-rw-r--r-- | Source/CParse/templ.c | 7 |
1 files changed, 1 insertions, 6 deletions
diff --git a/Source/CParse/templ.c b/Source/CParse/templ.c index ed6acfc8c..48bdf4faa 100644 --- a/Source/CParse/templ.c +++ b/Source/CParse/templ.c @@ -317,14 +317,13 @@ int Swig_cparse_template_expand(Node *n, String *rname, ParmList *tparms, Symtab if (tp) { Symtab *tsdecl = Getattr(n, "sym:symtab"); while (p && tp) { - String *name, *value, *valuestr, *tydef, *tmp, *tmpr; + String *name, *value, *valuestr, *tmp, *tmpr; int sz, i; String *dvalue = 0; String *qvalue = 0; name = Getattr(tp, "name"); value = Getattr(p, "value"); - tydef = Getattr(p, "typedef"); if (name) { if (!value) @@ -365,9 +364,6 @@ int Swig_cparse_template_expand(Node *n, String *rname, ParmList *tparms, Symtab /* Printf(stdout,"'%s'\n", s); */ } - if (!tydef) { - tydef = dvalue; - } tmp = NewStringf("#%s", name); tmpr = NewStringf("\"%s\"", valuestr); @@ -375,7 +371,6 @@ int Swig_cparse_template_expand(Node *n, String *rname, ParmList *tparms, Symtab for (i = 0; i < sz; i++) { String *s = Getitem(cpatchlist, i); Replace(s, tmp, tmpr, DOH_REPLACE_ID); - /* Replace(s,name,tydef, DOH_REPLACE_ID); */ Replace(s, name, valuestr, DOH_REPLACE_ID); } Delete(tmp); |