Lines Matching refs:obj
30 var accessorCallCount, setterArgument, setterValue, obj, forceDeopt; variable
35 function TestInlinedGetter(context, obj, expected) { argument
39 assertEquals(expected, context(obj));
42 assertEquals(expected, context(obj));
46 assertEquals(expected, context(obj));
50 assertEquals(expected, context(obj));
55 function value_context_for_getter(obj) { argument
56 return obj.getterProperty;
59 function test_context_for_getter(obj) { argument
60 if (obj.getterProperty) {
67 function effect_context_for_getter(obj) { argument
68 obj.getterProperty;
72 function TryGetter(context, getter, obj, expected, expectException) { argument
74 TestInlinedGetter(context, obj, expected);
85 function TestGetterInAllContexts(getter, obj, expected, expectException) { argument
86 TryGetter(value_context_for_getter, getter, obj, expected, expectException);
87 TryGetter(test_context_for_getter, getter, obj, expected ? 111 : 222,
89 TryGetter(effect_context_for_getter, getter, obj, 5678, expectException);
96 assertSame(obj, this);
103 obj = Object.defineProperty(new ConstrG1(), "getterProperty", { get: getter1 });
104 TestGetterInAllContexts(getter1, obj, 1234, false);
105 obj = Object.create(obj);
106 TestGetterInAllContexts(getter1, obj, 1234, false);
112 assertSame(obj, this);
119 obj = Object.defineProperty(new ConstrG2(), "getterProperty", { get: getter2 });
120 TestGetterInAllContexts(getter2, obj, false, false);
121 obj = Object.create(obj);
122 TestGetterInAllContexts(getter2, obj, false, false);
128 assertSame(obj, this);
134 obj = Object.defineProperty(new ConstrG3(), "getterProperty", { get: getter3 });
135 TestGetterInAllContexts(getter3, obj, undefined, false);
136 obj = Object.create(obj);
137 TestGetterInAllContexts(getter3, obj, undefined, false);
143 assertSame(obj, this);
150 obj = Object.defineProperty(new ConstrG4(), "getterProperty", { get: getter4 });
151 TestGetterInAllContexts(getter4, obj, undefined, false);
152 obj = Object.create(obj);
153 TestGetterInAllContexts(getter4, obj, undefined, false);
159 assertSame(obj, this);
167 obj = Object.defineProperty(new ConstrG5(), "getterProperty", { get: getter5 });
168 TestGetterInAllContexts(getter5, obj, 9876, false);
169 obj = Object.create(obj);
170 TestGetterInAllContexts(getter5, obj, 9876, false);
176 assertSame(obj, this);
184 obj = Object.defineProperty(new ConstrG6(), "getterProperty", { get: getter6 });
185 TestGetterInAllContexts(getter6, obj, 13579, true);
186 obj = Object.create(obj);
187 TestGetterInAllContexts(getter6, obj, 13579, true);
192 function TestInlinedSetter(context, obj, value, expected) { argument
197 assertEquals(expected, context(obj, value));
201 assertEquals(expected, context(obj, value));
206 assertEquals(expected, context(obj, value));
211 assertEquals(expected, context(obj, value));
216 function value_context_for_setter(obj, value) { argument
217 return obj.setterProperty = value;
220 function test_context_for_setter(obj, value) { argument
221 if (obj.setterProperty = value) {
228 function effect_context_for_setter(obj, value) { argument
229 obj.setterProperty = value;
233 function TrySetter(context, setter, obj, expectException, value, expected) { argument
235 TestInlinedSetter(context, obj, value, expected);
246 function TestSetterInAllContexts(setter, obj, expectException) { argument
247 TrySetter(value_context_for_setter, setter, obj, expectException, 111, 111);
248 TrySetter(test_context_for_setter, setter, obj, expectException, true, 333);
249 TrySetter(test_context_for_setter, setter, obj, expectException, false, 444);
250 TrySetter(effect_context_for_setter, setter, obj, expectException, 555, 666);
257 assertSame(obj, this);
264 obj = Object.defineProperty(new ConstrS1(), "setterProperty", { set: setter1 });
265 TestSetterInAllContexts(setter1, obj, false);
266 obj = Object.create(obj);
267 TestSetterInAllContexts(setter1, obj, false);
273 assertSame(obj, this);
281 obj = Object.defineProperty(new ConstrS2(), "setterProperty", { set: setter2 });
282 TestSetterInAllContexts(setter2, obj, false);
283 obj = Object.create(obj);
284 TestSetterInAllContexts(setter2, obj, false);
290 assertSame(obj, this);
297 obj = Object.defineProperty(new ConstrS3(), "setterProperty", { set: setter3 });
298 TestSetterInAllContexts(setter3, obj, false);
299 obj = Object.create(obj);
300 TestSetterInAllContexts(setter3, obj, false);
306 assertSame(obj, this);
314 obj = Object.defineProperty(new ConstrS4(), "setterProperty", { set: setter4 });
315 TestSetterInAllContexts(setter4, obj, false);
316 obj = Object.create(obj);
317 TestSetterInAllContexts(setter4, obj, false);
323 assertSame(obj, this);
331 obj = Object.defineProperty(new ConstrS5(), "setterProperty", { set: setter5 });
332 TestSetterInAllContexts(setter5, obj, false);
333 obj = Object.create(obj);
334 TestSetterInAllContexts(setter5, obj, false);
340 assertSame(obj, this);
349 obj = Object.defineProperty(new ConstrS6(), "setterProperty", { set: setter6 });
350 TestSetterInAllContexts(setter6, obj, false);
351 obj = Object.create(obj);
352 TestSetterInAllContexts(setter6, obj, false);
365 obj = Object.defineProperty(new ConstrS7(), "setterProperty", { set: setter7 });
366 TestSetterInAllContexts(setter7, obj, true);
367 obj = Object.create(obj);
368 TestSetterInAllContexts(setter7, obj, true);