mirror of
https://github.com/xomboverlord/ldc.git
synced 2026-01-20 14:53:14 +01:00
Fixed AddrExp might silently change the type of its value, but we weren't casting to compensate ... why doesn't DMD insert a cast?
This commit is contained in:
@@ -854,7 +854,7 @@ DValue* AddrExp::toElem(IRState* p)
|
||||
Logger::println("is nothing special");
|
||||
LLValue* lval = v->getLVal();
|
||||
Logger::cout() << "lval: " << *lval << '\n';
|
||||
return new DImValue(type, v->getLVal());
|
||||
return new DImValue(type, DtoBitCast(v->getLVal(), DtoType(type)));
|
||||
}
|
||||
|
||||
LLConstant* AddrExp::toConstElem(IRState* p)
|
||||
|
||||
Reference in New Issue
Block a user