Skip to content

Commit

Permalink
move errors to Dsymbol
Browse files Browse the repository at this point in the history
  • Loading branch information
WalterBright committed Feb 22, 2012
1 parent 36e214a commit 4eaccca
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 4 deletions.
2 changes: 2 additions & 0 deletions src/dsymbol.c
Expand Up @@ -45,6 +45,7 @@ Dsymbol::Dsymbol()
this->loc = 0;
this->comment = NULL;
this->scope = NULL;
this->errors = false;
}

Dsymbol::Dsymbol(Identifier *ident)
Expand All @@ -58,6 +59,7 @@ Dsymbol::Dsymbol(Identifier *ident)
this->loc = 0;
this->comment = NULL;
this->scope = NULL;
this->errors = false;
}

int Dsymbol::equals(Object *o)
Expand Down
1 change: 1 addition & 0 deletions src/dsymbol.h
Expand Up @@ -117,6 +117,7 @@ struct Dsymbol : Object
unsigned char *comment; // documentation comment for this Dsymbol
Loc loc; // where defined
Scope *scope; // !=NULL means context to use for semantic()
bool errors; // this symbol failed to pass semantic()

Dsymbol();
Dsymbol(Identifier *);
Expand Down
2 changes: 0 additions & 2 deletions src/template.c
Expand Up @@ -3346,7 +3346,6 @@ TemplateInstance::TemplateInstance(Loc loc, Identifier *ident)
this->nest = 0;
this->havetempdecl = 0;
this->isnested = NULL;
this->errors = 0;
this->speculative = 0;
}

Expand Down Expand Up @@ -3375,7 +3374,6 @@ TemplateInstance::TemplateInstance(Loc loc, TemplateDeclaration *td, Objects *ti
this->nest = 0;
this->havetempdecl = 1;
this->isnested = NULL;
this->errors = 0;
this->speculative = 0;

assert((size_t)tempdecl->scope > 0x10000);
Expand Down
3 changes: 1 addition & 2 deletions src/template.h
@@ -1,6 +1,6 @@

// Compiler implementation of the D programming language
// Copyright (c) 1999-2011 by Digital Mars
// Copyright (c) 1999-2012 by Digital Mars
// All Rights Reserved
// written by Walter Bright
// http://www.digitalmars.com
Expand Down Expand Up @@ -284,7 +284,6 @@ struct TemplateInstance : ScopeDsymbol
int nest; // for recursion detection
int havetempdecl; // 1 if used second constructor
Dsymbol *isnested; // if referencing local symbols, this is the context
int errors; // 1 if compiled with errors
int speculative; // 1 if only instantiated with errors gagged
#ifdef IN_GCC
/* On some targets, it is necessary to know whether a symbol
Expand Down

0 comments on commit 4eaccca

Please sign in to comment.