mirror of
https://github.com/corda/corda.git
synced 2025-03-24 04:55:32 +00:00
remove redundant Compiler::truncate srcType parameter
This commit is contained in:
parent
3029bb2d7e
commit
e3d01746e8
@ -110,8 +110,7 @@ class Compiler {
|
||||
ir::Type truncateType,
|
||||
ir::Value* src) = 0;
|
||||
|
||||
virtual ir::Value* truncate(ir::Type type, ir::Type srcType, ir::Value* src)
|
||||
= 0;
|
||||
virtual ir::Value* truncate(ir::Type type, ir::Value* src) = 0;
|
||||
|
||||
virtual void store(ir::Type srcType, ir::Value* src, ir::Value* dst) = 0;
|
||||
virtual ir::Value* load(ir::SignExtendMode signExtend,
|
||||
|
@ -2560,17 +2560,16 @@ class MyCompiler: public Compiler {
|
||||
static_cast<Value*>(index), handler);
|
||||
}
|
||||
|
||||
virtual ir::Value* truncate(ir::Type type, ir::Type srcType, ir::Value* src)
|
||||
virtual ir::Value* truncate(ir::Type type, ir::Value* src)
|
||||
{
|
||||
assert(&c, srcType == src->type);
|
||||
assert(&c, src->type.flavor() == type.flavor());
|
||||
assert(&c, type.flavor() != ir::Type::Float);
|
||||
assert(&c, type.size() < src->type.size());
|
||||
Value* dst = value(&c, type);
|
||||
appendMove(&c,
|
||||
lir::Move,
|
||||
srcType.size(),
|
||||
srcType.size(),
|
||||
src->type.size(),
|
||||
src->type.size(),
|
||||
static_cast<Value*>(src),
|
||||
type.size(),
|
||||
dst);
|
||||
|
@ -5329,7 +5329,7 @@ compile(MyThread* t, Frame* initialFrame, unsigned initialIp,
|
||||
} break;
|
||||
|
||||
case l2i:
|
||||
frame->pushInt(c->truncate(types.i4, types.i8, frame->popLong()));
|
||||
frame->pushInt(c->truncate(types.i4, frame->popLong()));
|
||||
break;
|
||||
|
||||
case ladd:
|
||||
|
Loading…
x
Reference in New Issue
Block a user