标签: javascript
假设我有这个对象:
var a = { b: 42, c: function() { return this; } } console.log((a.c)()); console.log((a.c || [])());
为什么this的返回值(绑定到(a.c)()的对象)与(a.c || [])()不同?
this
(a.c)()
(a.c || [])()