mirror of
https://github.com/jashkenas/coffeescript.git
synced 2026-02-18 19:34:27 -05:00
made --nodes output soak-aware
This commit is contained in:
@@ -103,7 +103,7 @@
|
||||
return this.traverseChildren(true, block);
|
||||
};
|
||||
BaseNode.prototype.toString = function(idt, override) {
|
||||
var _i, _len, _ref2, _result, child, children;
|
||||
var _i, _len, _ref2, _result, child, children, klass;
|
||||
idt || (idt = '');
|
||||
children = (function() {
|
||||
_result = []; _ref2 = this.collectChildren();
|
||||
@@ -113,7 +113,8 @@
|
||||
}
|
||||
return _result;
|
||||
}).call(this).join('');
|
||||
return '\n' + idt + (override || this["class"]) + children;
|
||||
klass = override || this["class"] + (this.soakNode || this.exist ? '?' : '');
|
||||
return '\n' + idt + klass + children;
|
||||
};
|
||||
BaseNode.prototype.eachChild = function(func) {
|
||||
var _i, _j, _len, _len2, _ref2, _ref3, _result, attr, child;
|
||||
@@ -1302,7 +1303,7 @@
|
||||
};
|
||||
OpNode.prototype.isMutator = function() {
|
||||
var _ref2;
|
||||
return ends(this.operator, '=') && !(('===' === (_ref2 = this.operator) || '!==' === _ref2));
|
||||
return ends(this.operator, '=') && !('===' === (_ref2 = this.operator) || '!==' === _ref2);
|
||||
};
|
||||
OpNode.prototype.isChainable = function() {
|
||||
return include(this.CHAINABLE, this.operator);
|
||||
|
||||
Reference in New Issue
Block a user