Merged DMD commit c32334150595c1d5423f6bee2c45662fb76d6502:

bugzilla 4873 Assertion failure: '0' on line 1483 in file 'expression.c'
This commit is contained in:
David Nadlinger
2011-04-22 15:09:12 +02:00
parent e092bd00df
commit 61ce67ad14

View File

@@ -1,8 +1,9 @@
// Copyright (c) 1999-2007 by Digital Mars
// Copyright (c) 1999-2010 by Digital Mars
// All Rights Reserved
// written by Walter Bright
// http://www.digitalmars.com
// http://www.dsource.org/projects/dmd/browser/branches/dmd-1.x/src/staticassert.c
// License for redistribution is by either the Artistic License
// in artistic.txt, or the GNU General Public License in gnu.txt.
// See the included readme.txt for details.
@@ -55,6 +56,8 @@ void StaticAssert::semantic2(Scope *sc)
//printf("StaticAssert::semantic2() %s\n", toChars());
e = exp->semantic(sc);
if (e->op == TOKerror)
return;
e = e->optimize(WANTvalue | WANTinterpret);
if (e->isBool(FALSE))
{