michael@0: function testDeepPropertyShadowing() michael@0: { michael@0: function h(node) { michael@0: var x = 0; michael@0: while (node) { michael@0: x++; michael@0: node = node.parent; michael@0: } michael@0: return x; michael@0: } michael@0: var tree = {__proto__: {__proto__: {parent: null}}}; michael@0: h(tree); michael@0: h(tree); michael@0: tree.parent = {}; michael@0: assertEq(h(tree), 2); michael@0: } michael@0: testDeepPropertyShadowing();