mirror of
https://github.com/corda/corda.git
synced 2025-01-07 13:38:47 +00:00
remove Event::validate, since it is no longer needed and actually causes trouble
This commit is contained in:
parent
36dbf1ad14
commit
21cb1c3c8f
@ -55,8 +55,6 @@ class Site {
|
||||
|
||||
virtual void thaw(Context*) { }
|
||||
|
||||
virtual void validate(Context*, Stack*, unsigned, Value*) { }
|
||||
|
||||
virtual OperandType type(Context*) = 0;
|
||||
|
||||
virtual Assembler::Operand* asAssemblerOperand(Context*) = 0;
|
||||
@ -581,7 +579,12 @@ class RegisterSite: public Site {
|
||||
}
|
||||
|
||||
virtual void acquire(Context* c, Stack* stack, unsigned size, Value* v) {
|
||||
validate(c, stack, size, v);
|
||||
low = ::validate(c, mask, stack, size, v, this, low);
|
||||
if (size > BytesPerWord) {
|
||||
::freeze(low);
|
||||
high = ::validate(c, mask >> 32, stack, size, v, this, high);
|
||||
::thaw(low);
|
||||
}
|
||||
}
|
||||
|
||||
virtual void release(Context* c) {
|
||||
@ -611,15 +614,6 @@ class RegisterSite: public Site {
|
||||
}
|
||||
}
|
||||
|
||||
virtual void validate(Context* c, Stack* stack, unsigned size, Value* v) {
|
||||
low = ::validate(c, mask, stack, size, v, this, low);
|
||||
if (size > BytesPerWord) {
|
||||
::freeze(low);
|
||||
high = ::validate(c, mask >> 32, stack, size, v, this, high);
|
||||
::thaw(low);
|
||||
}
|
||||
}
|
||||
|
||||
virtual OperandType type(Context*) {
|
||||
return RegisterOperand;
|
||||
}
|
||||
@ -2196,7 +2190,6 @@ readSource(Context* c, Stack* stack, Read* r)
|
||||
apply(c, Move, r->size, site, target);
|
||||
return target;
|
||||
} else {
|
||||
site->validate(c, stack, r->size, r->value);
|
||||
return site;
|
||||
}
|
||||
}
|
||||
|
@ -89,7 +89,14 @@ public class Misc {
|
||||
return a + b + c;
|
||||
}
|
||||
|
||||
private static long roundUp(long a, long b) {
|
||||
a += b - 1L;
|
||||
return a - (a % b);
|
||||
}
|
||||
|
||||
public static void main(String[] args) {
|
||||
expect(roundUp(156, 2) == 156);
|
||||
|
||||
{ Foo foo = new Foo();
|
||||
int x = foo.a + foo.b + foo.c;
|
||||
bar(foo.a, foo.b, foo.c);
|
||||
|
Loading…
Reference in New Issue
Block a user