mirror of
https://github.com/dart-lang/sdk
synced 2024-09-18 21:01:20 +00:00
dart2js cps: Remove receiverIsNotNull from CPS nodes.
BUG= R=kmillikin@google.com Review URL: https://codereview.chromium.org/1747213002 .
This commit is contained in:
parent
d2e1a2ce3c
commit
dbaf47de5e
|
@ -124,7 +124,6 @@ class CpsFragment {
|
|||
{bool receiverIsNotNull: false}) {
|
||||
ApplyBuiltinMethod apply =
|
||||
new ApplyBuiltinMethod(method, receiver, arguments, sourceInformation);
|
||||
apply.receiverIsNotNull = receiverIsNotNull;
|
||||
return letPrim(apply);
|
||||
}
|
||||
|
||||
|
|
|
@ -638,9 +638,6 @@ class InvokeMethod extends InvocationPrimitive {
|
|||
: receiverRef;
|
||||
}
|
||||
|
||||
/// If true, it is known that the receiver cannot be `null`.
|
||||
bool receiverIsNotNull = false;
|
||||
|
||||
InvokeMethod(Primitive receiver,
|
||||
this.selector,
|
||||
this.mask,
|
||||
|
@ -1159,13 +1156,10 @@ class ApplyBuiltinMethod extends Primitive {
|
|||
Primitive argument(int n) => argumentRefs[n].definition;
|
||||
Iterable<Primitive> get arguments => _dereferenceList(argumentRefs);
|
||||
|
||||
bool receiverIsNotNull;
|
||||
|
||||
ApplyBuiltinMethod(this.method,
|
||||
Primitive receiver,
|
||||
List<Primitive> arguments,
|
||||
this.sourceInformation,
|
||||
{this.receiverIsNotNull: false})
|
||||
this.sourceInformation)
|
||||
: this.receiverRef = new Reference<Primitive>(receiver),
|
||||
this.argumentRefs = _referenceList(arguments);
|
||||
|
||||
|
@ -2950,8 +2944,7 @@ class DefinitionCopyingVisitor extends Visitor<Definition> {
|
|||
Definition visitApplyBuiltinMethod(ApplyBuiltinMethod node) {
|
||||
return new ApplyBuiltinMethod(node.method, getCopy(node.receiverRef),
|
||||
getList(node.argumentRefs),
|
||||
node.sourceInformation,
|
||||
receiverIsNotNull: node.receiverIsNotNull);
|
||||
node.sourceInformation);
|
||||
}
|
||||
|
||||
Definition visitGetLength(GetLength node) {
|
||||
|
|
|
@ -2776,7 +2776,6 @@ class TypePropagationVisitor implements Visitor {
|
|||
|
||||
void visitInvokeMethod(InvokeMethod node) {
|
||||
AbstractConstantValue receiver = getValue(node.dartReceiver);
|
||||
node.receiverIsNotNull = receiver.isDefinitelyNotNull;
|
||||
if (receiver.isNothing) {
|
||||
return setResult(node, lattice.nothing);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue