gingerBill 7 years ago
parent
commit
e2600a3e44
1 changed files with 1 additions and 0 deletions
  1. 1 0
      src/check_decl.cpp

+ 1 - 0
src/check_decl.cpp

@@ -254,6 +254,7 @@ void check_const_decl(Checker *c, Entity *e, AstNode *type_expr, AstNode *init,
 		switch (operand.mode) {
 		switch (operand.mode) {
 		case Addressing_Type: {
 		case Addressing_Type: {
 			e->kind = Entity_TypeName;
 			e->kind = Entity_TypeName;
+			e->type = nullptr;
 
 
 			DeclInfo *d = c->context.decl;
 			DeclInfo *d = c->context.decl;
 			if (d->type_expr != nullptr) {
 			if (d->type_expr != nullptr) {