Mercurial > projects > ldc
comparison gen/toir.cpp @ 611:83ca663ecc20
Backed out changeset 1b62222581fb
Do not use i8 for bool. Instead rely on the target to store i1 as i8.
author | Christian Kamm <kamm incasoftware de> |
---|---|
date | Sun, 21 Sep 2008 14:45:41 +0200 |
parents | 1b62222581fb |
children | 5ced42a55aa9 |
comparison
equal
deleted
inserted
replaced
610:1b62222581fb | 611:83ca663ecc20 |
---|---|
1647 | 1647 |
1648 DValue* u = e1->toElem(p); | 1648 DValue* u = e1->toElem(p); |
1649 | 1649 |
1650 LLValue* b = DtoBoolean(loc, u); | 1650 LLValue* b = DtoBoolean(loc, u); |
1651 | 1651 |
1652 LLConstant* zero = llvm::ConstantInt::get(b->getType(), 0); | 1652 LLConstant* zero = DtoConstBool(false); |
1653 b = p->ir->CreateICmpEQ(b,zero); | 1653 b = p->ir->CreateICmpEQ(b,zero); |
1654 | 1654 |
1655 return new DImValue(type, b); | 1655 return new DImValue(type, b); |
1656 } | 1656 } |
1657 | 1657 |