feat(RecordRange): Set context for implicit receivers only
This commit is contained in:
@ -42,7 +42,7 @@ export class ProtoRecord {
|
||||
dest) {
|
||||
|
||||
this.recordRange = recordRange;
|
||||
this.mode = mode;
|
||||
this._mode = mode;
|
||||
this.funcOrValue = funcOrValue;
|
||||
this.arity = arity;
|
||||
this.dest = dest;
|
||||
@ -52,6 +52,10 @@ export class ProtoRecord {
|
||||
// The concrete Record instantiated from this ProtoRecord
|
||||
this.recordInConstruction = null;
|
||||
}
|
||||
|
||||
setIsImplicitReceiver() {
|
||||
this._mode |= RECORD_FLAG_IMPLICIT_RECEIVER;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@ -117,7 +121,7 @@ export class Record {
|
||||
return;
|
||||
}
|
||||
|
||||
this._mode = protoRecord.mode;
|
||||
this._mode = protoRecord._mode;
|
||||
|
||||
var type = this.type;
|
||||
|
||||
@ -160,6 +164,10 @@ export class Record {
|
||||
}
|
||||
}
|
||||
|
||||
get isImplicitReceiver() {
|
||||
return (this._mode & RECORD_FLAG_IMPLICIT_RECEIVER) === RECORD_FLAG_IMPLICIT_RECEIVER;
|
||||
}
|
||||
|
||||
static createMarker(rr:RecordRange) {
|
||||
return new Record(rr, null, null);
|
||||
}
|
||||
|
Reference in New Issue
Block a user