From e87e94572e71ea4f307858dd6f5c3c24546cda35 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Fri, 16 Nov 2012 19:33:43 +0000 Subject: [PATCH] Fix unused variables found by Coverity checker git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@13892 626c5289-ae23-0410-ae9c-e8d60b6d4f22 --- Source/CParse/parser.y | 1 - Source/Preprocessor/cpp.c | 5 +---- 2 files changed, 1 insertion(+), 5 deletions(-) diff --git a/Source/CParse/parser.y b/Source/CParse/parser.y index 724b2ef69..2774014ab 100644 --- a/Source/CParse/parser.y +++ b/Source/CParse/parser.y @@ -1004,7 +1004,6 @@ static String *resolve_create_node_scope(String *cname) { } else { /* now this last part is a class */ si = Next(si); - ns1 = Swig_symbol_clookup(sname,0); /* or a nested class tree, which is unrolled here */ for (; si.item; si = Next(si)) { if (si.item) { diff --git a/Source/Preprocessor/cpp.c b/Source/Preprocessor/cpp.c index b3e0549f5..d68658eb6 100644 --- a/Source/Preprocessor/cpp.c +++ b/Source/Preprocessor/cpp.c @@ -1213,13 +1213,10 @@ static DOH *Preprocessor_replace(DOH *s) { Replaceall(fn, "\\", "\\\\"); Printf(ns, "\"%s\"", fn); Delete(fn); - } else if ((m = Getattr(symbols, id))) { + } else if (Getattr(symbols, id)) { DOH *e; /* Yes. There is a macro here */ /* See if the macro expects arguments */ - /* if (Getattr(m,"args")) { - Swig_error(Getfile(id),Getline(id),"Macro arguments expected.\n"); - } */ e = expand_macro(id, 0, s); if (e) Append(ns, e);