mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-07-28 03:25:23 +00:00
Add more support for new style casts
Convert more code to use them git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@695 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -225,7 +225,7 @@ ExprType analysis::ClassifyExpression(Value *Expr) {
|
||||
case Value::MethodArgumentVal: // nothing known, return variable itself
|
||||
return Expr;
|
||||
case Value::ConstantVal: // Constant value, just return constant
|
||||
ConstPoolVal *CPV = Expr->castConstantAsserting();
|
||||
ConstPoolVal *CPV = cast<ConstPoolVal>(Expr);
|
||||
if (CPV->getType()->isIntegral()) { // It's an integral constant!
|
||||
ConstPoolInt *CPI = (ConstPoolInt*)Expr;
|
||||
return ExprType(CPI->equalsInt(0) ? 0 : CPI);
|
||||
|
Reference in New Issue
Block a user