OLD | NEW |
1 // Copyright 2015 the V8 project authors. All rights reserved. | 1 // Copyright 2015 the V8 project authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 // Flags: --allow-natives-syntax --expose-debug-as debug | |
6 | 5 |
7 "use strict"; | 6 "use strict"; |
8 | 7 |
9 // Test non-JSObject receiver. | 8 // Test non-JSObject receiver. |
10 function f(o) { | 9 function f(o) { |
11 var result = []; | 10 var result = []; |
12 for (var i in o) { | 11 for (var i in o) { |
13 result.push(i); | 12 result.push(i); |
14 } | 13 } |
15 return result; | 14 return result; |
(...skipping 132 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
148 x = false; | 147 x = false; |
149 | 148 |
150 f5(); f5(); f5(); | 149 f5(); f5(); f5(); |
151 %OptimizeFunctionOnNextCall(f5); | 150 %OptimizeFunctionOnNextCall(f5); |
152 x = true; | 151 x = true; |
153 count = 0; | 152 count = 0; |
154 Debug.setListener(listener); | 153 Debug.setListener(listener); |
155 f5(); | 154 f5(); |
156 Debug.setListener(null); | 155 Debug.setListener(null); |
157 assertEquals(1, count); | 156 assertEquals(1, count); |
OLD | NEW |