@powerlang/egg-js
Version:
A Smalltalk VM that runs on top of JavaScript
40 lines (29 loc) • 550 B
JavaScript
import EggObject from './EggObject.js';
let EggSmallInteger = class extends EggObject {
constructor() {
super();
this._value = nil;
}
_equal(anObject) {
if (!anObject.class()._equalEqual(this.class()))
{
return false
}
;
return this._value._equal(anObject.value());
}
hash() {
return this._value.hash();
}
isImmediate() {
return true;
}
value() {
return this._value;
}
value_(anInteger) {
this._value = anInteger;
return this;
}
}
export default EggSmallInteger