Instantly share code, notes, and snippets.

Embed
What would you like to do?
/* INLINED CODE */
function doSomething(x, y) {
// o1.add called with o2 as
// its `this` binding.
return o1.add(x, y);
}
@arty-name

This comment has been minimized.

arty-name commented Oct 11, 2014

Shouldn't it be o2.add(x, y) here? ;)

@jdalton

This comment has been minimized.

Owner

jdalton commented Oct 16, 2014

We wanted to avoid saying o2.add as that implies the add method of o2.
This is why the code comment states that it's o1.add called with o2 as its this binding.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment