Issue #641. Rename __superClass__ to __super__

This commit is contained in:
Jeremy Ashkenas
2010-08-23 21:19:43 -04:00
parent 1b88d18d61
commit bd3471b3d1
3 changed files with 43 additions and 43 deletions

View File

@@ -431,9 +431,9 @@ exports.CallNode = class CallNode extends BaseNode
superReference: (o) ->
methname = o.scope.method.name
meth = if o.scope.method.proto
"#{o.scope.method.proto}.__superClass__.#{methname}"
"#{o.scope.method.proto}.__super__.#{methname}"
else if methname
"#{methname}.__superClass__.constructor"
"#{methname}.__super__.constructor"
else throw new Error "cannot call super on an anonymous function."
# Compile a vanilla function call.
@@ -1571,7 +1571,7 @@ UTILITIES =
child.prototype = new ctor();
child.prototype.constructor = child;
if (typeof parent.extended === "function") parent.extended(child);
child.__superClass__ = parent.prototype;
child.__super__ = parent.prototype;
}
"""