[hackers] [scc] Fix notdefined() || Roberto E. Vargas Caballero

From: <git_AT_suckless.org>
Date: Mon, 5 Oct 2015 22:38:38 +0200 (CEST)

commit a88a10c38215e4bd6317d65a33e3bb0dac02dfd8
Author: Roberto E. Vargas Caballero <k0ga_AT_shike2.com>
AuthorDate: Mon Oct 5 22:32:18 2015 +0200
Commit: Roberto E. Vargas Caballero <k0ga_AT_shike2.com>
CommitDate: Mon Oct 5 22:32:18 2015 +0200

    Fix notdefined()
    
    The flag that a symbol is already in the hash table is
    ISDECLARED, meanwhile ISDEFINED stands for symbols
    already defined (defined in the standard sense).

diff --git a/cc1/expr.c b/cc1/expr.c
index 3b106a0..7fbde46 100644
--- a/cc1/expr.c
+++ b/cc1/expr.c
_AT_@ -509,7 +509,7 @@ notdefined(Symbol *sym)
                 expect(IDEN);
                 expect(')');
 
- isdef = (sym->flags & ISDEFINED) != 0;
+ isdef = (sym->flags & ISDECLARED) != 0;
                 sym = newsym(NS_IDEN);
                 sym->type = inttype;
                 sym->flags |= ISCONSTANT;
Received on Mon Oct 05 2015 - 22:38:38 CEST

This archive was generated by hypermail 2.3.0 : Mon Oct 05 2015 - 22:48:12 CEST