| 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: --strong-mode --allow-natives-syntax | 5 // Flags: --strong-mode --allow-natives-syntax |
| 6 // Flags: --harmony-rest-parameters | |
| 7 // Flags: --harmony-destructuring-bind | 6 // Flags: --harmony-destructuring-bind |
| 8 | 7 |
| 9 'use strict'; | 8 'use strict'; |
| 10 | 9 |
| 11 (function WeakObjectLiterals() { | 10 (function WeakObjectLiterals() { |
| 12 function assertWeakObject(x) { | 11 function assertWeakObject(x) { |
| 13 assertFalse(%IsStrong(x)); | 12 assertFalse(%IsStrong(x)); |
| 14 assertSame(Object.prototype, Object.getPrototypeOf(x)); | 13 assertSame(Object.prototype, Object.getPrototypeOf(x)); |
| 15 } | 14 } |
| 16 assertWeakObject({}); | 15 assertWeakObject({}); |
| (...skipping 266 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 283 })(); | 282 })(); |
| 284 | 283 |
| 285 (function StrongRegExpLiterals() { | 284 (function StrongRegExpLiterals() { |
| 286 'use strong'; | 285 'use strong'; |
| 287 function assertStrongRegExp(x) { | 286 function assertStrongRegExp(x) { |
| 288 // TODO(rossberg): strongify regexps | 287 // TODO(rossberg): strongify regexps |
| 289 // assertTrue(%IsStrong(x)); | 288 // assertTrue(%IsStrong(x)); |
| 290 } | 289 } |
| 291 assertStrongRegExp(/abc/); | 290 assertStrongRegExp(/abc/); |
| 292 })(); | 291 })(); |
| OLD | NEW |