3 ms·
> the 'this' has a very specific value even though you did not pass in an argument of that name nor did you ever assign a value to a local variable of that name
by munificent 3y ago
> the 'this' has a very specific value even though you did not pass in an argument of that name nor did you ever assign a value to a local variable of that name.
It's just an implicit parameter named `this` whose argument happens to appear to the left of the `.` instead of after the `(`. Yes, there's a little extra work in the language to support this, but it's not particularly complex or deep semantically.
(In fact `this` is particularly semantically shallow in JavaScript because as your example notes, it's not even bound when a reference to a method is taken. In most other languages, `myOb.funk` will give you a function that partially applies `this`.)