Ben Murdoch | b8a8cc1 | 2014-11-26 15:28:44 +0000 | [diff] [blame] | 1 | // Copyright 2014 the V8 project authors. All rights reserved. |
| 2 | // Use of this source code is governed by a BSD-style license that can be |
| 3 | // found in the LICENSE file. |
| 4 | |
Ben Murdoch | 4a90d5f | 2016-03-22 12:00:34 +0000 | [diff] [blame] | 5 | // Flags: --lazy |
Ben Murdoch | b8a8cc1 | 2014-11-26 15:28:44 +0000 | [diff] [blame] | 6 | |
| 7 | function foo(a, b, c, d) { |
| 8 | "use strict" |
| 9 | const x = 10; |
| 10 | // long comment to trigger lazy compilation. |
| 11 | // long comment to trigger lazy compilation. |
| 12 | // long comment to trigger lazy compilation. |
| 13 | // long comment to trigger lazy compilation. |
| 14 | // long comment to trigger lazy compilation. |
| 15 | // long comment to trigger lazy compilation. |
| 16 | // long comment to trigger lazy compilation. |
| 17 | // long comment to trigger lazy compilation. |
| 18 | // long comment to trigger lazy compilation. |
| 19 | // long comment to trigger lazy compilation. |
| 20 | // long comment to trigger lazy compilation. |
| 21 | // long comment to trigger lazy compilation. |
| 22 | // long comment to trigger lazy compilation. |
| 23 | // long comment to trigger lazy compilation. |
| 24 | // long comment to trigger lazy compilation. |
| 25 | // long comment to trigger lazy compilation. |
| 26 | // long comment to trigger lazy compilation. |
| 27 | // long comment to trigger lazy compilation. |
| 28 | // long comment to trigger lazy compilation. |
| 29 | // long comment to trigger lazy compilation. |
| 30 | // long comment to trigger lazy compilation. |
| 31 | // long comment to trigger lazy compilation. |
| 32 | x = 20; // This will trigger compile error with harmony scoping. |
| 33 | } |
| 34 | |
| 35 | assertThrows("foo.length()"); |