1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
let a = { bar: 1 }; let b = { quux: 2 }; let foo = function* bar(x) { b.quux; // ^ defined: 2 // ^ defined: 2 bar; // ^ defined: 4 yield x; // ^ defined: 4 }; foo(a).bar; // ^ defined: 1