Merge branch 'master' of github.com:jashkenas/coffee-script

This commit is contained in:
Jeremy Ashkenas
2010-10-04 23:21:22 -04:00
3 changed files with 11 additions and 15 deletions

View File

@@ -827,7 +827,7 @@
join = '';
}
indent = prop instanceof CommentNode ? '' : this.idt(1);
if (prop instanceof ValueNode && prop.tags['this']) {
if (prop instanceof ValueNode && prop.tags["this"]) {
prop = new AssignNode(prop.properties[0].name, prop, 'object');
} else if (!(prop instanceof AssignNode) && !(prop instanceof CommentNode)) {
prop = new AssignNode(prop, prop, 'object');
@@ -1033,7 +1033,7 @@
if (obj instanceof AssignNode) {
_ref2 = obj, idx = _ref2.variable.base, obj = _ref2.value;
} else {
idx = isObject ? obj : literal(0);
idx = isObject ? (obj.tags["this"] ? obj.properties[0].name : obj) : literal(0);
}
if (!(value instanceof ValueNode)) {
value = new ValueNode(value);
@@ -1056,11 +1056,7 @@
if (obj instanceof AssignNode) {
_ref2 = [obj.value, obj.variable.base], obj = _ref2[0], idx = _ref2[1];
} else {
if (obj.tags['this']) {
idx = obj.properties[0].name;
} else {
idx = obj;
}
idx = obj.tags["this"] ? obj.properties[0].name : obj;
}
}
if (!(obj instanceof ValueNode || obj instanceof SplatNode)) {