Skip to content

Commit

Permalink
Merge pull request jashkenas#2587 from sstur/pullreq
Browse files Browse the repository at this point in the history
Simplify Call.prototype.compileSplat based on how Traceur does it
  • Loading branch information
jashkenas committed Oct 16, 2012
2 parents d8905e2 + 25bdde8 commit b06a326
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/nodes.coffee
Expand Up @@ -606,8 +606,8 @@ exports.Call = class Call extends Base
return """
(function(func, args, ctor) {
#{idt}ctor.prototype = func.prototype;
#{idt}var child = new ctor, result = func.apply(child, args), t = typeof result;
#{idt}return t == "object" || t == "function" ? result || child : child;
#{idt}var child = new ctor, result = func.apply(child, args);
#{idt}return Object(result) === result ? result : child;
#{@tab}})(#{ @variable.compile o, LEVEL_LIST }, #{splatArgs}, function(){})
"""
base = new Value @variable
Expand Down

0 comments on commit b06a326

Please sign in to comment.