在JavaScript中分配运算符优先级

时间:2019-04-04 12:56:17

标签: javascript assignment-operator operator-precedence

我有这种结构

let a = {x: 1}
let b = a
a.x = a = {y: 2}

您如何详细解释我如何获得这些结果?

a.x = undefined
a={y: 2}
b={x: {y: 2}}

0 个答案:

没有答案