comparison dmd/mtype.c @ 717:a26b0c5d5942

Merged DMD 1.036. Improved comments a little in the runtime source code.
author Tomas Lindquist Olsen <tomas.l.olsen@gmail.com>
date Wed, 22 Oct 2008 17:06:17 +0200
parents 30b42a283c8e
children e177ae483f8e
comparison
equal deleted inserted replaced
716:b654bb98d31d 717:a26b0c5d5942
4371 if (!s->isFuncDeclaration()) // because of overloading 4371 if (!s->isFuncDeclaration()) // because of overloading
4372 s->checkDeprecated(e->loc, sc); 4372 s->checkDeprecated(e->loc, sc);
4373 s = s->toAlias(); 4373 s = s->toAlias();
4374 4374
4375 v = s->isVarDeclaration(); 4375 v = s->isVarDeclaration();
4376 if (v && v->isConst()) 4376 if (v && v->isConst() && v->type->toBasetype()->ty != Tsarray)
4377 { ExpInitializer *ei = v->getExpInitializer(); 4377 { ExpInitializer *ei = v->getExpInitializer();
4378 4378
4379 if (ei) 4379 if (ei)
4380 { e = ei->exp->copy(); // need to copy it if it's a StringExp 4380 { e = ei->exp->copy(); // need to copy it if it's a StringExp
4381 e = e->semantic(sc); 4381 e = e->semantic(sc);
4779 } 4779 }
4780 if (!s->isFuncDeclaration()) // because of overloading 4780 if (!s->isFuncDeclaration()) // because of overloading
4781 s->checkDeprecated(e->loc, sc); 4781 s->checkDeprecated(e->loc, sc);
4782 s = s->toAlias(); 4782 s = s->toAlias();
4783 v = s->isVarDeclaration(); 4783 v = s->isVarDeclaration();
4784 if (v && v->isConst()) 4784 if (v && v->isConst() && v->type->toBasetype()->ty != Tsarray)
4785 { ExpInitializer *ei = v->getExpInitializer(); 4785 { ExpInitializer *ei = v->getExpInitializer();
4786 4786
4787 if (ei) 4787 if (ei)
4788 { e = ei->exp->copy(); // need to copy it if it's a StringExp 4788 { e = ei->exp->copy(); // need to copy it if it's a StringExp
4789 e = e->semantic(sc); 4789 e = e->semantic(sc);