Skip to content

Commit

Permalink
Remove unused class ClassInfoDeclaration
Browse files Browse the repository at this point in the history
  • Loading branch information
yebblies committed May 17, 2015
1 parent 895eb9c commit 9b11ed7
Show file tree
Hide file tree
Showing 7 changed files with 0 additions and 41 deletions.
19 changes: 0 additions & 19 deletions src/declaration.c
Expand Up @@ -2119,25 +2119,6 @@ SymbolDeclaration::SymbolDeclaration(Loc loc, StructDeclaration *dsym)
storage_class |= STCconst;
}

/********************************* ClassInfoDeclaration ****************************/

ClassInfoDeclaration::ClassInfoDeclaration(ClassDeclaration *cd)
: VarDeclaration(Loc(), Type::typeinfoclass->type, cd->ident, NULL)
{
this->cd = cd;
storage_class = STCstatic | STCgshared;
}

Dsymbol *ClassInfoDeclaration::syntaxCopy(Dsymbol *s)
{
assert(0); // should never be produced by syntax
return NULL;
}

void ClassInfoDeclaration::semantic(Scope *sc)
{
}

/********************************* TypeInfoDeclaration ****************************/

TypeInfoDeclaration::TypeInfoDeclaration(Type *tinfo, int internal)
Expand Down
12 changes: 0 additions & 12 deletions src/declaration.h
Expand Up @@ -303,18 +303,6 @@ class SymbolDeclaration : public Declaration
void accept(Visitor *v) { v->visit(this); }
};

class ClassInfoDeclaration : public VarDeclaration
{
public:
ClassDeclaration *cd;

ClassInfoDeclaration(ClassDeclaration *cd);
Dsymbol *syntaxCopy(Dsymbol *);
void semantic(Scope *sc);

void accept(Visitor *v) { v->visit(this); }
};

class TypeInfoDeclaration : public VarDeclaration
{
public:
Expand Down
1 change: 0 additions & 1 deletion src/doc.c
Expand Up @@ -784,7 +784,6 @@ void emitComment(Dsymbol *s, OutBuffer *buf, Scope *sc)
void visit(DtorDeclaration *) {}
void visit(StaticCtorDeclaration *) {}
void visit(StaticDtorDeclaration *) {}
void visit(ClassInfoDeclaration *) {}
void visit(TypeInfoDeclaration *) {}

void visit(Declaration *d)
Expand Down
1 change: 0 additions & 1 deletion src/json.c
Expand Up @@ -628,7 +628,6 @@ class ToJsonVisitor : public Visitor
}
}

void visit(ClassInfoDeclaration *d) {}
void visit(TypeInfoDeclaration *d) {}
void visit(PostBlitDeclaration *d) {}

Expand Down
1 change: 0 additions & 1 deletion src/magicport.json
Expand Up @@ -1598,7 +1598,6 @@
"struct OverDeclaration",
"struct VarDeclaration",
"struct SymbolDeclaration",
"struct ClassInfoDeclaration",
"struct TypeInfoDeclaration",
"struct TypeInfoStructDeclaration",
"struct TypeInfoClassDeclaration",
Expand Down
5 changes: 0 additions & 5 deletions src/tocsym.c
Expand Up @@ -253,11 +253,6 @@ Symbol *toSymbol(Dsymbol *s)
result = vd->csym;
}

void visit(ClassInfoDeclaration *cid)
{
cid->cd->accept(this);
}

void visit(TypeInfoDeclaration *tid)
{
//printf("TypeInfoDeclaration::toSymbol(%s), linkage = %d\n", tid->toChars(), tid->linkage);
Expand Down
2 changes: 0 additions & 2 deletions src/visitor.h
Expand Up @@ -127,7 +127,6 @@ class AliasDeclaration;
class OverDeclaration;
class VarDeclaration;
class SymbolDeclaration;
class ClassInfoDeclaration;
class ThisDeclaration;

class TypeInfoDeclaration;
Expand Down Expand Up @@ -414,7 +413,6 @@ class Visitor
virtual void visit(OverDeclaration *s) { visit((Declaration *)s); }
virtual void visit(VarDeclaration *s) { visit((Declaration *)s); }
virtual void visit(SymbolDeclaration *s) { visit((Declaration *)s); }
virtual void visit(ClassInfoDeclaration *s) { visit((VarDeclaration *)s); }
virtual void visit(ThisDeclaration *s) { visit((VarDeclaration *)s); }

virtual void visit(TypeInfoDeclaration *s) { visit((VarDeclaration *)s); }
Expand Down

0 comments on commit 9b11ed7

Please sign in to comment.