* Fix a few warnings.
This commit is contained in:
		
							parent
							
								
									dcff8cdb76
								
							
						
					
					
						commit
						1854f84e83
					
				
					 4 changed files with 5 additions and 5 deletions
				
			
		|  | @ -87,7 +87,7 @@ static Expr substArgs(EvalState & state, | ||||||
|            arguments.  Find out which. */ |            arguments.  Find out which. */ | ||||||
|         for (ATermIterator i(formals); i; ++i) { |         for (ATermIterator i(formals); i; ++i) { | ||||||
|             Expr name; ATerm d1, d2; |             Expr name; ATerm d1, d2; | ||||||
|             matchFormal(*i, name, d1, d2); |             if (!matchFormal(*i, name, d1, d2)) abort(); | ||||||
|             subs.remove(name); |             subs.remove(name); | ||||||
|         } |         } | ||||||
|         throw TypeError(format("the function does not expect an argument named `%1%'") |         throw TypeError(format("the function does not expect an argument named `%1%'") | ||||||
|  |  | ||||||
|  | @ -130,7 +130,7 @@ Expr substitute(const Substitution & subs, Expr e) | ||||||
|     /* In case of a function, filter out all variables bound by this
 |     /* In case of a function, filter out all variables bound by this
 | ||||||
|        function. */ |        function. */ | ||||||
|     ATermList formals; |     ATermList formals; | ||||||
|     ATerm body, def; |     ATerm body; | ||||||
|     if (matchFunction(e, formals, body, pos)) { |     if (matchFunction(e, formals, body, pos)) { | ||||||
|         ATermMap map(ATgetLength(formals)); |         ATermMap map(ATgetLength(formals)); | ||||||
|         for (ATermIterator i(formals); i; ++i) { |         for (ATermIterator i(formals); i; ++i) { | ||||||
|  | @ -227,7 +227,7 @@ static void checkVarDefs2(set<Expr> & done, const ATermMap & defs, Expr e) | ||||||
|         for (ATermIterator i(formals); i; ++i) { |         for (ATermIterator i(formals); i; ++i) { | ||||||
|             ATerm valids, deflt; |             ATerm valids, deflt; | ||||||
|             set<Expr> done2; |             set<Expr> done2; | ||||||
|             matchFormal(*i, name, valids, deflt); |             if (!matchFormal(*i, name, valids, deflt)) abort(); | ||||||
|             checkVarDefs2(done, defs, valids); |             checkVarDefs2(done, defs, valids); | ||||||
|             checkVarDefs2(done2, defs2, deflt); |             checkVarDefs2(done2, defs2, deflt); | ||||||
|         } |         } | ||||||
|  |  | ||||||
|  | @ -50,7 +50,7 @@ struct Substitution | ||||||
|     { |     { | ||||||
|         Expr x; |         Expr x; | ||||||
|         for (const Substitution * s(this); s; s = s->prev) |         for (const Substitution * s(this); s; s = s->prev) | ||||||
|             if (x = s->map->get(name)) return x; |             if ((x = s->map->get(name))) return x; | ||||||
|         return 0; |         return 0; | ||||||
|     } |     } | ||||||
| }; | }; | ||||||
|  |  | ||||||
|  | @ -75,7 +75,7 @@ Expr unescapeStr(const char * s) | ||||||
| { | { | ||||||
|     string t; |     string t; | ||||||
|     char c; |     char c; | ||||||
|     while (c = *s++) { |     while ((c = *s++)) { | ||||||
|         if (c == '\\') { |         if (c == '\\') { | ||||||
|             assert(*s); |             assert(*s); | ||||||
|             c = *s++; |             c = *s++; | ||||||
|  |  | ||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue