-
Notifications
You must be signed in to change notification settings - Fork 7.3k
Conversation
exports.lookup = function(domain, family, callback) { | ||
exports.lookup = function(domain, family_, callback_) { | ||
var family = family_, | ||
callback = callback; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should this be callback = callback_
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, sorry.
I thought v8 could still optimize writes to named function arguments, but couldn't handle writes to |
It can't optimize any function that contains any usage of |
I was also under this impression. I know writing to |
Hmm, only says when you also use |
Ah, the problem is that is also reads |
Using `arguments` and reassigning parameter variable values causes v8 to disable function optimization.
@mscdex ... is this still something you think needs to be done in v0.10? |
@jasnell Well, it's an optimization. If anything it might make lookups a tad faster. If it doesn't apply cleanly to v0.10 anymore I guess I wouldn't worry about it. |
So long as CI passes, LGTM |
Using `arguments` and reassigning parameter variable values causes v8 to disable function optimization. PR-URL: #8942 Reviewed-By: jasnell - James M Snell <[email protected]>
Landed in 6502160 |
Reassigning the values of parameter variables causes
v8 to disable function optimization.