LEFT | RIGHT |
(no file at all) | |
| 1 |
| 2 var Tester; |
| 3 var stdkeywords; |
| 4 |
| 5 (function(global){ |
| 6 "use strict"; |
| 7 |
| 8 stdkeywords.keywords.forEach(function(word) { |
| 9 var program = 'var ' + word + ' = 1;'; |
| 10 Tester.badProgram('Keywords (7.6.1.1) ', |
| 11 program); |
| 12 Tester.badProgram('Keywords (7.6.1.1) ', |
| 13 '"use strict"; ' + program); |
| 14 }); |
| 15 |
| 16 stdkeywords.reserved.forEach(function(word) { |
| 17 var program = 'var ' + word + ' = 1;'; |
| 18 Tester.badProgram('Future Reserved Words (7.6.1.2) ', |
| 19 program); |
| 20 Tester.badProgram('Future Reserved Words (7.6.1.2) ', |
| 21 '"use strict"; ' + program); |
| 22 }); |
| 23 |
| 24 stdkeywords.strictReserved.forEach(function(word) { |
| 25 var program = 'var ' + word + ' = 1;'; |
| 26 Tester.goodProgram('Future Reserved Words (7.6.1.2) ', |
| 27 program); |
| 28 Tester.badProgram('Future Reserved Words (7.6.1.2) ', |
| 29 '"use strict"; ' + program); |
| 30 }); |
| 31 |
| 32 stdkeywords.unreserved.forEach(function(word) { |
| 33 var program = 'var ' + word + ' = 1;'; |
| 34 Tester.goodProgram('Reserved Words (7.6.1) ', |
| 35 program); |
| 36 Tester.goodProgram('Reserved Words (7.6.1) ', |
| 37 '"use strict"; ' + program); |
| 38 }); |
| 39 |
| 40 Object.keys(stdkeywords).forEach(function(kind) { |
| 41 stdkeywords[kind].forEach(function(word) { |
| 42 var program = '({' + word + ': 8})'; |
| 43 Tester.goodProgram('Object Initializer (11.1.5) ', |
| 44 program); |
| 45 Tester.goodProgram('Object Initializer (11.1.5) ', |
| 46 '"use strict"; ' + program); |
| 47 }); |
| 48 }); |
| 49 |
| 50 Object.keys(stdkeywords).forEach(function(kind) { |
| 51 stdkeywords[kind].forEach(function(word) { |
| 52 var program = 'x.' + word; |
| 53 Tester.goodProgram('Property Accessors (11.2.1) ', |
| 54 program); |
| 55 Tester.goodProgram('Property Accessors (11.2.1) ', |
| 56 '"use strict"; ' + program); |
| 57 }); |
| 58 }); |
| 59 |
| 60 })(this); |
LEFT | RIGHT |