Mercurial > projects > ldc
changeset 397:9ec89aad9dbc
Make an unresolved global into an error instead of an assert.
Fixes nocompile/alias_28_A/F.
author | Christian Kamm <kamm incasoftware de> |
---|---|
date | Sat, 26 Jul 2008 15:23:15 +0200 |
parents | b0feb180ce55 |
children | 811f82dfddbd |
files | gen/toir.cpp |
diffstat | 1 files changed, 3 insertions(+), 3 deletions(-) [+] |
line wrap: on
line diff
--- a/gen/toir.cpp Sat Jul 26 15:12:48 2008 +0200 +++ b/gen/toir.cpp Sat Jul 26 15:23:15 2008 +0200 @@ -244,9 +244,9 @@ DtoConstInitGlobal(vd); } if (!vd->ir.getIrValue() || DtoType(vd->type)->isAbstract()) { - Logger::println("global variable not resolved :/ %s", vd->toChars()); - Logger::cout() << *DtoType(vd->type) << '\n'; - assert(0); + error("global variable %s not resolved", vd->toChars()); + Logger::cout() << "unresolved global had type: " << *DtoType(vd->type) << '\n'; + fatal(); } return new DVarValue(vd, vd->ir.getIrValue(), true); }