UNPKG

@powerlang/egg-js

Version:

A Smalltalk VM that runs on top of JavaScript

40 lines (28 loc) 666 B
import SBinding from './SBinding.js'; let SInstVarBinding = class extends SBinding { constructor() { super(); this._index = nil; } static decodeUsing_(aTreecodeDecoder) { return aTreecodeDecoder.decodeInstVar(); } assign_within_(value, anEvaluationContext) { anEvaluationContext.instanceVarAt_put_(this._index, value); return this; } index() { return this._index; } index_(anInteger) { this._index = anInteger; return this; } isInstVar() { return true; } valueWithin_(anEvaluationContext) { return anEvaluationContext.instanceVarAt_(this._index); } } export default SInstVarBinding