diff --git a/package.json b/package.json index a874927de7..572be38078 100644 --- a/package.json +++ b/package.json @@ -20,5 +20,8 @@ "semver": "^5.0.0", "shelljs": "^0.5.1", "uglify-js": "^2.4.16" + }, + "dependencies": { + "mocha-fixtures": "^1.0.8" } } diff --git a/packages/babylon/test/_browser.js b/packages/babylon/test/_browser.js deleted file mode 100644 index c1bd732efb..0000000000 --- a/packages/babylon/test/_browser.js +++ /dev/null @@ -1,7 +0,0 @@ -if (process.browser) { - require("./tests"); - require("./tests-jsx"); - require("./tests-harmony"); - require("./tests-flow"); - require("./tests-babel"); -} diff --git a/packages/babylon/test/driver.js b/packages/babylon/test/driver.js deleted file mode 100755 index 940030201f..0000000000 --- a/packages/babylon/test/driver.js +++ /dev/null @@ -1,90 +0,0 @@ -var parse = require("../lib").parse; - -exports.test = function(code, ast, options) { - buildTest({code: code, ast: ast, options: options}); -}; - -exports.testFail = function(code, message, options) { - buildTest({code: code, error: message, options: options}); -}; - -exports.testAssert = function(code, assert, options) { - buildTest({code: code, assert: assert, options: options}); -}; - -function buildTest(config) { - test(config.code, function () { - return runTest(config); - }); -} - -function runTest(test) { - if (test.filter && !test.filter(test)) return; - var testOpts = test.options || {locations: true}; - var expected = {}; - if (expected.onComment = testOpts.onComment) - testOpts.onComment = [] - if (expected.onToken = testOpts.onToken) - testOpts.onToken = []; - - try { - var ast = parse(test.code, testOpts).program; - } catch (err) { - if (test.error) { - if (err.message === test.error) { - return; - } else { - err.message = "Expected error message: " + test.error + ". Got error message: " + err.message; - throw err; - } - } - - throw err; - } - - if (test.error) { - throw new Error("Expected error message: " + test.error + ". But parsing succeeded."); - } else if (test.assert) { - var error = test.assert(ast); - if (error) throw new Error("Assertion failed: " + error); - } else { - var mis = misMatch(test.ast, ast); - for (var name in expected) { - if (mis) break; - if (expected[name]) { - mis = misMatch(expected[name], testOpts[name]); - testOpts[name] = expected[name]; - } - } - if (mis) throw new Error(mis); - } -}; - -function ppJSON(v) { return v instanceof RegExp ? v.toString() : JSON.stringify(v, null, 2); } -function addPath(str, pt) { - if (str.charAt(str.length-1) == ")") - return str.slice(0, str.length-1) + "/" + pt + ")"; - return str + " (" + pt + ")"; -} - -var misMatch = exports.misMatch = function(exp, act) { - if (!exp || !act || (typeof exp != "object") || (typeof act != "object")) { - if (exp !== act && typeof exp != "function") - return ppJSON(exp) + " !== " + ppJSON(act); - } else if (exp instanceof RegExp || act instanceof RegExp) { - var left = ppJSON(exp), right = ppJSON(act); - if (left !== right) return left + " !== " + right; - } else if (exp.splice) { - if (!act.slice) return ppJSON(exp) + " != " + ppJSON(act); - if (act.length != exp.length) return "array length mismatch " + exp.length + " != " + act.length; - for (var i = 0; i < act.length; ++i) { - var mis = misMatch(exp[i], act[i]); - if (mis) return addPath(mis, i); - } - } else { - for (var prop in exp) { - var mis = misMatch(exp[prop], act[prop]); - if (mis) return addPath(mis, prop); - } - } -}; diff --git a/packages/babylon/test/fixtures/core/uncategorised/1/actual.js b/packages/babylon/test/fixtures/core/uncategorised/1/actual.js new file mode 100644 index 0000000000..9ecf3cf1d5 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/1/actual.js @@ -0,0 +1 @@ +this diff --git a/packages/babylon/test/fixtures/core/uncategorised/1/expected.json b/packages/babylon/test/fixtures/core/uncategorised/1/expected.json new file mode 100644 index 0000000000..809dfcce41 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/1/expected.json @@ -0,0 +1,48 @@ +{ + "type": "Program", + "start": 0, + "end": 4, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 4 + } + }, + "sourceType": "script", + "body": [ + { + "type": "ExpressionStatement", + "start": 0, + "end": 4, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 4 + } + }, + "expression": { + "type": "ThisExpression", + "start": 0, + "end": 4, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 4 + } + } + } + } + ] +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/10/actual.js b/packages/babylon/test/fixtures/core/uncategorised/10/actual.js new file mode 100644 index 0000000000..4a52d857d6 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/10/actual.js @@ -0,0 +1 @@ +x = [ 42, ] \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/10/expected.json b/packages/babylon/test/fixtures/core/uncategorised/10/expected.json new file mode 100644 index 0000000000..147130ce3a --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/10/expected.json @@ -0,0 +1,85 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "AssignmentExpression", + "operator": "=", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "right": { + "type": "ArrayExpression", + "elements": [ + { + "type": "Literal", + "value": 42, + "loc": { + "start": { + "line": 1, + "column": 6 + }, + "end": { + "line": 1, + "column": 8 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 11 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 11 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 11 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 11 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/100/actual.js b/packages/babylon/test/fixtures/core/uncategorised/100/actual.js new file mode 100644 index 0000000000..f9ac49bca7 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/100/actual.js @@ -0,0 +1,2 @@ +"Hello\ +world" \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/100/expected.json b/packages/babylon/test/fixtures/core/uncategorised/100/expected.json new file mode 100644 index 0000000000..d90f337fd7 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/100/expected.json @@ -0,0 +1,42 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "Literal", + "value": "Helloworld", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 2, + "column": 6 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 2, + "column": 6 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 2, + "column": 6 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/101/actual.js b/packages/babylon/test/fixtures/core/uncategorised/101/actual.js new file mode 100644 index 0000000000..d667033539 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/101/actual.js @@ -0,0 +1 @@ +"Hello\1World" \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/101/expected.json b/packages/babylon/test/fixtures/core/uncategorised/101/expected.json new file mode 100644 index 0000000000..3092c17c15 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/101/expected.json @@ -0,0 +1,42 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "Literal", + "value": "Hello\u0001World", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 14 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 14 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 14 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/102/actual.js b/packages/babylon/test/fixtures/core/uncategorised/102/actual.js new file mode 100644 index 0000000000..6bb56b4469 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/102/actual.js @@ -0,0 +1 @@ +var x = /[a-z]/i \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/102/expected.json b/packages/babylon/test/fixtures/core/uncategorised/102/expected.json new file mode 100644 index 0000000000..026237d552 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/102/expected.json @@ -0,0 +1,75 @@ +{ + "type": "Program", + "body": [ + { + "type": "VariableDeclaration", + "declarations": [ + { + "type": "VariableDeclarator", + "id": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "init": { + "type": "Literal", + "regex": { + "pattern": "[a-z]", + "flags": "i" + }, + "loc": { + "start": { + "line": 1, + "column": 8 + }, + "end": { + "line": 1, + "column": 16 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 16 + } + } + } + ], + "kind": "var", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 16 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 16 + } + } +} diff --git a/packages/babylon/test/fixtures/core/uncategorised/103/actual.js b/packages/babylon/test/fixtures/core/uncategorised/103/actual.js new file mode 100644 index 0000000000..9381588264 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/103/actual.js @@ -0,0 +1 @@ +var x = /[x-z]/i \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/103/expected.json b/packages/babylon/test/fixtures/core/uncategorised/103/expected.json new file mode 100644 index 0000000000..d9314c1c7b --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/103/expected.json @@ -0,0 +1,75 @@ +{ + "type": "Program", + "body": [ + { + "type": "VariableDeclaration", + "declarations": [ + { + "type": "VariableDeclarator", + "id": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "init": { + "type": "Literal", + "regex": { + "pattern": "[x-z]", + "flags": "i" + }, + "loc": { + "start": { + "line": 1, + "column": 8 + }, + "end": { + "line": 1, + "column": 16 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 16 + } + } + } + ], + "kind": "var", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 16 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 16 + } + } +} diff --git a/packages/babylon/test/fixtures/core/uncategorised/104/actual.js b/packages/babylon/test/fixtures/core/uncategorised/104/actual.js new file mode 100644 index 0000000000..71e179d728 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/104/actual.js @@ -0,0 +1 @@ +var x = /[a-c]/i \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/104/expected.json b/packages/babylon/test/fixtures/core/uncategorised/104/expected.json new file mode 100644 index 0000000000..3fa735a875 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/104/expected.json @@ -0,0 +1,75 @@ +{ + "type": "Program", + "body": [ + { + "type": "VariableDeclaration", + "declarations": [ + { + "type": "VariableDeclarator", + "id": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "init": { + "type": "Literal", + "regex": { + "pattern": "[a-c]", + "flags": "i" + }, + "loc": { + "start": { + "line": 1, + "column": 8 + }, + "end": { + "line": 1, + "column": 16 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 16 + } + } + } + ], + "kind": "var", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 16 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 16 + } + } +} diff --git a/packages/babylon/test/fixtures/core/uncategorised/105/actual.js b/packages/babylon/test/fixtures/core/uncategorised/105/actual.js new file mode 100644 index 0000000000..cc13baaedb --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/105/actual.js @@ -0,0 +1 @@ +var x = /[P QR]/i \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/105/expected.json b/packages/babylon/test/fixtures/core/uncategorised/105/expected.json new file mode 100644 index 0000000000..2f9fdd7610 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/105/expected.json @@ -0,0 +1,75 @@ +{ + "type": "Program", + "body": [ + { + "type": "VariableDeclaration", + "declarations": [ + { + "type": "VariableDeclarator", + "id": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "init": { + "type": "Literal", + "regex": { + "pattern": "[P QR]", + "flags": "i" + }, + "loc": { + "start": { + "line": 1, + "column": 8 + }, + "end": { + "line": 1, + "column": 17 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 17 + } + } + } + ], + "kind": "var", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 17 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 17 + } + } +} diff --git a/packages/babylon/test/fixtures/core/uncategorised/106/actual.js b/packages/babylon/test/fixtures/core/uncategorised/106/actual.js new file mode 100644 index 0000000000..dec7c26546 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/106/actual.js @@ -0,0 +1 @@ +var x = /foo\/bar/ \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/106/expected.json b/packages/babylon/test/fixtures/core/uncategorised/106/expected.json new file mode 100644 index 0000000000..6bf5845497 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/106/expected.json @@ -0,0 +1,75 @@ +{ + "type": "Program", + "body": [ + { + "type": "VariableDeclaration", + "declarations": [ + { + "type": "VariableDeclarator", + "id": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "init": { + "type": "Literal", + "regex": { + "pattern": "foo\\/bar", + "flags": "" + }, + "loc": { + "start": { + "line": 1, + "column": 8 + }, + "end": { + "line": 1, + "column": 18 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 18 + } + } + } + ], + "kind": "var", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 18 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 18 + } + } +} diff --git a/packages/babylon/test/fixtures/core/uncategorised/107/actual.js b/packages/babylon/test/fixtures/core/uncategorised/107/actual.js new file mode 100644 index 0000000000..3778fcff9e --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/107/actual.js @@ -0,0 +1 @@ +var x = /=([^=\s])+/g \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/107/expected.json b/packages/babylon/test/fixtures/core/uncategorised/107/expected.json new file mode 100644 index 0000000000..67dc4f80bf --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/107/expected.json @@ -0,0 +1,75 @@ +{ + "type": "Program", + "body": [ + { + "type": "VariableDeclaration", + "declarations": [ + { + "type": "VariableDeclarator", + "id": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "init": { + "type": "Literal", + "regex": { + "pattern": "=([^=\\s])+", + "flags": "g" + }, + "loc": { + "start": { + "line": 1, + "column": 8 + }, + "end": { + "line": 1, + "column": 21 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 21 + } + } + } + ], + "kind": "var", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 21 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 21 + } + } +} diff --git a/packages/babylon/test/fixtures/core/uncategorised/108/actual.js b/packages/babylon/test/fixtures/core/uncategorised/108/actual.js new file mode 100644 index 0000000000..270c2c52ab --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/108/actual.js @@ -0,0 +1 @@ +var x = /[P QR]/\u0067 \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/108/expected.json b/packages/babylon/test/fixtures/core/uncategorised/108/expected.json new file mode 100644 index 0000000000..745fbd2d94 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/108/expected.json @@ -0,0 +1,75 @@ +{ + "type": "Program", + "body": [ + { + "type": "VariableDeclaration", + "declarations": [ + { + "type": "VariableDeclarator", + "id": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "init": { + "type": "Literal", + "regex": { + "pattern": "[P QR]", + "flags": "g" + }, + "loc": { + "start": { + "line": 1, + "column": 8 + }, + "end": { + "line": 1, + "column": 22 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 22 + } + } + } + ], + "kind": "var", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 22 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 22 + } + } +} diff --git a/packages/babylon/test/fixtures/core/uncategorised/109/actual.js b/packages/babylon/test/fixtures/core/uncategorised/109/actual.js new file mode 100644 index 0000000000..187236da7a --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/109/actual.js @@ -0,0 +1 @@ +new Button \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/109/expected.json b/packages/babylon/test/fixtures/core/uncategorised/109/expected.json new file mode 100644 index 0000000000..9619d09764 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/109/expected.json @@ -0,0 +1,56 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "NewExpression", + "callee": { + "type": "Identifier", + "name": "Button", + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 10 + } + } + }, + "arguments": [], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 10 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 10 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 10 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/11/actual.js b/packages/babylon/test/fixtures/core/uncategorised/11/actual.js new file mode 100644 index 0000000000..18ce8c0881 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/11/actual.js @@ -0,0 +1 @@ +x = [ ,, 42 ] \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/11/expected.json b/packages/babylon/test/fixtures/core/uncategorised/11/expected.json new file mode 100644 index 0000000000..09fb5c230f --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/11/expected.json @@ -0,0 +1,87 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "AssignmentExpression", + "operator": "=", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "right": { + "type": "ArrayExpression", + "elements": [ + null, + null, + { + "type": "Literal", + "value": 42, + "loc": { + "start": { + "line": 1, + "column": 9 + }, + "end": { + "line": 1, + "column": 11 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 13 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 13 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 13 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 13 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/110/actual.js b/packages/babylon/test/fixtures/core/uncategorised/110/actual.js new file mode 100644 index 0000000000..a94b102062 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/110/actual.js @@ -0,0 +1 @@ +new Button() \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/110/expected.json b/packages/babylon/test/fixtures/core/uncategorised/110/expected.json new file mode 100644 index 0000000000..c084b798c6 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/110/expected.json @@ -0,0 +1,56 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "NewExpression", + "callee": { + "type": "Identifier", + "name": "Button", + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 10 + } + } + }, + "arguments": [], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 12 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 12 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 12 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/111/actual.js b/packages/babylon/test/fixtures/core/uncategorised/111/actual.js new file mode 100644 index 0000000000..3dba77c3c4 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/111/actual.js @@ -0,0 +1 @@ +new new foo \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/111/expected.json b/packages/babylon/test/fixtures/core/uncategorised/111/expected.json new file mode 100644 index 0000000000..041355249b --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/111/expected.json @@ -0,0 +1,70 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "NewExpression", + "callee": { + "type": "NewExpression", + "callee": { + "type": "Identifier", + "name": "foo", + "loc": { + "start": { + "line": 1, + "column": 8 + }, + "end": { + "line": 1, + "column": 11 + } + } + }, + "arguments": [], + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 11 + } + } + }, + "arguments": [], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 11 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 11 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 11 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/112/actual.js b/packages/babylon/test/fixtures/core/uncategorised/112/actual.js new file mode 100644 index 0000000000..4e860f60c7 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/112/actual.js @@ -0,0 +1 @@ +new new foo() \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/112/expected.json b/packages/babylon/test/fixtures/core/uncategorised/112/expected.json new file mode 100644 index 0000000000..5f522115f5 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/112/expected.json @@ -0,0 +1,70 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "NewExpression", + "callee": { + "type": "NewExpression", + "callee": { + "type": "Identifier", + "name": "foo", + "loc": { + "start": { + "line": 1, + "column": 8 + }, + "end": { + "line": 1, + "column": 11 + } + } + }, + "arguments": [], + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 13 + } + } + }, + "arguments": [], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 13 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 13 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 13 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/113/actual.js b/packages/babylon/test/fixtures/core/uncategorised/113/actual.js new file mode 100644 index 0000000000..f477838c33 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/113/actual.js @@ -0,0 +1 @@ +new foo().bar() \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/113/expected.json b/packages/babylon/test/fixtures/core/uncategorised/113/expected.json new file mode 100644 index 0000000000..1921ad4ea2 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/113/expected.json @@ -0,0 +1,98 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "CallExpression", + "callee": { + "type": "MemberExpression", + "object": { + "type": "NewExpression", + "callee": { + "type": "Identifier", + "name": "foo", + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 7 + } + } + }, + "arguments": [], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + "property": { + "type": "Identifier", + "name": "bar", + "loc": { + "start": { + "line": 1, + "column": 10 + }, + "end": { + "line": 1, + "column": 13 + } + } + }, + "computed": false, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 13 + } + } + }, + "arguments": [], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 15 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 15 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 15 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/114/actual.js b/packages/babylon/test/fixtures/core/uncategorised/114/actual.js new file mode 100644 index 0000000000..e860175116 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/114/actual.js @@ -0,0 +1 @@ +new foo[bar] \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/114/expected.json b/packages/babylon/test/fixtures/core/uncategorised/114/expected.json new file mode 100644 index 0000000000..8c7a8329e6 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/114/expected.json @@ -0,0 +1,84 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "NewExpression", + "callee": { + "type": "MemberExpression", + "object": { + "type": "Identifier", + "name": "foo", + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 7 + } + } + }, + "property": { + "type": "Identifier", + "name": "bar", + "loc": { + "start": { + "line": 1, + "column": 8 + }, + "end": { + "line": 1, + "column": 11 + } + } + }, + "computed": true, + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 12 + } + } + }, + "arguments": [], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 12 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 12 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 12 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/115/actual.js b/packages/babylon/test/fixtures/core/uncategorised/115/actual.js new file mode 100644 index 0000000000..0586f2b7e3 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/115/actual.js @@ -0,0 +1 @@ +new foo.bar() \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/115/expected.json b/packages/babylon/test/fixtures/core/uncategorised/115/expected.json new file mode 100644 index 0000000000..ea55e6febf --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/115/expected.json @@ -0,0 +1,84 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "NewExpression", + "callee": { + "type": "MemberExpression", + "object": { + "type": "Identifier", + "name": "foo", + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 7 + } + } + }, + "property": { + "type": "Identifier", + "name": "bar", + "loc": { + "start": { + "line": 1, + "column": 8 + }, + "end": { + "line": 1, + "column": 11 + } + } + }, + "computed": false, + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 11 + } + } + }, + "arguments": [], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 13 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 13 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 13 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/116/actual.js b/packages/babylon/test/fixtures/core/uncategorised/116/actual.js new file mode 100644 index 0000000000..0ff2def7f9 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/116/actual.js @@ -0,0 +1 @@ +( new foo).bar() \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/116/expected.json b/packages/babylon/test/fixtures/core/uncategorised/116/expected.json new file mode 100644 index 0000000000..ce81b7ca7e --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/116/expected.json @@ -0,0 +1,98 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "CallExpression", + "callee": { + "type": "MemberExpression", + "object": { + "type": "NewExpression", + "callee": { + "type": "Identifier", + "name": "foo", + "loc": { + "start": { + "line": 1, + "column": 6 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + "arguments": [], + "loc": { + "start": { + "line": 1, + "column": 2 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + "property": { + "type": "Identifier", + "name": "bar", + "loc": { + "start": { + "line": 1, + "column": 11 + }, + "end": { + "line": 1, + "column": 14 + } + } + }, + "computed": false, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 14 + } + } + }, + "arguments": [], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 16 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 16 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 16 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/117/actual.js b/packages/babylon/test/fixtures/core/uncategorised/117/actual.js new file mode 100644 index 0000000000..9f942f4032 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/117/actual.js @@ -0,0 +1 @@ +foo(bar, baz) \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/117/expected.json b/packages/babylon/test/fixtures/core/uncategorised/117/expected.json new file mode 100644 index 0000000000..94b30d5af9 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/117/expected.json @@ -0,0 +1,85 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "CallExpression", + "callee": { + "type": "Identifier", + "name": "foo", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 3 + } + } + }, + "arguments": [ + { + "type": "Identifier", + "name": "bar", + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 7 + } + } + }, + { + "type": "Identifier", + "name": "baz", + "loc": { + "start": { + "line": 1, + "column": 9 + }, + "end": { + "line": 1, + "column": 12 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 13 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 13 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 13 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/118/actual.js b/packages/babylon/test/fixtures/core/uncategorised/118/actual.js new file mode 100644 index 0000000000..507493b5a9 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/118/actual.js @@ -0,0 +1 @@ +( foo )() \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/118/expected.json b/packages/babylon/test/fixtures/core/uncategorised/118/expected.json new file mode 100644 index 0000000000..89fcab4775 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/118/expected.json @@ -0,0 +1,56 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "CallExpression", + "callee": { + "type": "Identifier", + "name": "foo", + "loc": { + "start": { + "line": 1, + "column": 5 + }, + "end": { + "line": 1, + "column": 8 + } + } + }, + "arguments": [], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 13 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 13 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 13 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/119/actual.js b/packages/babylon/test/fixtures/core/uncategorised/119/actual.js new file mode 100644 index 0000000000..1e1ee2e4d9 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/119/actual.js @@ -0,0 +1 @@ +universe.milkyway \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/119/expected.json b/packages/babylon/test/fixtures/core/uncategorised/119/expected.json new file mode 100644 index 0000000000..a4a75d5d71 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/119/expected.json @@ -0,0 +1,70 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "MemberExpression", + "object": { + "type": "Identifier", + "name": "universe", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 8 + } + } + }, + "property": { + "type": "Identifier", + "name": "milkyway", + "loc": { + "start": { + "line": 1, + "column": 9 + }, + "end": { + "line": 1, + "column": 17 + } + } + }, + "computed": false, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 17 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 17 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 17 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/12/actual.js b/packages/babylon/test/fixtures/core/uncategorised/12/actual.js new file mode 100644 index 0000000000..9a2988fad8 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/12/actual.js @@ -0,0 +1 @@ +x = [ 1, 2, 3, ] \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/12/expected.json b/packages/babylon/test/fixtures/core/uncategorised/12/expected.json new file mode 100644 index 0000000000..fb04ed1c0e --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/12/expected.json @@ -0,0 +1,113 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "AssignmentExpression", + "operator": "=", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "right": { + "type": "ArrayExpression", + "elements": [ + { + "type": "Literal", + "value": 1, + "loc": { + "start": { + "line": 1, + "column": 6 + }, + "end": { + "line": 1, + "column": 7 + } + } + }, + { + "type": "Literal", + "value": 2, + "loc": { + "start": { + "line": 1, + "column": 9 + }, + "end": { + "line": 1, + "column": 10 + } + } + }, + { + "type": "Literal", + "value": 3, + "loc": { + "start": { + "line": 1, + "column": 12 + }, + "end": { + "line": 1, + "column": 13 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 16 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 16 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 16 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 16 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/120/actual.js b/packages/babylon/test/fixtures/core/uncategorised/120/actual.js new file mode 100644 index 0000000000..c70185809d --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/120/actual.js @@ -0,0 +1 @@ +universe.milkyway.solarsystem \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/120/expected.json b/packages/babylon/test/fixtures/core/uncategorised/120/expected.json new file mode 100644 index 0000000000..80e1b9700c --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/120/expected.json @@ -0,0 +1,98 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "MemberExpression", + "object": { + "type": "MemberExpression", + "object": { + "type": "Identifier", + "name": "universe", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 8 + } + } + }, + "property": { + "type": "Identifier", + "name": "milkyway", + "loc": { + "start": { + "line": 1, + "column": 9 + }, + "end": { + "line": 1, + "column": 17 + } + } + }, + "computed": false, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 17 + } + } + }, + "property": { + "type": "Identifier", + "name": "solarsystem", + "loc": { + "start": { + "line": 1, + "column": 18 + }, + "end": { + "line": 1, + "column": 29 + } + } + }, + "computed": false, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 29 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 29 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 29 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/121/actual.js b/packages/babylon/test/fixtures/core/uncategorised/121/actual.js new file mode 100644 index 0000000000..78aa72f4a4 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/121/actual.js @@ -0,0 +1 @@ +universe.milkyway.solarsystem.Earth \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/121/expected.json b/packages/babylon/test/fixtures/core/uncategorised/121/expected.json new file mode 100644 index 0000000000..67d709a9b7 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/121/expected.json @@ -0,0 +1,126 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "MemberExpression", + "object": { + "type": "MemberExpression", + "object": { + "type": "MemberExpression", + "object": { + "type": "Identifier", + "name": "universe", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 8 + } + } + }, + "property": { + "type": "Identifier", + "name": "milkyway", + "loc": { + "start": { + "line": 1, + "column": 9 + }, + "end": { + "line": 1, + "column": 17 + } + } + }, + "computed": false, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 17 + } + } + }, + "property": { + "type": "Identifier", + "name": "solarsystem", + "loc": { + "start": { + "line": 1, + "column": 18 + }, + "end": { + "line": 1, + "column": 29 + } + } + }, + "computed": false, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 29 + } + } + }, + "property": { + "type": "Identifier", + "name": "Earth", + "loc": { + "start": { + "line": 1, + "column": 30 + }, + "end": { + "line": 1, + "column": 35 + } + } + }, + "computed": false, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 35 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 35 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 35 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/122/actual.js b/packages/babylon/test/fixtures/core/uncategorised/122/actual.js new file mode 100644 index 0000000000..8527f996ac --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/122/actual.js @@ -0,0 +1 @@ +universe[galaxyName, otherUselessName] \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/122/expected.json b/packages/babylon/test/fixtures/core/uncategorised/122/expected.json new file mode 100644 index 0000000000..9e20a28046 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/122/expected.json @@ -0,0 +1,99 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "MemberExpression", + "object": { + "type": "Identifier", + "name": "universe", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 8 + } + } + }, + "property": { + "type": "SequenceExpression", + "expressions": [ + { + "type": "Identifier", + "name": "galaxyName", + "loc": { + "start": { + "line": 1, + "column": 9 + }, + "end": { + "line": 1, + "column": 19 + } + } + }, + { + "type": "Identifier", + "name": "otherUselessName", + "loc": { + "start": { + "line": 1, + "column": 21 + }, + "end": { + "line": 1, + "column": 37 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 9 + }, + "end": { + "line": 1, + "column": 37 + } + } + }, + "computed": true, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 38 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 38 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 38 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/123/actual.js b/packages/babylon/test/fixtures/core/uncategorised/123/actual.js new file mode 100644 index 0000000000..e11584cae3 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/123/actual.js @@ -0,0 +1 @@ +universe[galaxyName] \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/123/expected.json b/packages/babylon/test/fixtures/core/uncategorised/123/expected.json new file mode 100644 index 0000000000..5f28a31868 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/123/expected.json @@ -0,0 +1,70 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "MemberExpression", + "object": { + "type": "Identifier", + "name": "universe", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 8 + } + } + }, + "property": { + "type": "Identifier", + "name": "galaxyName", + "loc": { + "start": { + "line": 1, + "column": 9 + }, + "end": { + "line": 1, + "column": 19 + } + } + }, + "computed": true, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 20 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 20 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 20 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/124/actual.js b/packages/babylon/test/fixtures/core/uncategorised/124/actual.js new file mode 100644 index 0000000000..b3797dc79c --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/124/actual.js @@ -0,0 +1 @@ +universe[42].galaxies \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/124/expected.json b/packages/babylon/test/fixtures/core/uncategorised/124/expected.json new file mode 100644 index 0000000000..7ba8d661fb --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/124/expected.json @@ -0,0 +1,98 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "MemberExpression", + "object": { + "type": "MemberExpression", + "object": { + "type": "Identifier", + "name": "universe", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 8 + } + } + }, + "property": { + "type": "Literal", + "value": 42, + "loc": { + "start": { + "line": 1, + "column": 9 + }, + "end": { + "line": 1, + "column": 11 + } + } + }, + "computed": true, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 12 + } + } + }, + "property": { + "type": "Identifier", + "name": "galaxies", + "loc": { + "start": { + "line": 1, + "column": 13 + }, + "end": { + "line": 1, + "column": 21 + } + } + }, + "computed": false, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 21 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 21 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 21 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/125/actual.js b/packages/babylon/test/fixtures/core/uncategorised/125/actual.js new file mode 100644 index 0000000000..2da49978a6 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/125/actual.js @@ -0,0 +1 @@ +universe(42).galaxies \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/125/expected.json b/packages/babylon/test/fixtures/core/uncategorised/125/expected.json new file mode 100644 index 0000000000..ec15b796b1 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/125/expected.json @@ -0,0 +1,99 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "MemberExpression", + "object": { + "type": "CallExpression", + "callee": { + "type": "Identifier", + "name": "universe", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 8 + } + } + }, + "arguments": [ + { + "type": "Literal", + "value": 42, + "loc": { + "start": { + "line": 1, + "column": 9 + }, + "end": { + "line": 1, + "column": 11 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 12 + } + } + }, + "property": { + "type": "Identifier", + "name": "galaxies", + "loc": { + "start": { + "line": 1, + "column": 13 + }, + "end": { + "line": 1, + "column": 21 + } + } + }, + "computed": false, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 21 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 21 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 21 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/126/actual.js b/packages/babylon/test/fixtures/core/uncategorised/126/actual.js new file mode 100644 index 0000000000..1bf483f9e5 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/126/actual.js @@ -0,0 +1 @@ +universe(42).galaxies(14, 3, 77).milkyway \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/126/expected.json b/packages/babylon/test/fixtures/core/uncategorised/126/expected.json new file mode 100644 index 0000000000..9288ae8da5 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/126/expected.json @@ -0,0 +1,184 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "MemberExpression", + "object": { + "type": "CallExpression", + "callee": { + "type": "MemberExpression", + "object": { + "type": "CallExpression", + "callee": { + "type": "Identifier", + "name": "universe", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 8 + } + } + }, + "arguments": [ + { + "type": "Literal", + "value": 42, + "loc": { + "start": { + "line": 1, + "column": 9 + }, + "end": { + "line": 1, + "column": 11 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 12 + } + } + }, + "property": { + "type": "Identifier", + "name": "galaxies", + "loc": { + "start": { + "line": 1, + "column": 13 + }, + "end": { + "line": 1, + "column": 21 + } + } + }, + "computed": false, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 21 + } + } + }, + "arguments": [ + { + "type": "Literal", + "value": 14, + "loc": { + "start": { + "line": 1, + "column": 22 + }, + "end": { + "line": 1, + "column": 24 + } + } + }, + { + "type": "Literal", + "value": 3, + "loc": { + "start": { + "line": 1, + "column": 26 + }, + "end": { + "line": 1, + "column": 27 + } + } + }, + { + "type": "Literal", + "value": 77, + "loc": { + "start": { + "line": 1, + "column": 29 + }, + "end": { + "line": 1, + "column": 31 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 32 + } + } + }, + "property": { + "type": "Identifier", + "name": "milkyway", + "loc": { + "start": { + "line": 1, + "column": 33 + }, + "end": { + "line": 1, + "column": 41 + } + } + }, + "computed": false, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 41 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 41 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 41 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/127/actual.js b/packages/babylon/test/fixtures/core/uncategorised/127/actual.js new file mode 100644 index 0000000000..4bd8c591ca --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/127/actual.js @@ -0,0 +1 @@ +earth.asia.Indonesia.prepareForElection(2014) \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/127/expected.json b/packages/babylon/test/fixtures/core/uncategorised/127/expected.json new file mode 100644 index 0000000000..82d34ff0ae --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/127/expected.json @@ -0,0 +1,155 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "CallExpression", + "callee": { + "type": "MemberExpression", + "object": { + "type": "MemberExpression", + "object": { + "type": "MemberExpression", + "object": { + "type": "Identifier", + "name": "earth", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "property": { + "type": "Identifier", + "name": "asia", + "loc": { + "start": { + "line": 1, + "column": 6 + }, + "end": { + "line": 1, + "column": 10 + } + } + }, + "computed": false, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 10 + } + } + }, + "property": { + "type": "Identifier", + "name": "Indonesia", + "loc": { + "start": { + "line": 1, + "column": 11 + }, + "end": { + "line": 1, + "column": 20 + } + } + }, + "computed": false, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 20 + } + } + }, + "property": { + "type": "Identifier", + "name": "prepareForElection", + "loc": { + "start": { + "line": 1, + "column": 21 + }, + "end": { + "line": 1, + "column": 39 + } + } + }, + "computed": false, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 39 + } + } + }, + "arguments": [ + { + "type": "Literal", + "value": 2014, + "loc": { + "start": { + "line": 1, + "column": 40 + }, + "end": { + "line": 1, + "column": 44 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 45 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 45 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 45 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/128/actual.js b/packages/babylon/test/fixtures/core/uncategorised/128/actual.js new file mode 100644 index 0000000000..be247f789c --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/128/actual.js @@ -0,0 +1 @@ +universe.if \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/128/expected.json b/packages/babylon/test/fixtures/core/uncategorised/128/expected.json new file mode 100644 index 0000000000..9d4591d62d --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/128/expected.json @@ -0,0 +1,70 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "MemberExpression", + "object": { + "type": "Identifier", + "name": "universe", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 8 + } + } + }, + "property": { + "type": "Identifier", + "name": "if", + "loc": { + "start": { + "line": 1, + "column": 9 + }, + "end": { + "line": 1, + "column": 11 + } + } + }, + "computed": false, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 11 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 11 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 11 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/129/actual.js b/packages/babylon/test/fixtures/core/uncategorised/129/actual.js new file mode 100644 index 0000000000..83d00158ba --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/129/actual.js @@ -0,0 +1 @@ +universe.true \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/129/expected.json b/packages/babylon/test/fixtures/core/uncategorised/129/expected.json new file mode 100644 index 0000000000..b703e3ae7c --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/129/expected.json @@ -0,0 +1,70 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "MemberExpression", + "object": { + "type": "Identifier", + "name": "universe", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 8 + } + } + }, + "property": { + "type": "Identifier", + "name": "true", + "loc": { + "start": { + "line": 1, + "column": 9 + }, + "end": { + "line": 1, + "column": 13 + } + } + }, + "computed": false, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 13 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 13 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 13 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/13/actual.js b/packages/babylon/test/fixtures/core/uncategorised/13/actual.js new file mode 100644 index 0000000000..9fad480185 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/13/actual.js @@ -0,0 +1 @@ +x = [ 1, 2,, 3, ] \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/13/expected.json b/packages/babylon/test/fixtures/core/uncategorised/13/expected.json new file mode 100644 index 0000000000..6b57aa7d8e --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/13/expected.json @@ -0,0 +1,114 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "AssignmentExpression", + "operator": "=", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "right": { + "type": "ArrayExpression", + "elements": [ + { + "type": "Literal", + "value": 1, + "loc": { + "start": { + "line": 1, + "column": 6 + }, + "end": { + "line": 1, + "column": 7 + } + } + }, + { + "type": "Literal", + "value": 2, + "loc": { + "start": { + "line": 1, + "column": 9 + }, + "end": { + "line": 1, + "column": 10 + } + } + }, + null, + { + "type": "Literal", + "value": 3, + "loc": { + "start": { + "line": 1, + "column": 13 + }, + "end": { + "line": 1, + "column": 14 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 17 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 17 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 17 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 17 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/130/actual.js b/packages/babylon/test/fixtures/core/uncategorised/130/actual.js new file mode 100644 index 0000000000..85bcdd4988 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/130/actual.js @@ -0,0 +1 @@ +universe.false \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/130/expected.json b/packages/babylon/test/fixtures/core/uncategorised/130/expected.json new file mode 100644 index 0000000000..af216b81f1 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/130/expected.json @@ -0,0 +1,70 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "MemberExpression", + "object": { + "type": "Identifier", + "name": "universe", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 8 + } + } + }, + "property": { + "type": "Identifier", + "name": "false", + "loc": { + "start": { + "line": 1, + "column": 9 + }, + "end": { + "line": 1, + "column": 14 + } + } + }, + "computed": false, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 14 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 14 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 14 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/131/actual.js b/packages/babylon/test/fixtures/core/uncategorised/131/actual.js new file mode 100644 index 0000000000..6ed7c77271 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/131/actual.js @@ -0,0 +1 @@ +universe.null \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/131/expected.json b/packages/babylon/test/fixtures/core/uncategorised/131/expected.json new file mode 100644 index 0000000000..d7f96322b5 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/131/expected.json @@ -0,0 +1,70 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "MemberExpression", + "object": { + "type": "Identifier", + "name": "universe", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 8 + } + } + }, + "property": { + "type": "Identifier", + "name": "null", + "loc": { + "start": { + "line": 1, + "column": 9 + }, + "end": { + "line": 1, + "column": 13 + } + } + }, + "computed": false, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 13 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 13 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 13 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/132/actual.js b/packages/babylon/test/fixtures/core/uncategorised/132/actual.js new file mode 100644 index 0000000000..1dee13b942 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/132/actual.js @@ -0,0 +1 @@ +x++ \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/132/expected.json b/packages/babylon/test/fixtures/core/uncategorised/132/expected.json new file mode 100644 index 0000000000..e037dfeac1 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/132/expected.json @@ -0,0 +1,57 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "UpdateExpression", + "operator": "++", + "prefix": false, + "argument": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 3 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 3 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 3 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/133/actual.js b/packages/babylon/test/fixtures/core/uncategorised/133/actual.js new file mode 100644 index 0000000000..61a1bfe684 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/133/actual.js @@ -0,0 +1 @@ +x-- \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/133/expected.json b/packages/babylon/test/fixtures/core/uncategorised/133/expected.json new file mode 100644 index 0000000000..36c6ad9210 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/133/expected.json @@ -0,0 +1,57 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "UpdateExpression", + "operator": "--", + "prefix": false, + "argument": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 3 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 3 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 3 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/134/actual.js b/packages/babylon/test/fixtures/core/uncategorised/134/actual.js new file mode 100644 index 0000000000..b28918441d --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/134/actual.js @@ -0,0 +1 @@ +eval++ \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/134/expected.json b/packages/babylon/test/fixtures/core/uncategorised/134/expected.json new file mode 100644 index 0000000000..75eddd3ab6 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/134/expected.json @@ -0,0 +1,57 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "UpdateExpression", + "operator": "++", + "prefix": false, + "argument": { + "type": "Identifier", + "name": "eval", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 4 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 6 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 6 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 6 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/135/actual.js b/packages/babylon/test/fixtures/core/uncategorised/135/actual.js new file mode 100644 index 0000000000..319fb3881c --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/135/actual.js @@ -0,0 +1 @@ +eval-- \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/135/expected.json b/packages/babylon/test/fixtures/core/uncategorised/135/expected.json new file mode 100644 index 0000000000..d1d60f29f7 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/135/expected.json @@ -0,0 +1,57 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "UpdateExpression", + "operator": "--", + "prefix": false, + "argument": { + "type": "Identifier", + "name": "eval", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 4 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 6 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 6 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 6 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/136/actual.js b/packages/babylon/test/fixtures/core/uncategorised/136/actual.js new file mode 100644 index 0000000000..9cf54e31ef --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/136/actual.js @@ -0,0 +1 @@ +arguments++ \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/136/expected.json b/packages/babylon/test/fixtures/core/uncategorised/136/expected.json new file mode 100644 index 0000000000..4a03ec3711 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/136/expected.json @@ -0,0 +1,57 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "UpdateExpression", + "operator": "++", + "prefix": false, + "argument": { + "type": "Identifier", + "name": "arguments", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 11 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 11 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 11 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/137/actual.js b/packages/babylon/test/fixtures/core/uncategorised/137/actual.js new file mode 100644 index 0000000000..8b1113a529 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/137/actual.js @@ -0,0 +1 @@ +arguments-- \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/137/expected.json b/packages/babylon/test/fixtures/core/uncategorised/137/expected.json new file mode 100644 index 0000000000..c536f4ee65 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/137/expected.json @@ -0,0 +1,57 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "UpdateExpression", + "operator": "--", + "prefix": false, + "argument": { + "type": "Identifier", + "name": "arguments", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 11 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 11 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 11 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/138/actual.js b/packages/babylon/test/fixtures/core/uncategorised/138/actual.js new file mode 100644 index 0000000000..76eaf4c8ec --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/138/actual.js @@ -0,0 +1 @@ +++x \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/138/expected.json b/packages/babylon/test/fixtures/core/uncategorised/138/expected.json new file mode 100644 index 0000000000..22c4b3da89 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/138/expected.json @@ -0,0 +1,57 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "UpdateExpression", + "operator": "++", + "prefix": true, + "argument": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 2 + }, + "end": { + "line": 1, + "column": 3 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 3 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 3 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 3 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/139/actual.js b/packages/babylon/test/fixtures/core/uncategorised/139/actual.js new file mode 100644 index 0000000000..39fec252a7 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/139/actual.js @@ -0,0 +1 @@ +--x \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/139/expected.json b/packages/babylon/test/fixtures/core/uncategorised/139/expected.json new file mode 100644 index 0000000000..8b6c07e246 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/139/expected.json @@ -0,0 +1,57 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "UpdateExpression", + "operator": "--", + "prefix": true, + "argument": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 2 + }, + "end": { + "line": 1, + "column": 3 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 3 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 3 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 3 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/14/actual.js b/packages/babylon/test/fixtures/core/uncategorised/14/actual.js new file mode 100644 index 0000000000..16e202fe27 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/14/actual.js @@ -0,0 +1 @@ +日本語 = [] \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/14/expected.json b/packages/babylon/test/fixtures/core/uncategorised/14/expected.json new file mode 100644 index 0000000000..85939fbfb3 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/14/expected.json @@ -0,0 +1,70 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "AssignmentExpression", + "operator": "=", + "left": { + "type": "Identifier", + "name": "日本語", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 3 + } + } + }, + "right": { + "type": "ArrayExpression", + "elements": [], + "loc": { + "start": { + "line": 1, + "column": 6 + }, + "end": { + "line": 1, + "column": 8 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 8 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 8 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 8 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/140/actual.js b/packages/babylon/test/fixtures/core/uncategorised/140/actual.js new file mode 100644 index 0000000000..afae5bb90c --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/140/actual.js @@ -0,0 +1 @@ +++eval \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/140/expected.json b/packages/babylon/test/fixtures/core/uncategorised/140/expected.json new file mode 100644 index 0000000000..5776ff8193 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/140/expected.json @@ -0,0 +1,57 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "UpdateExpression", + "operator": "++", + "prefix": true, + "argument": { + "type": "Identifier", + "name": "eval", + "loc": { + "start": { + "line": 1, + "column": 2 + }, + "end": { + "line": 1, + "column": 6 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 6 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 6 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 6 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/141/actual.js b/packages/babylon/test/fixtures/core/uncategorised/141/actual.js new file mode 100644 index 0000000000..2d4178c9fe --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/141/actual.js @@ -0,0 +1 @@ +--eval \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/141/expected.json b/packages/babylon/test/fixtures/core/uncategorised/141/expected.json new file mode 100644 index 0000000000..10ad71c713 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/141/expected.json @@ -0,0 +1,57 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "UpdateExpression", + "operator": "--", + "prefix": true, + "argument": { + "type": "Identifier", + "name": "eval", + "loc": { + "start": { + "line": 1, + "column": 2 + }, + "end": { + "line": 1, + "column": 6 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 6 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 6 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 6 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/142/actual.js b/packages/babylon/test/fixtures/core/uncategorised/142/actual.js new file mode 100644 index 0000000000..df35d14f21 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/142/actual.js @@ -0,0 +1 @@ +++arguments \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/142/expected.json b/packages/babylon/test/fixtures/core/uncategorised/142/expected.json new file mode 100644 index 0000000000..c2bb8250d3 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/142/expected.json @@ -0,0 +1,57 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "UpdateExpression", + "operator": "++", + "prefix": true, + "argument": { + "type": "Identifier", + "name": "arguments", + "loc": { + "start": { + "line": 1, + "column": 2 + }, + "end": { + "line": 1, + "column": 11 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 11 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 11 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 11 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/143/actual.js b/packages/babylon/test/fixtures/core/uncategorised/143/actual.js new file mode 100644 index 0000000000..f4b69ca899 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/143/actual.js @@ -0,0 +1 @@ +--arguments \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/143/expected.json b/packages/babylon/test/fixtures/core/uncategorised/143/expected.json new file mode 100644 index 0000000000..fa80ce52fc --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/143/expected.json @@ -0,0 +1,57 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "UpdateExpression", + "operator": "--", + "prefix": true, + "argument": { + "type": "Identifier", + "name": "arguments", + "loc": { + "start": { + "line": 1, + "column": 2 + }, + "end": { + "line": 1, + "column": 11 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 11 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 11 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 11 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/144/actual.js b/packages/babylon/test/fixtures/core/uncategorised/144/actual.js new file mode 100644 index 0000000000..46b9f7f60b --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/144/actual.js @@ -0,0 +1 @@ ++x \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/144/expected.json b/packages/babylon/test/fixtures/core/uncategorised/144/expected.json new file mode 100644 index 0000000000..612b2354bf --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/144/expected.json @@ -0,0 +1,57 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "UnaryExpression", + "operator": "+", + "prefix": true, + "argument": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 1 + }, + "end": { + "line": 1, + "column": 2 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 2 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 2 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 2 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/145/actual.js b/packages/babylon/test/fixtures/core/uncategorised/145/actual.js new file mode 100644 index 0000000000..e1c1426586 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/145/actual.js @@ -0,0 +1 @@ +-x \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/145/expected.json b/packages/babylon/test/fixtures/core/uncategorised/145/expected.json new file mode 100644 index 0000000000..adb25023dd --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/145/expected.json @@ -0,0 +1,57 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "UnaryExpression", + "operator": "-", + "prefix": true, + "argument": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 1 + }, + "end": { + "line": 1, + "column": 2 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 2 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 2 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 2 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/146/actual.js b/packages/babylon/test/fixtures/core/uncategorised/146/actual.js new file mode 100644 index 0000000000..edbe207d5d --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/146/actual.js @@ -0,0 +1 @@ +~x \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/146/expected.json b/packages/babylon/test/fixtures/core/uncategorised/146/expected.json new file mode 100644 index 0000000000..e6eb0b342a --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/146/expected.json @@ -0,0 +1,57 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "UnaryExpression", + "operator": "~", + "prefix": true, + "argument": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 1 + }, + "end": { + "line": 1, + "column": 2 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 2 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 2 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 2 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/147/actual.js b/packages/babylon/test/fixtures/core/uncategorised/147/actual.js new file mode 100644 index 0000000000..252b5dd874 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/147/actual.js @@ -0,0 +1 @@ +!x \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/147/expected.json b/packages/babylon/test/fixtures/core/uncategorised/147/expected.json new file mode 100644 index 0000000000..446891530c --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/147/expected.json @@ -0,0 +1,57 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "UnaryExpression", + "operator": "!", + "prefix": true, + "argument": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 1 + }, + "end": { + "line": 1, + "column": 2 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 2 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 2 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 2 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/148/actual.js b/packages/babylon/test/fixtures/core/uncategorised/148/actual.js new file mode 100644 index 0000000000..d37d4c1c9f --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/148/actual.js @@ -0,0 +1 @@ +void x \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/148/expected.json b/packages/babylon/test/fixtures/core/uncategorised/148/expected.json new file mode 100644 index 0000000000..9928880f3a --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/148/expected.json @@ -0,0 +1,57 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "UnaryExpression", + "operator": "void", + "prefix": true, + "argument": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 5 + }, + "end": { + "line": 1, + "column": 6 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 6 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 6 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 6 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/149/actual.js b/packages/babylon/test/fixtures/core/uncategorised/149/actual.js new file mode 100644 index 0000000000..5209804d22 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/149/actual.js @@ -0,0 +1 @@ +delete x \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/149/expected.json b/packages/babylon/test/fixtures/core/uncategorised/149/expected.json new file mode 100644 index 0000000000..813ba67394 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/149/expected.json @@ -0,0 +1,57 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "UnaryExpression", + "operator": "delete", + "prefix": true, + "argument": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 7 + }, + "end": { + "line": 1, + "column": 8 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 8 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 8 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 8 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/15/actual.js b/packages/babylon/test/fixtures/core/uncategorised/15/actual.js new file mode 100644 index 0000000000..e8ddfa4b23 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/15/actual.js @@ -0,0 +1 @@ +T‿ = [] \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/15/expected.json b/packages/babylon/test/fixtures/core/uncategorised/15/expected.json new file mode 100644 index 0000000000..d206b8b00a --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/15/expected.json @@ -0,0 +1,70 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "AssignmentExpression", + "operator": "=", + "left": { + "type": "Identifier", + "name": "T‿", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 2 + } + } + }, + "right": { + "type": "ArrayExpression", + "elements": [], + "loc": { + "start": { + "line": 1, + "column": 5 + }, + "end": { + "line": 1, + "column": 7 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 7 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 7 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 7 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/150/actual.js b/packages/babylon/test/fixtures/core/uncategorised/150/actual.js new file mode 100644 index 0000000000..8b9e2beb29 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/150/actual.js @@ -0,0 +1 @@ +typeof x \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/150/expected.json b/packages/babylon/test/fixtures/core/uncategorised/150/expected.json new file mode 100644 index 0000000000..e4a26cf36e --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/150/expected.json @@ -0,0 +1,57 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "UnaryExpression", + "operator": "typeof", + "prefix": true, + "argument": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 7 + }, + "end": { + "line": 1, + "column": 8 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 8 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 8 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 8 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/151/actual.js b/packages/babylon/test/fixtures/core/uncategorised/151/actual.js new file mode 100644 index 0000000000..bb5b8a40de --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/151/actual.js @@ -0,0 +1 @@ +x * y \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/151/expected.json b/packages/babylon/test/fixtures/core/uncategorised/151/expected.json new file mode 100644 index 0000000000..4b4641786c --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/151/expected.json @@ -0,0 +1,70 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "BinaryExpression", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "operator": "*", + "right": { + "type": "Identifier", + "name": "y", + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 5 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 5 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/152/actual.js b/packages/babylon/test/fixtures/core/uncategorised/152/actual.js new file mode 100644 index 0000000000..d6029e9f47 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/152/actual.js @@ -0,0 +1 @@ +x / y \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/152/expected.json b/packages/babylon/test/fixtures/core/uncategorised/152/expected.json new file mode 100644 index 0000000000..aa0e1c196a --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/152/expected.json @@ -0,0 +1,70 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "BinaryExpression", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "operator": "/", + "right": { + "type": "Identifier", + "name": "y", + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 5 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 5 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/153/actual.js b/packages/babylon/test/fixtures/core/uncategorised/153/actual.js new file mode 100644 index 0000000000..971b2f2244 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/153/actual.js @@ -0,0 +1 @@ +x % y \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/153/expected.json b/packages/babylon/test/fixtures/core/uncategorised/153/expected.json new file mode 100644 index 0000000000..0ed76fe370 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/153/expected.json @@ -0,0 +1,70 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "BinaryExpression", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "operator": "%", + "right": { + "type": "Identifier", + "name": "y", + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 5 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 5 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/154/actual.js b/packages/babylon/test/fixtures/core/uncategorised/154/actual.js new file mode 100644 index 0000000000..f96f15729c --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/154/actual.js @@ -0,0 +1 @@ +x + y \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/154/expected.json b/packages/babylon/test/fixtures/core/uncategorised/154/expected.json new file mode 100644 index 0000000000..c42146b10e --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/154/expected.json @@ -0,0 +1,70 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "BinaryExpression", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "operator": "+", + "right": { + "type": "Identifier", + "name": "y", + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 5 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 5 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/155/actual.js b/packages/babylon/test/fixtures/core/uncategorised/155/actual.js new file mode 100644 index 0000000000..2285ac28f0 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/155/actual.js @@ -0,0 +1 @@ +x - y \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/155/expected.json b/packages/babylon/test/fixtures/core/uncategorised/155/expected.json new file mode 100644 index 0000000000..5ab0365976 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/155/expected.json @@ -0,0 +1,70 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "BinaryExpression", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "operator": "-", + "right": { + "type": "Identifier", + "name": "y", + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 5 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 5 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/156/actual.js b/packages/babylon/test/fixtures/core/uncategorised/156/actual.js new file mode 100644 index 0000000000..ae3caa88da --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/156/actual.js @@ -0,0 +1 @@ +x << y \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/156/expected.json b/packages/babylon/test/fixtures/core/uncategorised/156/expected.json new file mode 100644 index 0000000000..5df00f2bb4 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/156/expected.json @@ -0,0 +1,70 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "BinaryExpression", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "operator": "<<", + "right": { + "type": "Identifier", + "name": "y", + "loc": { + "start": { + "line": 1, + "column": 5 + }, + "end": { + "line": 1, + "column": 6 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 6 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 6 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 6 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/157/actual.js b/packages/babylon/test/fixtures/core/uncategorised/157/actual.js new file mode 100644 index 0000000000..b8607451f2 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/157/actual.js @@ -0,0 +1 @@ +x >> y \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/157/expected.json b/packages/babylon/test/fixtures/core/uncategorised/157/expected.json new file mode 100644 index 0000000000..066d631115 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/157/expected.json @@ -0,0 +1,70 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "BinaryExpression", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "operator": ">>", + "right": { + "type": "Identifier", + "name": "y", + "loc": { + "start": { + "line": 1, + "column": 5 + }, + "end": { + "line": 1, + "column": 6 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 6 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 6 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 6 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/158/actual.js b/packages/babylon/test/fixtures/core/uncategorised/158/actual.js new file mode 100644 index 0000000000..94b6eaf756 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/158/actual.js @@ -0,0 +1 @@ +x >>> y \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/158/expected.json b/packages/babylon/test/fixtures/core/uncategorised/158/expected.json new file mode 100644 index 0000000000..c57f0248e2 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/158/expected.json @@ -0,0 +1,70 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "BinaryExpression", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "operator": ">>>", + "right": { + "type": "Identifier", + "name": "y", + "loc": { + "start": { + "line": 1, + "column": 6 + }, + "end": { + "line": 1, + "column": 7 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 7 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 7 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 7 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/159/actual.js b/packages/babylon/test/fixtures/core/uncategorised/159/actual.js new file mode 100644 index 0000000000..2a585b86d5 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/159/actual.js @@ -0,0 +1 @@ +x < y \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/159/expected.json b/packages/babylon/test/fixtures/core/uncategorised/159/expected.json new file mode 100644 index 0000000000..8f15137317 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/159/expected.json @@ -0,0 +1,70 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "BinaryExpression", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "operator": "<", + "right": { + "type": "Identifier", + "name": "y", + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 5 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 5 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/16/actual.js b/packages/babylon/test/fixtures/core/uncategorised/16/actual.js new file mode 100644 index 0000000000..023a1ce97a --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/16/actual.js @@ -0,0 +1 @@ +T‌ = [] \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/16/expected.json b/packages/babylon/test/fixtures/core/uncategorised/16/expected.json new file mode 100644 index 0000000000..53c98a4b35 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/16/expected.json @@ -0,0 +1,70 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "AssignmentExpression", + "operator": "=", + "left": { + "type": "Identifier", + "name": "T‌", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 2 + } + } + }, + "right": { + "type": "ArrayExpression", + "elements": [], + "loc": { + "start": { + "line": 1, + "column": 5 + }, + "end": { + "line": 1, + "column": 7 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 7 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 7 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 7 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/160/actual.js b/packages/babylon/test/fixtures/core/uncategorised/160/actual.js new file mode 100644 index 0000000000..c231f12795 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/160/actual.js @@ -0,0 +1 @@ +x > y \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/160/expected.json b/packages/babylon/test/fixtures/core/uncategorised/160/expected.json new file mode 100644 index 0000000000..03adf6854c --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/160/expected.json @@ -0,0 +1,70 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "BinaryExpression", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "operator": ">", + "right": { + "type": "Identifier", + "name": "y", + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 5 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 5 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/161/actual.js b/packages/babylon/test/fixtures/core/uncategorised/161/actual.js new file mode 100644 index 0000000000..2b216c213d --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/161/actual.js @@ -0,0 +1 @@ +x <= y \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/161/expected.json b/packages/babylon/test/fixtures/core/uncategorised/161/expected.json new file mode 100644 index 0000000000..adf80b0d56 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/161/expected.json @@ -0,0 +1,70 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "BinaryExpression", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "operator": "<=", + "right": { + "type": "Identifier", + "name": "y", + "loc": { + "start": { + "line": 1, + "column": 5 + }, + "end": { + "line": 1, + "column": 6 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 6 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 6 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 6 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/162/actual.js b/packages/babylon/test/fixtures/core/uncategorised/162/actual.js new file mode 100644 index 0000000000..491e7fed15 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/162/actual.js @@ -0,0 +1 @@ +x >= y \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/162/expected.json b/packages/babylon/test/fixtures/core/uncategorised/162/expected.json new file mode 100644 index 0000000000..d83081b57e --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/162/expected.json @@ -0,0 +1,70 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "BinaryExpression", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "operator": ">=", + "right": { + "type": "Identifier", + "name": "y", + "loc": { + "start": { + "line": 1, + "column": 5 + }, + "end": { + "line": 1, + "column": 6 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 6 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 6 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 6 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/163/actual.js b/packages/babylon/test/fixtures/core/uncategorised/163/actual.js new file mode 100644 index 0000000000..9d2a5136f5 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/163/actual.js @@ -0,0 +1 @@ +x in y \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/163/expected.json b/packages/babylon/test/fixtures/core/uncategorised/163/expected.json new file mode 100644 index 0000000000..6dcdd50842 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/163/expected.json @@ -0,0 +1,70 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "BinaryExpression", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "operator": "in", + "right": { + "type": "Identifier", + "name": "y", + "loc": { + "start": { + "line": 1, + "column": 5 + }, + "end": { + "line": 1, + "column": 6 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 6 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 6 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 6 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/164/actual.js b/packages/babylon/test/fixtures/core/uncategorised/164/actual.js new file mode 100644 index 0000000000..9b2d626637 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/164/actual.js @@ -0,0 +1 @@ +x instanceof y \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/164/expected.json b/packages/babylon/test/fixtures/core/uncategorised/164/expected.json new file mode 100644 index 0000000000..5130913ef9 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/164/expected.json @@ -0,0 +1,70 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "BinaryExpression", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "operator": "instanceof", + "right": { + "type": "Identifier", + "name": "y", + "loc": { + "start": { + "line": 1, + "column": 13 + }, + "end": { + "line": 1, + "column": 14 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 14 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 14 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 14 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/165/actual.js b/packages/babylon/test/fixtures/core/uncategorised/165/actual.js new file mode 100644 index 0000000000..48f0852108 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/165/actual.js @@ -0,0 +1 @@ +x < y < z \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/165/expected.json b/packages/babylon/test/fixtures/core/uncategorised/165/expected.json new file mode 100644 index 0000000000..ea6154df8d --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/165/expected.json @@ -0,0 +1,98 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "BinaryExpression", + "left": { + "type": "BinaryExpression", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "operator": "<", + "right": { + "type": "Identifier", + "name": "y", + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "operator": "<", + "right": { + "type": "Identifier", + "name": "z", + "loc": { + "start": { + "line": 1, + "column": 8 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/166/actual.js b/packages/babylon/test/fixtures/core/uncategorised/166/actual.js new file mode 100644 index 0000000000..616ee7099e --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/166/actual.js @@ -0,0 +1 @@ +x == y \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/166/expected.json b/packages/babylon/test/fixtures/core/uncategorised/166/expected.json new file mode 100644 index 0000000000..6a5ae93a3e --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/166/expected.json @@ -0,0 +1,70 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "BinaryExpression", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "operator": "==", + "right": { + "type": "Identifier", + "name": "y", + "loc": { + "start": { + "line": 1, + "column": 5 + }, + "end": { + "line": 1, + "column": 6 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 6 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 6 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 6 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/167/actual.js b/packages/babylon/test/fixtures/core/uncategorised/167/actual.js new file mode 100644 index 0000000000..6d0ea2ea64 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/167/actual.js @@ -0,0 +1 @@ +x != y \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/167/expected.json b/packages/babylon/test/fixtures/core/uncategorised/167/expected.json new file mode 100644 index 0000000000..48d93e482e --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/167/expected.json @@ -0,0 +1,70 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "BinaryExpression", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "operator": "!=", + "right": { + "type": "Identifier", + "name": "y", + "loc": { + "start": { + "line": 1, + "column": 5 + }, + "end": { + "line": 1, + "column": 6 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 6 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 6 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 6 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/168/actual.js b/packages/babylon/test/fixtures/core/uncategorised/168/actual.js new file mode 100644 index 0000000000..8af91894fa --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/168/actual.js @@ -0,0 +1 @@ +x === y \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/168/expected.json b/packages/babylon/test/fixtures/core/uncategorised/168/expected.json new file mode 100644 index 0000000000..b406c7705a --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/168/expected.json @@ -0,0 +1,70 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "BinaryExpression", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "operator": "===", + "right": { + "type": "Identifier", + "name": "y", + "loc": { + "start": { + "line": 1, + "column": 6 + }, + "end": { + "line": 1, + "column": 7 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 7 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 7 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 7 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/169/actual.js b/packages/babylon/test/fixtures/core/uncategorised/169/actual.js new file mode 100644 index 0000000000..81800acc46 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/169/actual.js @@ -0,0 +1 @@ +x !== y \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/169/expected.json b/packages/babylon/test/fixtures/core/uncategorised/169/expected.json new file mode 100644 index 0000000000..6e486c77d3 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/169/expected.json @@ -0,0 +1,70 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "BinaryExpression", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "operator": "!==", + "right": { + "type": "Identifier", + "name": "y", + "loc": { + "start": { + "line": 1, + "column": 6 + }, + "end": { + "line": 1, + "column": 7 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 7 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 7 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 7 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/17/actual.js b/packages/babylon/test/fixtures/core/uncategorised/17/actual.js new file mode 100644 index 0000000000..d206225c90 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/17/actual.js @@ -0,0 +1 @@ +T‍ = [] \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/17/expected.json b/packages/babylon/test/fixtures/core/uncategorised/17/expected.json new file mode 100644 index 0000000000..6e20ae13eb --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/17/expected.json @@ -0,0 +1,70 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "AssignmentExpression", + "operator": "=", + "left": { + "type": "Identifier", + "name": "T‍", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 2 + } + } + }, + "right": { + "type": "ArrayExpression", + "elements": [], + "loc": { + "start": { + "line": 1, + "column": 5 + }, + "end": { + "line": 1, + "column": 7 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 7 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 7 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 7 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/170/actual.js b/packages/babylon/test/fixtures/core/uncategorised/170/actual.js new file mode 100644 index 0000000000..90b80fa162 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/170/actual.js @@ -0,0 +1 @@ +x & y \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/170/expected.json b/packages/babylon/test/fixtures/core/uncategorised/170/expected.json new file mode 100644 index 0000000000..1a4854758c --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/170/expected.json @@ -0,0 +1,70 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "BinaryExpression", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "operator": "&", + "right": { + "type": "Identifier", + "name": "y", + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 5 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 5 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/171/actual.js b/packages/babylon/test/fixtures/core/uncategorised/171/actual.js new file mode 100644 index 0000000000..e4579f09fc --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/171/actual.js @@ -0,0 +1 @@ +x ^ y \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/171/expected.json b/packages/babylon/test/fixtures/core/uncategorised/171/expected.json new file mode 100644 index 0000000000..4a558e1650 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/171/expected.json @@ -0,0 +1,70 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "BinaryExpression", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "operator": "^", + "right": { + "type": "Identifier", + "name": "y", + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 5 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 5 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/172/actual.js b/packages/babylon/test/fixtures/core/uncategorised/172/actual.js new file mode 100644 index 0000000000..0bf2abbe53 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/172/actual.js @@ -0,0 +1 @@ +x | y \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/172/expected.json b/packages/babylon/test/fixtures/core/uncategorised/172/expected.json new file mode 100644 index 0000000000..a60ee91846 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/172/expected.json @@ -0,0 +1,70 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "BinaryExpression", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "operator": "|", + "right": { + "type": "Identifier", + "name": "y", + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 5 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 5 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/173/actual.js b/packages/babylon/test/fixtures/core/uncategorised/173/actual.js new file mode 100644 index 0000000000..04323493dc --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/173/actual.js @@ -0,0 +1 @@ +x + y + z \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/173/expected.json b/packages/babylon/test/fixtures/core/uncategorised/173/expected.json new file mode 100644 index 0000000000..a2cd388f43 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/173/expected.json @@ -0,0 +1,98 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "BinaryExpression", + "left": { + "type": "BinaryExpression", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "operator": "+", + "right": { + "type": "Identifier", + "name": "y", + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "operator": "+", + "right": { + "type": "Identifier", + "name": "z", + "loc": { + "start": { + "line": 1, + "column": 8 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/174/actual.js b/packages/babylon/test/fixtures/core/uncategorised/174/actual.js new file mode 100644 index 0000000000..e5b7880c74 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/174/actual.js @@ -0,0 +1 @@ +x - y + z \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/174/expected.json b/packages/babylon/test/fixtures/core/uncategorised/174/expected.json new file mode 100644 index 0000000000..07cb0ab58f --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/174/expected.json @@ -0,0 +1,98 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "BinaryExpression", + "left": { + "type": "BinaryExpression", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "operator": "-", + "right": { + "type": "Identifier", + "name": "y", + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "operator": "+", + "right": { + "type": "Identifier", + "name": "z", + "loc": { + "start": { + "line": 1, + "column": 8 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/175/actual.js b/packages/babylon/test/fixtures/core/uncategorised/175/actual.js new file mode 100644 index 0000000000..55b42392c5 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/175/actual.js @@ -0,0 +1 @@ +x + y - z \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/175/expected.json b/packages/babylon/test/fixtures/core/uncategorised/175/expected.json new file mode 100644 index 0000000000..a06578f7f0 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/175/expected.json @@ -0,0 +1,98 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "BinaryExpression", + "left": { + "type": "BinaryExpression", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "operator": "+", + "right": { + "type": "Identifier", + "name": "y", + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "operator": "-", + "right": { + "type": "Identifier", + "name": "z", + "loc": { + "start": { + "line": 1, + "column": 8 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/176/actual.js b/packages/babylon/test/fixtures/core/uncategorised/176/actual.js new file mode 100644 index 0000000000..19e84aab94 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/176/actual.js @@ -0,0 +1 @@ +x - y - z \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/176/expected.json b/packages/babylon/test/fixtures/core/uncategorised/176/expected.json new file mode 100644 index 0000000000..e7fffe596d --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/176/expected.json @@ -0,0 +1,98 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "BinaryExpression", + "left": { + "type": "BinaryExpression", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "operator": "-", + "right": { + "type": "Identifier", + "name": "y", + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "operator": "-", + "right": { + "type": "Identifier", + "name": "z", + "loc": { + "start": { + "line": 1, + "column": 8 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/177/actual.js b/packages/babylon/test/fixtures/core/uncategorised/177/actual.js new file mode 100644 index 0000000000..a25187770d --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/177/actual.js @@ -0,0 +1 @@ +x + y * z \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/177/expected.json b/packages/babylon/test/fixtures/core/uncategorised/177/expected.json new file mode 100644 index 0000000000..6b33fcf6ed --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/177/expected.json @@ -0,0 +1,98 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "BinaryExpression", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "operator": "+", + "right": { + "type": "BinaryExpression", + "left": { + "type": "Identifier", + "name": "y", + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "operator": "*", + "right": { + "type": "Identifier", + "name": "z", + "loc": { + "start": { + "line": 1, + "column": 8 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/178/actual.js b/packages/babylon/test/fixtures/core/uncategorised/178/actual.js new file mode 100644 index 0000000000..b1858dbf55 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/178/actual.js @@ -0,0 +1 @@ +x + y / z \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/178/expected.json b/packages/babylon/test/fixtures/core/uncategorised/178/expected.json new file mode 100644 index 0000000000..b7f663ee92 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/178/expected.json @@ -0,0 +1,98 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "BinaryExpression", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "operator": "+", + "right": { + "type": "BinaryExpression", + "left": { + "type": "Identifier", + "name": "y", + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "operator": "/", + "right": { + "type": "Identifier", + "name": "z", + "loc": { + "start": { + "line": 1, + "column": 8 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/179/actual.js b/packages/babylon/test/fixtures/core/uncategorised/179/actual.js new file mode 100644 index 0000000000..a665a0cbfd --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/179/actual.js @@ -0,0 +1 @@ +x - y % z \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/179/expected.json b/packages/babylon/test/fixtures/core/uncategorised/179/expected.json new file mode 100644 index 0000000000..6c019141de --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/179/expected.json @@ -0,0 +1,98 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "BinaryExpression", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "operator": "-", + "right": { + "type": "BinaryExpression", + "left": { + "type": "Identifier", + "name": "y", + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "operator": "%", + "right": { + "type": "Identifier", + "name": "z", + "loc": { + "start": { + "line": 1, + "column": 8 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/18/actual.js b/packages/babylon/test/fixtures/core/uncategorised/18/actual.js new file mode 100644 index 0000000000..c955ab7151 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/18/actual.js @@ -0,0 +1 @@ +ⅣⅡ = [] \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/18/expected.json b/packages/babylon/test/fixtures/core/uncategorised/18/expected.json new file mode 100644 index 0000000000..65188d0276 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/18/expected.json @@ -0,0 +1,70 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "AssignmentExpression", + "operator": "=", + "left": { + "type": "Identifier", + "name": "ⅣⅡ", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 2 + } + } + }, + "right": { + "type": "ArrayExpression", + "elements": [], + "loc": { + "start": { + "line": 1, + "column": 5 + }, + "end": { + "line": 1, + "column": 7 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 7 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 7 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 7 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/180/actual.js b/packages/babylon/test/fixtures/core/uncategorised/180/actual.js new file mode 100644 index 0000000000..7200a89b58 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/180/actual.js @@ -0,0 +1 @@ +x * y * z \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/180/expected.json b/packages/babylon/test/fixtures/core/uncategorised/180/expected.json new file mode 100644 index 0000000000..ab7ffa29f9 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/180/expected.json @@ -0,0 +1,98 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "BinaryExpression", + "left": { + "type": "BinaryExpression", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "operator": "*", + "right": { + "type": "Identifier", + "name": "y", + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "operator": "*", + "right": { + "type": "Identifier", + "name": "z", + "loc": { + "start": { + "line": 1, + "column": 8 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/181/actual.js b/packages/babylon/test/fixtures/core/uncategorised/181/actual.js new file mode 100644 index 0000000000..a55d62bc5e --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/181/actual.js @@ -0,0 +1 @@ +x * y / z \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/181/expected.json b/packages/babylon/test/fixtures/core/uncategorised/181/expected.json new file mode 100644 index 0000000000..4e5d9b30ea --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/181/expected.json @@ -0,0 +1,98 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "BinaryExpression", + "left": { + "type": "BinaryExpression", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "operator": "*", + "right": { + "type": "Identifier", + "name": "y", + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "operator": "/", + "right": { + "type": "Identifier", + "name": "z", + "loc": { + "start": { + "line": 1, + "column": 8 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/182/actual.js b/packages/babylon/test/fixtures/core/uncategorised/182/actual.js new file mode 100644 index 0000000000..50a532b6bb --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/182/actual.js @@ -0,0 +1 @@ +x * y % z \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/182/expected.json b/packages/babylon/test/fixtures/core/uncategorised/182/expected.json new file mode 100644 index 0000000000..d4a4206014 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/182/expected.json @@ -0,0 +1,98 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "BinaryExpression", + "left": { + "type": "BinaryExpression", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "operator": "*", + "right": { + "type": "Identifier", + "name": "y", + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "operator": "%", + "right": { + "type": "Identifier", + "name": "z", + "loc": { + "start": { + "line": 1, + "column": 8 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/183/actual.js b/packages/babylon/test/fixtures/core/uncategorised/183/actual.js new file mode 100644 index 0000000000..5d25d998e0 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/183/actual.js @@ -0,0 +1 @@ +x % y * z \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/183/expected.json b/packages/babylon/test/fixtures/core/uncategorised/183/expected.json new file mode 100644 index 0000000000..8b33ca21e5 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/183/expected.json @@ -0,0 +1,98 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "BinaryExpression", + "left": { + "type": "BinaryExpression", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "operator": "%", + "right": { + "type": "Identifier", + "name": "y", + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "operator": "*", + "right": { + "type": "Identifier", + "name": "z", + "loc": { + "start": { + "line": 1, + "column": 8 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/184/actual.js b/packages/babylon/test/fixtures/core/uncategorised/184/actual.js new file mode 100644 index 0000000000..06c766c2d9 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/184/actual.js @@ -0,0 +1 @@ +x << y << z \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/184/expected.json b/packages/babylon/test/fixtures/core/uncategorised/184/expected.json new file mode 100644 index 0000000000..2a39ce2b88 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/184/expected.json @@ -0,0 +1,98 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "BinaryExpression", + "left": { + "type": "BinaryExpression", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "operator": "<<", + "right": { + "type": "Identifier", + "name": "y", + "loc": { + "start": { + "line": 1, + "column": 5 + }, + "end": { + "line": 1, + "column": 6 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 6 + } + } + }, + "operator": "<<", + "right": { + "type": "Identifier", + "name": "z", + "loc": { + "start": { + "line": 1, + "column": 10 + }, + "end": { + "line": 1, + "column": 11 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 11 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 11 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 11 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/185/actual.js b/packages/babylon/test/fixtures/core/uncategorised/185/actual.js new file mode 100644 index 0000000000..d58330b3e9 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/185/actual.js @@ -0,0 +1 @@ +x | y | z \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/185/expected.json b/packages/babylon/test/fixtures/core/uncategorised/185/expected.json new file mode 100644 index 0000000000..4ef578d702 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/185/expected.json @@ -0,0 +1,98 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "BinaryExpression", + "left": { + "type": "BinaryExpression", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "operator": "|", + "right": { + "type": "Identifier", + "name": "y", + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "operator": "|", + "right": { + "type": "Identifier", + "name": "z", + "loc": { + "start": { + "line": 1, + "column": 8 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/186/actual.js b/packages/babylon/test/fixtures/core/uncategorised/186/actual.js new file mode 100644 index 0000000000..bab523a946 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/186/actual.js @@ -0,0 +1 @@ +x & y & z \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/186/expected.json b/packages/babylon/test/fixtures/core/uncategorised/186/expected.json new file mode 100644 index 0000000000..1be809919c --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/186/expected.json @@ -0,0 +1,98 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "BinaryExpression", + "left": { + "type": "BinaryExpression", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "operator": "&", + "right": { + "type": "Identifier", + "name": "y", + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "operator": "&", + "right": { + "type": "Identifier", + "name": "z", + "loc": { + "start": { + "line": 1, + "column": 8 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/187/actual.js b/packages/babylon/test/fixtures/core/uncategorised/187/actual.js new file mode 100644 index 0000000000..ab3e2601b8 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/187/actual.js @@ -0,0 +1 @@ +x ^ y ^ z \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/187/expected.json b/packages/babylon/test/fixtures/core/uncategorised/187/expected.json new file mode 100644 index 0000000000..3144ac72bf --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/187/expected.json @@ -0,0 +1,98 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "BinaryExpression", + "left": { + "type": "BinaryExpression", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "operator": "^", + "right": { + "type": "Identifier", + "name": "y", + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "operator": "^", + "right": { + "type": "Identifier", + "name": "z", + "loc": { + "start": { + "line": 1, + "column": 8 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/188/actual.js b/packages/babylon/test/fixtures/core/uncategorised/188/actual.js new file mode 100644 index 0000000000..1421c449aa --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/188/actual.js @@ -0,0 +1 @@ +x & y | z \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/188/expected.json b/packages/babylon/test/fixtures/core/uncategorised/188/expected.json new file mode 100644 index 0000000000..6b171f1ce6 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/188/expected.json @@ -0,0 +1,98 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "BinaryExpression", + "left": { + "type": "BinaryExpression", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "operator": "&", + "right": { + "type": "Identifier", + "name": "y", + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "operator": "|", + "right": { + "type": "Identifier", + "name": "z", + "loc": { + "start": { + "line": 1, + "column": 8 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/189/actual.js b/packages/babylon/test/fixtures/core/uncategorised/189/actual.js new file mode 100644 index 0000000000..96ba00381a --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/189/actual.js @@ -0,0 +1 @@ +x | y ^ z \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/189/expected.json b/packages/babylon/test/fixtures/core/uncategorised/189/expected.json new file mode 100644 index 0000000000..e498c699e3 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/189/expected.json @@ -0,0 +1,98 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "BinaryExpression", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "operator": "|", + "right": { + "type": "BinaryExpression", + "left": { + "type": "Identifier", + "name": "y", + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "operator": "^", + "right": { + "type": "Identifier", + "name": "z", + "loc": { + "start": { + "line": 1, + "column": 8 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/19/actual.js b/packages/babylon/test/fixtures/core/uncategorised/19/actual.js new file mode 100644 index 0000000000..e11bf2dae4 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/19/actual.js @@ -0,0 +1 @@ +ⅣⅡ = [] \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/19/expected.json b/packages/babylon/test/fixtures/core/uncategorised/19/expected.json new file mode 100644 index 0000000000..65188d0276 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/19/expected.json @@ -0,0 +1,70 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "AssignmentExpression", + "operator": "=", + "left": { + "type": "Identifier", + "name": "ⅣⅡ", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 2 + } + } + }, + "right": { + "type": "ArrayExpression", + "elements": [], + "loc": { + "start": { + "line": 1, + "column": 5 + }, + "end": { + "line": 1, + "column": 7 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 7 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 7 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 7 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/190/actual.js b/packages/babylon/test/fixtures/core/uncategorised/190/actual.js new file mode 100644 index 0000000000..aa9af9ca39 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/190/actual.js @@ -0,0 +1 @@ +x | y & z \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/190/expected.json b/packages/babylon/test/fixtures/core/uncategorised/190/expected.json new file mode 100644 index 0000000000..7fb69d1286 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/190/expected.json @@ -0,0 +1,98 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "BinaryExpression", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "operator": "|", + "right": { + "type": "BinaryExpression", + "left": { + "type": "Identifier", + "name": "y", + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "operator": "&", + "right": { + "type": "Identifier", + "name": "z", + "loc": { + "start": { + "line": 1, + "column": 8 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/191/actual.js b/packages/babylon/test/fixtures/core/uncategorised/191/actual.js new file mode 100644 index 0000000000..a8ade4585c --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/191/actual.js @@ -0,0 +1 @@ +x || y \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/191/expected.json b/packages/babylon/test/fixtures/core/uncategorised/191/expected.json new file mode 100644 index 0000000000..47fe7bc41b --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/191/expected.json @@ -0,0 +1,70 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "LogicalExpression", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "operator": "||", + "right": { + "type": "Identifier", + "name": "y", + "loc": { + "start": { + "line": 1, + "column": 5 + }, + "end": { + "line": 1, + "column": 6 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 6 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 6 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 6 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/192/actual.js b/packages/babylon/test/fixtures/core/uncategorised/192/actual.js new file mode 100644 index 0000000000..ffe862c808 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/192/actual.js @@ -0,0 +1 @@ +x && y \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/192/expected.json b/packages/babylon/test/fixtures/core/uncategorised/192/expected.json new file mode 100644 index 0000000000..e04d903ba5 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/192/expected.json @@ -0,0 +1,70 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "LogicalExpression", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "operator": "&&", + "right": { + "type": "Identifier", + "name": "y", + "loc": { + "start": { + "line": 1, + "column": 5 + }, + "end": { + "line": 1, + "column": 6 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 6 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 6 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 6 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/193/actual.js b/packages/babylon/test/fixtures/core/uncategorised/193/actual.js new file mode 100644 index 0000000000..2b9f0bc84a --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/193/actual.js @@ -0,0 +1 @@ +x || y || z \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/193/expected.json b/packages/babylon/test/fixtures/core/uncategorised/193/expected.json new file mode 100644 index 0000000000..1179b3478d --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/193/expected.json @@ -0,0 +1,98 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "LogicalExpression", + "left": { + "type": "LogicalExpression", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "operator": "||", + "right": { + "type": "Identifier", + "name": "y", + "loc": { + "start": { + "line": 1, + "column": 5 + }, + "end": { + "line": 1, + "column": 6 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 6 + } + } + }, + "operator": "||", + "right": { + "type": "Identifier", + "name": "z", + "loc": { + "start": { + "line": 1, + "column": 10 + }, + "end": { + "line": 1, + "column": 11 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 11 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 11 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 11 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/194/actual.js b/packages/babylon/test/fixtures/core/uncategorised/194/actual.js new file mode 100644 index 0000000000..e0346bb51d --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/194/actual.js @@ -0,0 +1 @@ +x && y && z \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/194/expected.json b/packages/babylon/test/fixtures/core/uncategorised/194/expected.json new file mode 100644 index 0000000000..8d625034fc --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/194/expected.json @@ -0,0 +1,98 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "LogicalExpression", + "left": { + "type": "LogicalExpression", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "operator": "&&", + "right": { + "type": "Identifier", + "name": "y", + "loc": { + "start": { + "line": 1, + "column": 5 + }, + "end": { + "line": 1, + "column": 6 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 6 + } + } + }, + "operator": "&&", + "right": { + "type": "Identifier", + "name": "z", + "loc": { + "start": { + "line": 1, + "column": 10 + }, + "end": { + "line": 1, + "column": 11 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 11 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 11 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 11 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/195/actual.js b/packages/babylon/test/fixtures/core/uncategorised/195/actual.js new file mode 100644 index 0000000000..b76f785341 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/195/actual.js @@ -0,0 +1 @@ +x || y && z \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/195/expected.json b/packages/babylon/test/fixtures/core/uncategorised/195/expected.json new file mode 100644 index 0000000000..78f4232d49 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/195/expected.json @@ -0,0 +1,98 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "LogicalExpression", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "operator": "||", + "right": { + "type": "LogicalExpression", + "left": { + "type": "Identifier", + "name": "y", + "loc": { + "start": { + "line": 1, + "column": 5 + }, + "end": { + "line": 1, + "column": 6 + } + } + }, + "operator": "&&", + "right": { + "type": "Identifier", + "name": "z", + "loc": { + "start": { + "line": 1, + "column": 10 + }, + "end": { + "line": 1, + "column": 11 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 5 + }, + "end": { + "line": 1, + "column": 11 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 11 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 11 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 11 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/196/actual.js b/packages/babylon/test/fixtures/core/uncategorised/196/actual.js new file mode 100644 index 0000000000..5e12a04ee9 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/196/actual.js @@ -0,0 +1 @@ +x || y ^ z \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/196/expected.json b/packages/babylon/test/fixtures/core/uncategorised/196/expected.json new file mode 100644 index 0000000000..192bd76118 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/196/expected.json @@ -0,0 +1,98 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "LogicalExpression", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "operator": "||", + "right": { + "type": "BinaryExpression", + "left": { + "type": "Identifier", + "name": "y", + "loc": { + "start": { + "line": 1, + "column": 5 + }, + "end": { + "line": 1, + "column": 6 + } + } + }, + "operator": "^", + "right": { + "type": "Identifier", + "name": "z", + "loc": { + "start": { + "line": 1, + "column": 9 + }, + "end": { + "line": 1, + "column": 10 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 5 + }, + "end": { + "line": 1, + "column": 10 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 10 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 10 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 10 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/197/actual.js b/packages/babylon/test/fixtures/core/uncategorised/197/actual.js new file mode 100644 index 0000000000..f042369fb2 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/197/actual.js @@ -0,0 +1 @@ +y ? 1 : 2 \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/197/expected.json b/packages/babylon/test/fixtures/core/uncategorised/197/expected.json new file mode 100644 index 0000000000..71d41c2bd0 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/197/expected.json @@ -0,0 +1,83 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "ConditionalExpression", + "test": { + "type": "Identifier", + "name": "y", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "consequent": { + "type": "Literal", + "value": 1, + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "alternate": { + "type": "Literal", + "value": 2, + "loc": { + "start": { + "line": 1, + "column": 8 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/198/actual.js b/packages/babylon/test/fixtures/core/uncategorised/198/actual.js new file mode 100644 index 0000000000..2d9c14cd46 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/198/actual.js @@ -0,0 +1 @@ +x && y ? 1 : 2 \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/198/expected.json b/packages/babylon/test/fixtures/core/uncategorised/198/expected.json new file mode 100644 index 0000000000..9e32ee478e --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/198/expected.json @@ -0,0 +1,111 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "ConditionalExpression", + "test": { + "type": "LogicalExpression", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "operator": "&&", + "right": { + "type": "Identifier", + "name": "y", + "loc": { + "start": { + "line": 1, + "column": 5 + }, + "end": { + "line": 1, + "column": 6 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 6 + } + } + }, + "consequent": { + "type": "Literal", + "value": 1, + "loc": { + "start": { + "line": 1, + "column": 9 + }, + "end": { + "line": 1, + "column": 10 + } + } + }, + "alternate": { + "type": "Literal", + "value": 2, + "loc": { + "start": { + "line": 1, + "column": 13 + }, + "end": { + "line": 1, + "column": 14 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 14 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 14 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 14 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/199/actual.js b/packages/babylon/test/fixtures/core/uncategorised/199/actual.js new file mode 100644 index 0000000000..4452ec6797 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/199/actual.js @@ -0,0 +1 @@ +x = 42 \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/199/expected.json b/packages/babylon/test/fixtures/core/uncategorised/199/expected.json new file mode 100644 index 0000000000..33d74af1da --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/199/expected.json @@ -0,0 +1,70 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "AssignmentExpression", + "operator": "=", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "right": { + "type": "Literal", + "value": 42, + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 6 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 6 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 6 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 6 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/2/actual.js b/packages/babylon/test/fixtures/core/uncategorised/2/actual.js new file mode 100644 index 0000000000..19765bd501 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/2/actual.js @@ -0,0 +1 @@ +null diff --git a/packages/babylon/test/fixtures/core/uncategorised/2/expected.json b/packages/babylon/test/fixtures/core/uncategorised/2/expected.json new file mode 100644 index 0000000000..aa59ba7b25 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/2/expected.json @@ -0,0 +1,51 @@ +{ + "type": "Program", + "start": 0, + "end": 4, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 4 + } + }, + "sourceType": "script", + "body": [ + { + "type": "ExpressionStatement", + "start": 0, + "end": 4, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 4 + } + }, + "expression": { + "type": "Literal", + "start": 0, + "end": 4, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 4 + } + }, + "value": null, + "rawValue": null, + "raw": "null" + } + } + ] +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/20/actual.js b/packages/babylon/test/fixtures/core/uncategorised/20/actual.js new file mode 100644 index 0000000000..ad9234753c --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/20/actual.js @@ -0,0 +1 @@ +x = {} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/20/expected.json b/packages/babylon/test/fixtures/core/uncategorised/20/expected.json new file mode 100644 index 0000000000..4d02d1291a --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/20/expected.json @@ -0,0 +1,70 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "AssignmentExpression", + "operator": "=", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "right": { + "type": "ObjectExpression", + "properties": [], + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 6 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 6 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 6 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 6 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/200/actual.js b/packages/babylon/test/fixtures/core/uncategorised/200/actual.js new file mode 100644 index 0000000000..d1e8c3862e --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/200/actual.js @@ -0,0 +1 @@ +eval = 42 \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/200/expected.json b/packages/babylon/test/fixtures/core/uncategorised/200/expected.json new file mode 100644 index 0000000000..33bd7aa74b --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/200/expected.json @@ -0,0 +1,70 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "AssignmentExpression", + "operator": "=", + "left": { + "type": "Identifier", + "name": "eval", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 4 + } + } + }, + "right": { + "type": "Literal", + "value": 42, + "loc": { + "start": { + "line": 1, + "column": 7 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/201/actual.js b/packages/babylon/test/fixtures/core/uncategorised/201/actual.js new file mode 100644 index 0000000000..dde1683c49 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/201/actual.js @@ -0,0 +1 @@ +arguments = 42 \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/201/expected.json b/packages/babylon/test/fixtures/core/uncategorised/201/expected.json new file mode 100644 index 0000000000..96dafe01f2 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/201/expected.json @@ -0,0 +1,70 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "AssignmentExpression", + "operator": "=", + "left": { + "type": "Identifier", + "name": "arguments", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + "right": { + "type": "Literal", + "value": 42, + "loc": { + "start": { + "line": 1, + "column": 12 + }, + "end": { + "line": 1, + "column": 14 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 14 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 14 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 14 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/202/actual.js b/packages/babylon/test/fixtures/core/uncategorised/202/actual.js new file mode 100644 index 0000000000..9addd71c80 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/202/actual.js @@ -0,0 +1 @@ +x *= 42 \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/202/expected.json b/packages/babylon/test/fixtures/core/uncategorised/202/expected.json new file mode 100644 index 0000000000..77c3ad2189 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/202/expected.json @@ -0,0 +1,70 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "AssignmentExpression", + "operator": "*=", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "right": { + "type": "Literal", + "value": 42, + "loc": { + "start": { + "line": 1, + "column": 5 + }, + "end": { + "line": 1, + "column": 7 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 7 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 7 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 7 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/203/actual.js b/packages/babylon/test/fixtures/core/uncategorised/203/actual.js new file mode 100644 index 0000000000..23b2b58bcd --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/203/actual.js @@ -0,0 +1 @@ +x /= 42 \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/203/expected.json b/packages/babylon/test/fixtures/core/uncategorised/203/expected.json new file mode 100644 index 0000000000..8a3fd06d68 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/203/expected.json @@ -0,0 +1,70 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "AssignmentExpression", + "operator": "/=", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "right": { + "type": "Literal", + "value": 42, + "loc": { + "start": { + "line": 1, + "column": 5 + }, + "end": { + "line": 1, + "column": 7 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 7 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 7 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 7 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/204/actual.js b/packages/babylon/test/fixtures/core/uncategorised/204/actual.js new file mode 100644 index 0000000000..c4d5c9e90e --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/204/actual.js @@ -0,0 +1 @@ +x %= 42 \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/204/expected.json b/packages/babylon/test/fixtures/core/uncategorised/204/expected.json new file mode 100644 index 0000000000..0671efd066 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/204/expected.json @@ -0,0 +1,70 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "AssignmentExpression", + "operator": "%=", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "right": { + "type": "Literal", + "value": 42, + "loc": { + "start": { + "line": 1, + "column": 5 + }, + "end": { + "line": 1, + "column": 7 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 7 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 7 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 7 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/205/actual.js b/packages/babylon/test/fixtures/core/uncategorised/205/actual.js new file mode 100644 index 0000000000..217b625089 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/205/actual.js @@ -0,0 +1 @@ +x += 42 \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/205/expected.json b/packages/babylon/test/fixtures/core/uncategorised/205/expected.json new file mode 100644 index 0000000000..c0a01fab8b --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/205/expected.json @@ -0,0 +1,70 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "AssignmentExpression", + "operator": "+=", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "right": { + "type": "Literal", + "value": 42, + "loc": { + "start": { + "line": 1, + "column": 5 + }, + "end": { + "line": 1, + "column": 7 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 7 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 7 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 7 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/206/actual.js b/packages/babylon/test/fixtures/core/uncategorised/206/actual.js new file mode 100644 index 0000000000..d79ce3418a --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/206/actual.js @@ -0,0 +1 @@ +x -= 42 \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/206/expected.json b/packages/babylon/test/fixtures/core/uncategorised/206/expected.json new file mode 100644 index 0000000000..425b843c57 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/206/expected.json @@ -0,0 +1,70 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "AssignmentExpression", + "operator": "-=", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "right": { + "type": "Literal", + "value": 42, + "loc": { + "start": { + "line": 1, + "column": 5 + }, + "end": { + "line": 1, + "column": 7 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 7 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 7 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 7 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/207/actual.js b/packages/babylon/test/fixtures/core/uncategorised/207/actual.js new file mode 100644 index 0000000000..5ad52f72cd --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/207/actual.js @@ -0,0 +1 @@ +x <<= 42 \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/207/expected.json b/packages/babylon/test/fixtures/core/uncategorised/207/expected.json new file mode 100644 index 0000000000..2369010c4f --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/207/expected.json @@ -0,0 +1,70 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "AssignmentExpression", + "operator": "<<=", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "right": { + "type": "Literal", + "value": 42, + "loc": { + "start": { + "line": 1, + "column": 6 + }, + "end": { + "line": 1, + "column": 8 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 8 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 8 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 8 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/208/actual.js b/packages/babylon/test/fixtures/core/uncategorised/208/actual.js new file mode 100644 index 0000000000..80af4fd232 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/208/actual.js @@ -0,0 +1 @@ +x >>= 42 \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/208/expected.json b/packages/babylon/test/fixtures/core/uncategorised/208/expected.json new file mode 100644 index 0000000000..6a2a0d471e --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/208/expected.json @@ -0,0 +1,70 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "AssignmentExpression", + "operator": ">>=", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "right": { + "type": "Literal", + "value": 42, + "loc": { + "start": { + "line": 1, + "column": 6 + }, + "end": { + "line": 1, + "column": 8 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 8 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 8 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 8 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/209/actual.js b/packages/babylon/test/fixtures/core/uncategorised/209/actual.js new file mode 100644 index 0000000000..c8b561c90a --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/209/actual.js @@ -0,0 +1 @@ +x >>>= 42 \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/209/expected.json b/packages/babylon/test/fixtures/core/uncategorised/209/expected.json new file mode 100644 index 0000000000..f5122f299e --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/209/expected.json @@ -0,0 +1,70 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "AssignmentExpression", + "operator": ">>>=", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "right": { + "type": "Literal", + "value": 42, + "loc": { + "start": { + "line": 1, + "column": 7 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/21/actual.js b/packages/babylon/test/fixtures/core/uncategorised/21/actual.js new file mode 100644 index 0000000000..e2070b1349 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/21/actual.js @@ -0,0 +1 @@ +x = { } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/21/expected.json b/packages/babylon/test/fixtures/core/uncategorised/21/expected.json new file mode 100644 index 0000000000..3d6bb1973e --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/21/expected.json @@ -0,0 +1,70 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "AssignmentExpression", + "operator": "=", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "right": { + "type": "ObjectExpression", + "properties": [], + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 7 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 7 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 7 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 7 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/210/actual.js b/packages/babylon/test/fixtures/core/uncategorised/210/actual.js new file mode 100644 index 0000000000..98b2f5429b --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/210/actual.js @@ -0,0 +1 @@ +x &= 42 \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/210/expected.json b/packages/babylon/test/fixtures/core/uncategorised/210/expected.json new file mode 100644 index 0000000000..72c27843a4 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/210/expected.json @@ -0,0 +1,70 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "AssignmentExpression", + "operator": "&=", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "right": { + "type": "Literal", + "value": 42, + "loc": { + "start": { + "line": 1, + "column": 5 + }, + "end": { + "line": 1, + "column": 7 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 7 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 7 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 7 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/211/actual.js b/packages/babylon/test/fixtures/core/uncategorised/211/actual.js new file mode 100644 index 0000000000..f2c536bedb --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/211/actual.js @@ -0,0 +1 @@ +x ^= 42 \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/211/expected.json b/packages/babylon/test/fixtures/core/uncategorised/211/expected.json new file mode 100644 index 0000000000..92d5f8112f --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/211/expected.json @@ -0,0 +1,70 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "AssignmentExpression", + "operator": "^=", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "right": { + "type": "Literal", + "value": 42, + "loc": { + "start": { + "line": 1, + "column": 5 + }, + "end": { + "line": 1, + "column": 7 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 7 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 7 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 7 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/212/actual.js b/packages/babylon/test/fixtures/core/uncategorised/212/actual.js new file mode 100644 index 0000000000..af7ab3b054 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/212/actual.js @@ -0,0 +1 @@ +x |= 42 \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/212/expected.json b/packages/babylon/test/fixtures/core/uncategorised/212/expected.json new file mode 100644 index 0000000000..0332188955 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/212/expected.json @@ -0,0 +1,70 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "AssignmentExpression", + "operator": "|=", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "right": { + "type": "Literal", + "value": 42, + "loc": { + "start": { + "line": 1, + "column": 5 + }, + "end": { + "line": 1, + "column": 7 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 7 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 7 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 7 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/213/actual.js b/packages/babylon/test/fixtures/core/uncategorised/213/actual.js new file mode 100644 index 0000000000..d97825eac8 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/213/actual.js @@ -0,0 +1 @@ +{ foo } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/213/expected.json b/packages/babylon/test/fixtures/core/uncategorised/213/expected.json new file mode 100644 index 0000000000..2e84228e77 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/213/expected.json @@ -0,0 +1,57 @@ +{ + "type": "Program", + "body": [ + { + "type": "BlockStatement", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "Identifier", + "name": "foo", + "loc": { + "start": { + "line": 1, + "column": 2 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 2 + }, + "end": { + "line": 1, + "column": 5 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 7 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 7 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/214/actual.js b/packages/babylon/test/fixtures/core/uncategorised/214/actual.js new file mode 100644 index 0000000000..b258b54f9c --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/214/actual.js @@ -0,0 +1 @@ +{ doThis(); doThat(); } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/214/expected.json b/packages/babylon/test/fixtures/core/uncategorised/214/expected.json new file mode 100644 index 0000000000..c4a8e05788 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/214/expected.json @@ -0,0 +1,112 @@ +{ + "type": "Program", + "body": [ + { + "type": "BlockStatement", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "CallExpression", + "callee": { + "type": "Identifier", + "name": "doThis", + "loc": { + "start": { + "line": 1, + "column": 2 + }, + "end": { + "line": 1, + "column": 8 + } + } + }, + "arguments": [], + "loc": { + "start": { + "line": 1, + "column": 2 + }, + "end": { + "line": 1, + "column": 10 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 2 + }, + "end": { + "line": 1, + "column": 11 + } + } + }, + { + "type": "ExpressionStatement", + "expression": { + "type": "CallExpression", + "callee": { + "type": "Identifier", + "name": "doThat", + "loc": { + "start": { + "line": 1, + "column": 12 + }, + "end": { + "line": 1, + "column": 18 + } + } + }, + "arguments": [], + "loc": { + "start": { + "line": 1, + "column": 12 + }, + "end": { + "line": 1, + "column": 20 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 12 + }, + "end": { + "line": 1, + "column": 21 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 23 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 23 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/215/actual.js b/packages/babylon/test/fixtures/core/uncategorised/215/actual.js new file mode 100644 index 0000000000..9e26dfeeb6 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/215/actual.js @@ -0,0 +1 @@ +{} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/215/expected.json b/packages/babylon/test/fixtures/core/uncategorised/215/expected.json new file mode 100644 index 0000000000..3c9148b75a --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/215/expected.json @@ -0,0 +1,29 @@ +{ + "type": "Program", + "body": [ + { + "type": "BlockStatement", + "body": [], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 2 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 2 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/216/actual.js b/packages/babylon/test/fixtures/core/uncategorised/216/actual.js new file mode 100644 index 0000000000..72f136bbb7 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/216/actual.js @@ -0,0 +1 @@ +var x \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/216/expected.json b/packages/babylon/test/fixtures/core/uncategorised/216/expected.json new file mode 100644 index 0000000000..36be7ef1e5 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/216/expected.json @@ -0,0 +1,59 @@ +{ + "type": "Program", + "body": [ + { + "type": "VariableDeclaration", + "declarations": [ + { + "type": "VariableDeclarator", + "id": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "init": null, + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 5 + } + } + } + ], + "kind": "var", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 5 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 5 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/217/actual.js b/packages/babylon/test/fixtures/core/uncategorised/217/actual.js new file mode 100644 index 0000000000..84592dd6d3 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/217/actual.js @@ -0,0 +1 @@ +var x, y; \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/217/expected.json b/packages/babylon/test/fixtures/core/uncategorised/217/expected.json new file mode 100644 index 0000000000..fb5fa4bf0b --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/217/expected.json @@ -0,0 +1,87 @@ +{ + "type": "Program", + "body": [ + { + "type": "VariableDeclaration", + "declarations": [ + { + "type": "VariableDeclarator", + "id": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "init": null, + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + { + "type": "VariableDeclarator", + "id": { + "type": "Identifier", + "name": "y", + "loc": { + "start": { + "line": 1, + "column": 7 + }, + "end": { + "line": 1, + "column": 8 + } + } + }, + "init": null, + "loc": { + "start": { + "line": 1, + "column": 7 + }, + "end": { + "line": 1, + "column": 8 + } + } + } + ], + "kind": "var", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/218/actual.js b/packages/babylon/test/fixtures/core/uncategorised/218/actual.js new file mode 100644 index 0000000000..af223d05de --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/218/actual.js @@ -0,0 +1 @@ +var x = 42 \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/218/expected.json b/packages/babylon/test/fixtures/core/uncategorised/218/expected.json new file mode 100644 index 0000000000..bb752e2a26 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/218/expected.json @@ -0,0 +1,72 @@ +{ + "type": "Program", + "body": [ + { + "type": "VariableDeclaration", + "declarations": [ + { + "type": "VariableDeclarator", + "id": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "init": { + "type": "Literal", + "value": 42, + "loc": { + "start": { + "line": 1, + "column": 8 + }, + "end": { + "line": 1, + "column": 10 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 10 + } + } + } + ], + "kind": "var", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 10 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 10 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/219/actual.js b/packages/babylon/test/fixtures/core/uncategorised/219/actual.js new file mode 100644 index 0000000000..6903ba0a49 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/219/actual.js @@ -0,0 +1 @@ +var eval = 42, arguments = 42 \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/219/expected.json b/packages/babylon/test/fixtures/core/uncategorised/219/expected.json new file mode 100644 index 0000000000..5615d9f56f --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/219/expected.json @@ -0,0 +1,113 @@ +{ + "type": "Program", + "body": [ + { + "type": "VariableDeclaration", + "declarations": [ + { + "type": "VariableDeclarator", + "id": { + "type": "Identifier", + "name": "eval", + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 8 + } + } + }, + "init": { + "type": "Literal", + "value": 42, + "loc": { + "start": { + "line": 1, + "column": 11 + }, + "end": { + "line": 1, + "column": 13 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 13 + } + } + }, + { + "type": "VariableDeclarator", + "id": { + "type": "Identifier", + "name": "arguments", + "loc": { + "start": { + "line": 1, + "column": 15 + }, + "end": { + "line": 1, + "column": 24 + } + } + }, + "init": { + "type": "Literal", + "value": 42, + "loc": { + "start": { + "line": 1, + "column": 27 + }, + "end": { + "line": 1, + "column": 29 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 15 + }, + "end": { + "line": 1, + "column": 29 + } + } + } + ], + "kind": "var", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 29 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 29 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/22/actual.js b/packages/babylon/test/fixtures/core/uncategorised/22/actual.js new file mode 100644 index 0000000000..ac27b07c1f --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/22/actual.js @@ -0,0 +1 @@ +x = { answer: 42 } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/22/expected.json b/packages/babylon/test/fixtures/core/uncategorised/22/expected.json new file mode 100644 index 0000000000..a43e63a5a7 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/22/expected.json @@ -0,0 +1,103 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "AssignmentExpression", + "operator": "=", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "right": { + "type": "ObjectExpression", + "properties": [ + { + "type": "Property", + "key": { + "type": "Identifier", + "name": "answer", + "loc": { + "start": { + "line": 1, + "column": 6 + }, + "end": { + "line": 1, + "column": 12 + } + } + }, + "value": { + "type": "Literal", + "value": 42, + "loc": { + "start": { + "line": 1, + "column": 14 + }, + "end": { + "line": 1, + "column": 16 + } + } + }, + "kind": "init" + } + ], + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 18 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 18 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 18 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 18 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/220/actual.js b/packages/babylon/test/fixtures/core/uncategorised/220/actual.js new file mode 100644 index 0000000000..984fdd2e05 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/220/actual.js @@ -0,0 +1 @@ +var x = 14, y = 3, z = 1977 \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/220/expected.json b/packages/babylon/test/fixtures/core/uncategorised/220/expected.json new file mode 100644 index 0000000000..de593b3f6f --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/220/expected.json @@ -0,0 +1,154 @@ +{ + "type": "Program", + "body": [ + { + "type": "VariableDeclaration", + "declarations": [ + { + "type": "VariableDeclarator", + "id": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "init": { + "type": "Literal", + "value": 14, + "loc": { + "start": { + "line": 1, + "column": 8 + }, + "end": { + "line": 1, + "column": 10 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 10 + } + } + }, + { + "type": "VariableDeclarator", + "id": { + "type": "Identifier", + "name": "y", + "loc": { + "start": { + "line": 1, + "column": 12 + }, + "end": { + "line": 1, + "column": 13 + } + } + }, + "init": { + "type": "Literal", + "value": 3, + "loc": { + "start": { + "line": 1, + "column": 16 + }, + "end": { + "line": 1, + "column": 17 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 12 + }, + "end": { + "line": 1, + "column": 17 + } + } + }, + { + "type": "VariableDeclarator", + "id": { + "type": "Identifier", + "name": "z", + "loc": { + "start": { + "line": 1, + "column": 19 + }, + "end": { + "line": 1, + "column": 20 + } + } + }, + "init": { + "type": "Literal", + "value": 1977, + "loc": { + "start": { + "line": 1, + "column": 23 + }, + "end": { + "line": 1, + "column": 27 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 19 + }, + "end": { + "line": 1, + "column": 27 + } + } + } + ], + "kind": "var", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 27 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 27 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/221/actual.js b/packages/babylon/test/fixtures/core/uncategorised/221/actual.js new file mode 100644 index 0000000000..179e8b5cab --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/221/actual.js @@ -0,0 +1 @@ +var implements, interface, package \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/221/expected.json b/packages/babylon/test/fixtures/core/uncategorised/221/expected.json new file mode 100644 index 0000000000..61a8414b5a --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/221/expected.json @@ -0,0 +1,115 @@ +{ + "type": "Program", + "body": [ + { + "type": "VariableDeclaration", + "declarations": [ + { + "type": "VariableDeclarator", + "id": { + "type": "Identifier", + "name": "implements", + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 14 + } + } + }, + "init": null, + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 14 + } + } + }, + { + "type": "VariableDeclarator", + "id": { + "type": "Identifier", + "name": "interface", + "loc": { + "start": { + "line": 1, + "column": 16 + }, + "end": { + "line": 1, + "column": 25 + } + } + }, + "init": null, + "loc": { + "start": { + "line": 1, + "column": 16 + }, + "end": { + "line": 1, + "column": 25 + } + } + }, + { + "type": "VariableDeclarator", + "id": { + "type": "Identifier", + "name": "package", + "loc": { + "start": { + "line": 1, + "column": 27 + }, + "end": { + "line": 1, + "column": 34 + } + } + }, + "init": null, + "loc": { + "start": { + "line": 1, + "column": 27 + }, + "end": { + "line": 1, + "column": 34 + } + } + } + ], + "kind": "var", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 34 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 34 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/222/actual.js b/packages/babylon/test/fixtures/core/uncategorised/222/actual.js new file mode 100644 index 0000000000..d2c2ed5b68 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/222/actual.js @@ -0,0 +1 @@ +var private, protected, public, static \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/222/expected.json b/packages/babylon/test/fixtures/core/uncategorised/222/expected.json new file mode 100644 index 0000000000..7fa42d7b08 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/222/expected.json @@ -0,0 +1,143 @@ +{ + "type": "Program", + "body": [ + { + "type": "VariableDeclaration", + "declarations": [ + { + "type": "VariableDeclarator", + "id": { + "type": "Identifier", + "name": "private", + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 11 + } + } + }, + "init": null, + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 11 + } + } + }, + { + "type": "VariableDeclarator", + "id": { + "type": "Identifier", + "name": "protected", + "loc": { + "start": { + "line": 1, + "column": 13 + }, + "end": { + "line": 1, + "column": 22 + } + } + }, + "init": null, + "loc": { + "start": { + "line": 1, + "column": 13 + }, + "end": { + "line": 1, + "column": 22 + } + } + }, + { + "type": "VariableDeclarator", + "id": { + "type": "Identifier", + "name": "public", + "loc": { + "start": { + "line": 1, + "column": 24 + }, + "end": { + "line": 1, + "column": 30 + } + } + }, + "init": null, + "loc": { + "start": { + "line": 1, + "column": 24 + }, + "end": { + "line": 1, + "column": 30 + } + } + }, + { + "type": "VariableDeclarator", + "id": { + "type": "Identifier", + "name": "static", + "loc": { + "start": { + "line": 1, + "column": 32 + }, + "end": { + "line": 1, + "column": 38 + } + } + }, + "init": null, + "loc": { + "start": { + "line": 1, + "column": 32 + }, + "end": { + "line": 1, + "column": 38 + } + } + } + ], + "kind": "var", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 38 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 38 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/223/actual.js b/packages/babylon/test/fixtures/core/uncategorised/223/actual.js new file mode 100644 index 0000000000..1c8a0e7976 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/223/actual.js @@ -0,0 +1 @@ +; \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/223/expected.json b/packages/babylon/test/fixtures/core/uncategorised/223/expected.json new file mode 100644 index 0000000000..fbaa880052 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/223/expected.json @@ -0,0 +1,28 @@ +{ + "type": "Program", + "body": [ + { + "type": "EmptyStatement", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/224/actual.js b/packages/babylon/test/fixtures/core/uncategorised/224/actual.js new file mode 100644 index 0000000000..c1b0730e01 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/224/actual.js @@ -0,0 +1 @@ +x \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/224/expected.json b/packages/babylon/test/fixtures/core/uncategorised/224/expected.json new file mode 100644 index 0000000000..945e197915 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/224/expected.json @@ -0,0 +1,42 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/225/actual.js b/packages/babylon/test/fixtures/core/uncategorised/225/actual.js new file mode 100644 index 0000000000..76daf19bb5 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/225/actual.js @@ -0,0 +1 @@ +x, y \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/225/expected.json b/packages/babylon/test/fixtures/core/uncategorised/225/expected.json new file mode 100644 index 0000000000..c3ec6db0da --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/225/expected.json @@ -0,0 +1,71 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "SequenceExpression", + "expressions": [ + { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + { + "type": "Identifier", + "name": "y", + "loc": { + "start": { + "line": 1, + "column": 3 + }, + "end": { + "line": 1, + "column": 4 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 4 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 4 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 4 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/226/actual.js b/packages/babylon/test/fixtures/core/uncategorised/226/actual.js new file mode 100644 index 0000000000..440c382031 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/226/actual.js @@ -0,0 +1 @@ +\u0061 \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/226/expected.json b/packages/babylon/test/fixtures/core/uncategorised/226/expected.json new file mode 100644 index 0000000000..722b86412e --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/226/expected.json @@ -0,0 +1,42 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "Identifier", + "name": "a", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 6 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 6 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 6 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/227/actual.js b/packages/babylon/test/fixtures/core/uncategorised/227/actual.js new file mode 100644 index 0000000000..09556b60a5 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/227/actual.js @@ -0,0 +1 @@ +a\u0061 \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/227/expected.json b/packages/babylon/test/fixtures/core/uncategorised/227/expected.json new file mode 100644 index 0000000000..2f804f6d04 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/227/expected.json @@ -0,0 +1,42 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "Identifier", + "name": "aa", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 7 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 7 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 7 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/228/actual.js b/packages/babylon/test/fixtures/core/uncategorised/228/actual.js new file mode 100644 index 0000000000..dce48ace34 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/228/actual.js @@ -0,0 +1 @@ +if (morning) goodMorning() \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/228/expected.json b/packages/babylon/test/fixtures/core/uncategorised/228/expected.json new file mode 100644 index 0000000000..f5a97cc959 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/228/expected.json @@ -0,0 +1,84 @@ +{ + "type": "Program", + "body": [ + { + "type": "IfStatement", + "test": { + "type": "Identifier", + "name": "morning", + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 11 + } + } + }, + "consequent": { + "type": "ExpressionStatement", + "expression": { + "type": "CallExpression", + "callee": { + "type": "Identifier", + "name": "goodMorning", + "loc": { + "start": { + "line": 1, + "column": 13 + }, + "end": { + "line": 1, + "column": 24 + } + } + }, + "arguments": [], + "loc": { + "start": { + "line": 1, + "column": 13 + }, + "end": { + "line": 1, + "column": 26 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 13 + }, + "end": { + "line": 1, + "column": 26 + } + } + }, + "alternate": null, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 26 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 26 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/229/actual.js b/packages/babylon/test/fixtures/core/uncategorised/229/actual.js new file mode 100644 index 0000000000..ceb5cecec4 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/229/actual.js @@ -0,0 +1 @@ +if (morning) (function(){}) \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/229/expected.json b/packages/babylon/test/fixtures/core/uncategorised/229/expected.json new file mode 100644 index 0000000000..c98f3067f7 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/229/expected.json @@ -0,0 +1,85 @@ +{ + "type": "Program", + "body": [ + { + "type": "IfStatement", + "test": { + "type": "Identifier", + "name": "morning", + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 11 + } + } + }, + "consequent": { + "type": "ExpressionStatement", + "expression": { + "type": "FunctionExpression", + "id": null, + "params": [], + "body": { + "type": "BlockStatement", + "body": [], + "loc": { + "start": { + "line": 1, + "column": 24 + }, + "end": { + "line": 1, + "column": 26 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 14 + }, + "end": { + "line": 1, + "column": 26 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 13 + }, + "end": { + "line": 1, + "column": 27 + } + } + }, + "alternate": null, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 27 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 27 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/23/actual.js b/packages/babylon/test/fixtures/core/uncategorised/23/actual.js new file mode 100644 index 0000000000..eb6c39e461 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/23/actual.js @@ -0,0 +1 @@ +x = { if: 42 } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/23/expected.json b/packages/babylon/test/fixtures/core/uncategorised/23/expected.json new file mode 100644 index 0000000000..a8b57b2ce0 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/23/expected.json @@ -0,0 +1,103 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "AssignmentExpression", + "operator": "=", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "right": { + "type": "ObjectExpression", + "properties": [ + { + "type": "Property", + "key": { + "type": "Identifier", + "name": "if", + "loc": { + "start": { + "line": 1, + "column": 6 + }, + "end": { + "line": 1, + "column": 8 + } + } + }, + "value": { + "type": "Literal", + "value": 42, + "loc": { + "start": { + "line": 1, + "column": 10 + }, + "end": { + "line": 1, + "column": 12 + } + } + }, + "kind": "init" + } + ], + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 14 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 14 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 14 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 14 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/230/actual.js b/packages/babylon/test/fixtures/core/uncategorised/230/actual.js new file mode 100644 index 0000000000..586d8d8b4f --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/230/actual.js @@ -0,0 +1 @@ +if (morning) var x = 0; \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/230/expected.json b/packages/babylon/test/fixtures/core/uncategorised/230/expected.json new file mode 100644 index 0000000000..8d1a08beb5 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/230/expected.json @@ -0,0 +1,100 @@ +{ + "type": "Program", + "body": [ + { + "type": "IfStatement", + "test": { + "type": "Identifier", + "name": "morning", + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 11 + } + } + }, + "consequent": { + "type": "VariableDeclaration", + "declarations": [ + { + "type": "VariableDeclarator", + "id": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 17 + }, + "end": { + "line": 1, + "column": 18 + } + } + }, + "init": { + "type": "Literal", + "value": 0, + "loc": { + "start": { + "line": 1, + "column": 21 + }, + "end": { + "line": 1, + "column": 22 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 17 + }, + "end": { + "line": 1, + "column": 22 + } + } + } + ], + "kind": "var", + "loc": { + "start": { + "line": 1, + "column": 13 + }, + "end": { + "line": 1, + "column": 23 + } + } + }, + "alternate": null, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 23 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 23 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/231/actual.js b/packages/babylon/test/fixtures/core/uncategorised/231/actual.js new file mode 100644 index 0000000000..2bf0746a5a --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/231/actual.js @@ -0,0 +1 @@ +if (morning) goodMorning(); else goodDay() \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/231/expected.json b/packages/babylon/test/fixtures/core/uncategorised/231/expected.json new file mode 100644 index 0000000000..615a810ed7 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/231/expected.json @@ -0,0 +1,124 @@ +{ + "type": "Program", + "body": [ + { + "type": "IfStatement", + "test": { + "type": "Identifier", + "name": "morning", + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 11 + } + } + }, + "consequent": { + "type": "ExpressionStatement", + "expression": { + "type": "CallExpression", + "callee": { + "type": "Identifier", + "name": "goodMorning", + "loc": { + "start": { + "line": 1, + "column": 13 + }, + "end": { + "line": 1, + "column": 24 + } + } + }, + "arguments": [], + "loc": { + "start": { + "line": 1, + "column": 13 + }, + "end": { + "line": 1, + "column": 26 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 13 + }, + "end": { + "line": 1, + "column": 27 + } + } + }, + "alternate": { + "type": "ExpressionStatement", + "expression": { + "type": "CallExpression", + "callee": { + "type": "Identifier", + "name": "goodDay", + "loc": { + "start": { + "line": 1, + "column": 33 + }, + "end": { + "line": 1, + "column": 40 + } + } + }, + "arguments": [], + "loc": { + "start": { + "line": 1, + "column": 33 + }, + "end": { + "line": 1, + "column": 42 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 33 + }, + "end": { + "line": 1, + "column": 42 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 42 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 42 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/232/actual.js b/packages/babylon/test/fixtures/core/uncategorised/232/actual.js new file mode 100644 index 0000000000..83d1b131bc --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/232/actual.js @@ -0,0 +1 @@ +do keep(); while (true) \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/232/expected.json b/packages/babylon/test/fixtures/core/uncategorised/232/expected.json new file mode 100644 index 0000000000..9c824e5ad5 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/232/expected.json @@ -0,0 +1,83 @@ +{ + "type": "Program", + "body": [ + { + "type": "DoWhileStatement", + "body": { + "type": "ExpressionStatement", + "expression": { + "type": "CallExpression", + "callee": { + "type": "Identifier", + "name": "keep", + "loc": { + "start": { + "line": 1, + "column": 3 + }, + "end": { + "line": 1, + "column": 7 + } + } + }, + "arguments": [], + "loc": { + "start": { + "line": 1, + "column": 3 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 3 + }, + "end": { + "line": 1, + "column": 10 + } + } + }, + "test": { + "type": "Literal", + "value": true, + "loc": { + "start": { + "line": 1, + "column": 18 + }, + "end": { + "line": 1, + "column": 22 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 23 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 23 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/233/actual.js b/packages/babylon/test/fixtures/core/uncategorised/233/actual.js new file mode 100644 index 0000000000..d42e8f5318 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/233/actual.js @@ -0,0 +1 @@ +do keep(); while (true); \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/233/expected.json b/packages/babylon/test/fixtures/core/uncategorised/233/expected.json new file mode 100644 index 0000000000..8aa938b64c --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/233/expected.json @@ -0,0 +1,83 @@ +{ + "type": "Program", + "body": [ + { + "type": "DoWhileStatement", + "body": { + "type": "ExpressionStatement", + "expression": { + "type": "CallExpression", + "callee": { + "type": "Identifier", + "name": "keep", + "loc": { + "start": { + "line": 1, + "column": 3 + }, + "end": { + "line": 1, + "column": 7 + } + } + }, + "arguments": [], + "loc": { + "start": { + "line": 1, + "column": 3 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 3 + }, + "end": { + "line": 1, + "column": 10 + } + } + }, + "test": { + "type": "Literal", + "value": true, + "loc": { + "start": { + "line": 1, + "column": 18 + }, + "end": { + "line": 1, + "column": 22 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 24 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 24 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/234/actual.js b/packages/babylon/test/fixtures/core/uncategorised/234/actual.js new file mode 100644 index 0000000000..45bf48745c --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/234/actual.js @@ -0,0 +1 @@ +do { x++; y--; } while (x < 10) \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/234/expected.json b/packages/babylon/test/fixtures/core/uncategorised/234/expected.json new file mode 100644 index 0000000000..393ddc6671 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/234/expected.json @@ -0,0 +1,169 @@ +{ + "type": "Program", + "body": [ + { + "type": "DoWhileStatement", + "body": { + "type": "BlockStatement", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "UpdateExpression", + "operator": "++", + "prefix": false, + "argument": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 5 + }, + "end": { + "line": 1, + "column": 6 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 5 + }, + "end": { + "line": 1, + "column": 8 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 5 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + { + "type": "ExpressionStatement", + "expression": { + "type": "UpdateExpression", + "operator": "--", + "prefix": false, + "argument": { + "type": "Identifier", + "name": "y", + "loc": { + "start": { + "line": 1, + "column": 10 + }, + "end": { + "line": 1, + "column": 11 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 10 + }, + "end": { + "line": 1, + "column": 13 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 10 + }, + "end": { + "line": 1, + "column": 14 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 3 + }, + "end": { + "line": 1, + "column": 16 + } + } + }, + "test": { + "type": "BinaryExpression", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 24 + }, + "end": { + "line": 1, + "column": 25 + } + } + }, + "operator": "<", + "right": { + "type": "Literal", + "value": 10, + "loc": { + "start": { + "line": 1, + "column": 28 + }, + "end": { + "line": 1, + "column": 30 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 24 + }, + "end": { + "line": 1, + "column": 30 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 31 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 31 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/235/actual.js b/packages/babylon/test/fixtures/core/uncategorised/235/actual.js new file mode 100644 index 0000000000..1599e12f78 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/235/actual.js @@ -0,0 +1 @@ +{ do { } while (false);false } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/235/expected.json b/packages/babylon/test/fixtures/core/uncategorised/235/expected.json new file mode 100644 index 0000000000..aa080755bd --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/235/expected.json @@ -0,0 +1,98 @@ +{ + "type": "Program", + "body": [ + { + "type": "BlockStatement", + "body": [ + { + "type": "DoWhileStatement", + "body": { + "type": "BlockStatement", + "body": [], + "loc": { + "start": { + "line": 1, + "column": 5 + }, + "end": { + "line": 1, + "column": 8 + } + } + }, + "test": { + "type": "Literal", + "value": false, + "loc": { + "start": { + "line": 1, + "column": 16 + }, + "end": { + "line": 1, + "column": 21 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 2 + }, + "end": { + "line": 1, + "column": 23 + } + } + }, + { + "type": "ExpressionStatement", + "expression": { + "type": "Literal", + "value": false, + "loc": { + "start": { + "line": 1, + "column": 23 + }, + "end": { + "line": 1, + "column": 28 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 23 + }, + "end": { + "line": 1, + "column": 28 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 30 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 30 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/236/actual.js b/packages/babylon/test/fixtures/core/uncategorised/236/actual.js new file mode 100644 index 0000000000..bb9e8a5826 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/236/actual.js @@ -0,0 +1 @@ +while (true) doSomething() \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/236/expected.json b/packages/babylon/test/fixtures/core/uncategorised/236/expected.json new file mode 100644 index 0000000000..d781712f49 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/236/expected.json @@ -0,0 +1,83 @@ +{ + "type": "Program", + "body": [ + { + "type": "WhileStatement", + "test": { + "type": "Literal", + "value": true, + "loc": { + "start": { + "line": 1, + "column": 7 + }, + "end": { + "line": 1, + "column": 11 + } + } + }, + "body": { + "type": "ExpressionStatement", + "expression": { + "type": "CallExpression", + "callee": { + "type": "Identifier", + "name": "doSomething", + "loc": { + "start": { + "line": 1, + "column": 13 + }, + "end": { + "line": 1, + "column": 24 + } + } + }, + "arguments": [], + "loc": { + "start": { + "line": 1, + "column": 13 + }, + "end": { + "line": 1, + "column": 26 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 13 + }, + "end": { + "line": 1, + "column": 26 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 26 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 26 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/237/actual.js b/packages/babylon/test/fixtures/core/uncategorised/237/actual.js new file mode 100644 index 0000000000..cec73ff908 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/237/actual.js @@ -0,0 +1 @@ +while (x < 10) { x++; y--; } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/237/expected.json b/packages/babylon/test/fixtures/core/uncategorised/237/expected.json new file mode 100644 index 0000000000..1f220a90d4 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/237/expected.json @@ -0,0 +1,169 @@ +{ + "type": "Program", + "body": [ + { + "type": "WhileStatement", + "test": { + "type": "BinaryExpression", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 7 + }, + "end": { + "line": 1, + "column": 8 + } + } + }, + "operator": "<", + "right": { + "type": "Literal", + "value": 10, + "loc": { + "start": { + "line": 1, + "column": 11 + }, + "end": { + "line": 1, + "column": 13 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 7 + }, + "end": { + "line": 1, + "column": 13 + } + } + }, + "body": { + "type": "BlockStatement", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "UpdateExpression", + "operator": "++", + "prefix": false, + "argument": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 17 + }, + "end": { + "line": 1, + "column": 18 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 17 + }, + "end": { + "line": 1, + "column": 20 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 17 + }, + "end": { + "line": 1, + "column": 21 + } + } + }, + { + "type": "ExpressionStatement", + "expression": { + "type": "UpdateExpression", + "operator": "--", + "prefix": false, + "argument": { + "type": "Identifier", + "name": "y", + "loc": { + "start": { + "line": 1, + "column": 22 + }, + "end": { + "line": 1, + "column": 23 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 22 + }, + "end": { + "line": 1, + "column": 25 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 22 + }, + "end": { + "line": 1, + "column": 26 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 15 + }, + "end": { + "line": 1, + "column": 28 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 28 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 28 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/238/actual.js b/packages/babylon/test/fixtures/core/uncategorised/238/actual.js new file mode 100644 index 0000000000..80c8092f85 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/238/actual.js @@ -0,0 +1 @@ +for(;;); \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/238/expected.json b/packages/babylon/test/fixtures/core/uncategorised/238/expected.json new file mode 100644 index 0000000000..c0ce19c702 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/238/expected.json @@ -0,0 +1,44 @@ +{ + "type": "Program", + "body": [ + { + "type": "ForStatement", + "init": null, + "test": null, + "update": null, + "body": { + "type": "EmptyStatement", + "loc": { + "start": { + "line": 1, + "column": 7 + }, + "end": { + "line": 1, + "column": 8 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 8 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 8 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/239/actual.js b/packages/babylon/test/fixtures/core/uncategorised/239/actual.js new file mode 100644 index 0000000000..a96f450d48 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/239/actual.js @@ -0,0 +1 @@ +for(;;){} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/239/expected.json b/packages/babylon/test/fixtures/core/uncategorised/239/expected.json new file mode 100644 index 0000000000..7ef0c060ee --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/239/expected.json @@ -0,0 +1,45 @@ +{ + "type": "Program", + "body": [ + { + "type": "ForStatement", + "init": null, + "test": null, + "update": null, + "body": { + "type": "BlockStatement", + "body": [], + "loc": { + "start": { + "line": 1, + "column": 7 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/24/actual.js b/packages/babylon/test/fixtures/core/uncategorised/24/actual.js new file mode 100644 index 0000000000..cc13060a89 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/24/actual.js @@ -0,0 +1 @@ +x = { true: 42 } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/24/expected.json b/packages/babylon/test/fixtures/core/uncategorised/24/expected.json new file mode 100644 index 0000000000..506f2ff87b --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/24/expected.json @@ -0,0 +1,103 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "AssignmentExpression", + "operator": "=", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "right": { + "type": "ObjectExpression", + "properties": [ + { + "type": "Property", + "key": { + "type": "Identifier", + "name": "true", + "loc": { + "start": { + "line": 1, + "column": 6 + }, + "end": { + "line": 1, + "column": 10 + } + } + }, + "value": { + "type": "Literal", + "value": 42, + "loc": { + "start": { + "line": 1, + "column": 12 + }, + "end": { + "line": 1, + "column": 14 + } + } + }, + "kind": "init" + } + ], + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 16 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 16 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 16 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 16 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/240/actual.js b/packages/babylon/test/fixtures/core/uncategorised/240/actual.js new file mode 100644 index 0000000000..188f89edc7 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/240/actual.js @@ -0,0 +1 @@ +for(x = 0;;); \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/240/expected.json b/packages/babylon/test/fixtures/core/uncategorised/240/expected.json new file mode 100644 index 0000000000..a028344ff8 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/240/expected.json @@ -0,0 +1,85 @@ +{ + "type": "Program", + "body": [ + { + "type": "ForStatement", + "init": { + "type": "AssignmentExpression", + "operator": "=", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "right": { + "type": "Literal", + "value": 0, + "loc": { + "start": { + "line": 1, + "column": 8 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + "test": null, + "update": null, + "body": { + "type": "EmptyStatement", + "loc": { + "start": { + "line": 1, + "column": 12 + }, + "end": { + "line": 1, + "column": 13 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 13 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 13 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/241/actual.js b/packages/babylon/test/fixtures/core/uncategorised/241/actual.js new file mode 100644 index 0000000000..9ebc154bb7 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/241/actual.js @@ -0,0 +1 @@ +for(var x = 0;;); \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/241/expected.json b/packages/babylon/test/fixtures/core/uncategorised/241/expected.json new file mode 100644 index 0000000000..4ac5605240 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/241/expected.json @@ -0,0 +1,100 @@ +{ + "type": "Program", + "body": [ + { + "type": "ForStatement", + "init": { + "type": "VariableDeclaration", + "declarations": [ + { + "type": "VariableDeclarator", + "id": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 8 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + "init": { + "type": "Literal", + "value": 0, + "loc": { + "start": { + "line": 1, + "column": 12 + }, + "end": { + "line": 1, + "column": 13 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 8 + }, + "end": { + "line": 1, + "column": 13 + } + } + } + ], + "kind": "var", + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 13 + } + } + }, + "test": null, + "update": null, + "body": { + "type": "EmptyStatement", + "loc": { + "start": { + "line": 1, + "column": 16 + }, + "end": { + "line": 1, + "column": 17 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 17 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 17 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/242/actual.js b/packages/babylon/test/fixtures/core/uncategorised/242/actual.js new file mode 100644 index 0000000000..fea9ea13ec --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/242/actual.js @@ -0,0 +1 @@ +for(var x = 0, y = 1;;); \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/242/expected.json b/packages/babylon/test/fixtures/core/uncategorised/242/expected.json new file mode 100644 index 0000000000..18973867d8 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/242/expected.json @@ -0,0 +1,141 @@ +{ + "type": "Program", + "body": [ + { + "type": "ForStatement", + "init": { + "type": "VariableDeclaration", + "declarations": [ + { + "type": "VariableDeclarator", + "id": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 8 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + "init": { + "type": "Literal", + "value": 0, + "loc": { + "start": { + "line": 1, + "column": 12 + }, + "end": { + "line": 1, + "column": 13 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 8 + }, + "end": { + "line": 1, + "column": 13 + } + } + }, + { + "type": "VariableDeclarator", + "id": { + "type": "Identifier", + "name": "y", + "loc": { + "start": { + "line": 1, + "column": 15 + }, + "end": { + "line": 1, + "column": 16 + } + } + }, + "init": { + "type": "Literal", + "value": 1, + "loc": { + "start": { + "line": 1, + "column": 19 + }, + "end": { + "line": 1, + "column": 20 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 15 + }, + "end": { + "line": 1, + "column": 20 + } + } + } + ], + "kind": "var", + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 20 + } + } + }, + "test": null, + "update": null, + "body": { + "type": "EmptyStatement", + "loc": { + "start": { + "line": 1, + "column": 23 + }, + "end": { + "line": 1, + "column": 24 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 24 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 24 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/243/actual.js b/packages/babylon/test/fixtures/core/uncategorised/243/actual.js new file mode 100644 index 0000000000..b9ffae3ec2 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/243/actual.js @@ -0,0 +1 @@ +for(x = 0; x < 42;); \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/243/expected.json b/packages/babylon/test/fixtures/core/uncategorised/243/expected.json new file mode 100644 index 0000000000..50c2bcfa16 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/243/expected.json @@ -0,0 +1,126 @@ +{ + "type": "Program", + "body": [ + { + "type": "ForStatement", + "init": { + "type": "AssignmentExpression", + "operator": "=", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "right": { + "type": "Literal", + "value": 0, + "loc": { + "start": { + "line": 1, + "column": 8 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + "test": { + "type": "BinaryExpression", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 11 + }, + "end": { + "line": 1, + "column": 12 + } + } + }, + "operator": "<", + "right": { + "type": "Literal", + "value": 42, + "loc": { + "start": { + "line": 1, + "column": 15 + }, + "end": { + "line": 1, + "column": 17 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 11 + }, + "end": { + "line": 1, + "column": 17 + } + } + }, + "update": null, + "body": { + "type": "EmptyStatement", + "loc": { + "start": { + "line": 1, + "column": 19 + }, + "end": { + "line": 1, + "column": 20 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 20 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 20 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/244/actual.js b/packages/babylon/test/fixtures/core/uncategorised/244/actual.js new file mode 100644 index 0000000000..3eef5490ba --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/244/actual.js @@ -0,0 +1 @@ +for(x = 0; x < 42; x++); \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/244/expected.json b/packages/babylon/test/fixtures/core/uncategorised/244/expected.json new file mode 100644 index 0000000000..fe82074701 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/244/expected.json @@ -0,0 +1,154 @@ +{ + "type": "Program", + "body": [ + { + "type": "ForStatement", + "init": { + "type": "AssignmentExpression", + "operator": "=", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "right": { + "type": "Literal", + "value": 0, + "loc": { + "start": { + "line": 1, + "column": 8 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + "test": { + "type": "BinaryExpression", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 11 + }, + "end": { + "line": 1, + "column": 12 + } + } + }, + "operator": "<", + "right": { + "type": "Literal", + "value": 42, + "loc": { + "start": { + "line": 1, + "column": 15 + }, + "end": { + "line": 1, + "column": 17 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 11 + }, + "end": { + "line": 1, + "column": 17 + } + } + }, + "update": { + "type": "UpdateExpression", + "operator": "++", + "prefix": false, + "argument": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 19 + }, + "end": { + "line": 1, + "column": 20 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 19 + }, + "end": { + "line": 1, + "column": 22 + } + } + }, + "body": { + "type": "EmptyStatement", + "loc": { + "start": { + "line": 1, + "column": 23 + }, + "end": { + "line": 1, + "column": 24 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 24 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 24 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/245/actual.js b/packages/babylon/test/fixtures/core/uncategorised/245/actual.js new file mode 100644 index 0000000000..228926ee8c --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/245/actual.js @@ -0,0 +1 @@ +for(x = 0; x < 42; x++) process(x); \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/245/expected.json b/packages/babylon/test/fixtures/core/uncategorised/245/expected.json new file mode 100644 index 0000000000..d92d7485b0 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/245/expected.json @@ -0,0 +1,197 @@ +{ + "type": "Program", + "body": [ + { + "type": "ForStatement", + "init": { + "type": "AssignmentExpression", + "operator": "=", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "right": { + "type": "Literal", + "value": 0, + "loc": { + "start": { + "line": 1, + "column": 8 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + "test": { + "type": "BinaryExpression", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 11 + }, + "end": { + "line": 1, + "column": 12 + } + } + }, + "operator": "<", + "right": { + "type": "Literal", + "value": 42, + "loc": { + "start": { + "line": 1, + "column": 15 + }, + "end": { + "line": 1, + "column": 17 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 11 + }, + "end": { + "line": 1, + "column": 17 + } + } + }, + "update": { + "type": "UpdateExpression", + "operator": "++", + "prefix": false, + "argument": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 19 + }, + "end": { + "line": 1, + "column": 20 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 19 + }, + "end": { + "line": 1, + "column": 22 + } + } + }, + "body": { + "type": "ExpressionStatement", + "expression": { + "type": "CallExpression", + "callee": { + "type": "Identifier", + "name": "process", + "loc": { + "start": { + "line": 1, + "column": 24 + }, + "end": { + "line": 1, + "column": 31 + } + } + }, + "arguments": [ + { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 32 + }, + "end": { + "line": 1, + "column": 33 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 24 + }, + "end": { + "line": 1, + "column": 34 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 24 + }, + "end": { + "line": 1, + "column": 35 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 35 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 35 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/246/actual.js b/packages/babylon/test/fixtures/core/uncategorised/246/actual.js new file mode 100644 index 0000000000..1c1271f4db --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/246/actual.js @@ -0,0 +1 @@ +for(x in list) process(x); \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/246/expected.json b/packages/babylon/test/fixtures/core/uncategorised/246/expected.json new file mode 100644 index 0000000000..f04e0c53ec --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/246/expected.json @@ -0,0 +1,112 @@ +{ + "type": "Program", + "body": [ + { + "type": "ForInStatement", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "right": { + "type": "Identifier", + "name": "list", + "loc": { + "start": { + "line": 1, + "column": 9 + }, + "end": { + "line": 1, + "column": 13 + } + } + }, + "body": { + "type": "ExpressionStatement", + "expression": { + "type": "CallExpression", + "callee": { + "type": "Identifier", + "name": "process", + "loc": { + "start": { + "line": 1, + "column": 15 + }, + "end": { + "line": 1, + "column": 22 + } + } + }, + "arguments": [ + { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 23 + }, + "end": { + "line": 1, + "column": 24 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 15 + }, + "end": { + "line": 1, + "column": 25 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 15 + }, + "end": { + "line": 1, + "column": 26 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 26 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 26 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/247/actual.js b/packages/babylon/test/fixtures/core/uncategorised/247/actual.js new file mode 100644 index 0000000000..b75dddef83 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/247/actual.js @@ -0,0 +1 @@ +for (var x in list) process(x); \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/247/expected.json b/packages/babylon/test/fixtures/core/uncategorised/247/expected.json new file mode 100644 index 0000000000..a1f351f933 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/247/expected.json @@ -0,0 +1,142 @@ +{ + "type": "Program", + "body": [ + { + "type": "ForInStatement", + "left": { + "type": "VariableDeclaration", + "declarations": [ + { + "type": "VariableDeclarator", + "id": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 9 + }, + "end": { + "line": 1, + "column": 10 + } + } + }, + "init": null, + "loc": { + "start": { + "line": 1, + "column": 9 + }, + "end": { + "line": 1, + "column": 10 + } + } + } + ], + "kind": "var", + "loc": { + "start": { + "line": 1, + "column": 5 + }, + "end": { + "line": 1, + "column": 10 + } + } + }, + "right": { + "type": "Identifier", + "name": "list", + "loc": { + "start": { + "line": 1, + "column": 14 + }, + "end": { + "line": 1, + "column": 18 + } + } + }, + "body": { + "type": "ExpressionStatement", + "expression": { + "type": "CallExpression", + "callee": { + "type": "Identifier", + "name": "process", + "loc": { + "start": { + "line": 1, + "column": 20 + }, + "end": { + "line": 1, + "column": 27 + } + } + }, + "arguments": [ + { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 28 + }, + "end": { + "line": 1, + "column": 29 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 20 + }, + "end": { + "line": 1, + "column": 30 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 20 + }, + "end": { + "line": 1, + "column": 31 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 31 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 31 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/248/actual.js b/packages/babylon/test/fixtures/core/uncategorised/248/actual.js new file mode 100644 index 0000000000..b06fd22155 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/248/actual.js @@ -0,0 +1 @@ +for (var x = 42 in list) process(x); \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/248/expected.json b/packages/babylon/test/fixtures/core/uncategorised/248/expected.json new file mode 100644 index 0000000000..ad762564fa --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/248/expected.json @@ -0,0 +1,155 @@ +{ + "type": "Program", + "body": [ + { + "type": "ForInStatement", + "left": { + "type": "VariableDeclaration", + "declarations": [ + { + "type": "VariableDeclarator", + "id": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 9 + }, + "end": { + "line": 1, + "column": 10 + } + } + }, + "init": { + "type": "Literal", + "value": 42, + "loc": { + "start": { + "line": 1, + "column": 13 + }, + "end": { + "line": 1, + "column": 15 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 9 + }, + "end": { + "line": 1, + "column": 15 + } + } + } + ], + "kind": "var", + "loc": { + "start": { + "line": 1, + "column": 5 + }, + "end": { + "line": 1, + "column": 15 + } + } + }, + "right": { + "type": "Identifier", + "name": "list", + "loc": { + "start": { + "line": 1, + "column": 19 + }, + "end": { + "line": 1, + "column": 23 + } + } + }, + "body": { + "type": "ExpressionStatement", + "expression": { + "type": "CallExpression", + "callee": { + "type": "Identifier", + "name": "process", + "loc": { + "start": { + "line": 1, + "column": 25 + }, + "end": { + "line": 1, + "column": 32 + } + } + }, + "arguments": [ + { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 33 + }, + "end": { + "line": 1, + "column": 34 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 25 + }, + "end": { + "line": 1, + "column": 35 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 25 + }, + "end": { + "line": 1, + "column": 36 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 36 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 36 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/249/actual.js b/packages/babylon/test/fixtures/core/uncategorised/249/actual.js new file mode 100644 index 0000000000..d42823d7f5 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/249/actual.js @@ -0,0 +1 @@ +for (var i = function() { return 10 in [] } in list) process(x); \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/249/expected.json b/packages/babylon/test/fixtures/core/uncategorised/249/expected.json new file mode 100644 index 0000000000..8b456fad89 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/249/expected.json @@ -0,0 +1,226 @@ +{ + "type": "Program", + "body": [ + { + "type": "ForInStatement", + "left": { + "type": "VariableDeclaration", + "declarations": [ + { + "type": "VariableDeclarator", + "id": { + "type": "Identifier", + "name": "i", + "loc": { + "start": { + "line": 1, + "column": 9 + }, + "end": { + "line": 1, + "column": 10 + } + } + }, + "init": { + "type": "FunctionExpression", + "id": null, + "params": [], + "body": { + "type": "BlockStatement", + "body": [ + { + "type": "ReturnStatement", + "argument": { + "type": "BinaryExpression", + "left": { + "type": "Literal", + "value": 10, + "loc": { + "start": { + "line": 1, + "column": 33 + }, + "end": { + "line": 1, + "column": 35 + } + } + }, + "operator": "in", + "right": { + "type": "ArrayExpression", + "elements": [], + "loc": { + "start": { + "line": 1, + "column": 39 + }, + "end": { + "line": 1, + "column": 41 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 33 + }, + "end": { + "line": 1, + "column": 41 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 26 + }, + "end": { + "line": 1, + "column": 41 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 24 + }, + "end": { + "line": 1, + "column": 43 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 13 + }, + "end": { + "line": 1, + "column": 43 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 9 + }, + "end": { + "line": 1, + "column": 43 + } + } + } + ], + "kind": "var", + "loc": { + "start": { + "line": 1, + "column": 5 + }, + "end": { + "line": 1, + "column": 43 + } + } + }, + "right": { + "type": "Identifier", + "name": "list", + "loc": { + "start": { + "line": 1, + "column": 47 + }, + "end": { + "line": 1, + "column": 51 + } + } + }, + "body": { + "type": "ExpressionStatement", + "expression": { + "type": "CallExpression", + "callee": { + "type": "Identifier", + "name": "process", + "loc": { + "start": { + "line": 1, + "column": 53 + }, + "end": { + "line": 1, + "column": 60 + } + } + }, + "arguments": [ + { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 61 + }, + "end": { + "line": 1, + "column": 62 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 53 + }, + "end": { + "line": 1, + "column": 63 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 53 + }, + "end": { + "line": 1, + "column": 64 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 64 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 64 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/25/actual.js b/packages/babylon/test/fixtures/core/uncategorised/25/actual.js new file mode 100644 index 0000000000..232f4d608a --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/25/actual.js @@ -0,0 +1 @@ +x = { false: 42 } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/25/expected.json b/packages/babylon/test/fixtures/core/uncategorised/25/expected.json new file mode 100644 index 0000000000..ff88a51411 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/25/expected.json @@ -0,0 +1,103 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "AssignmentExpression", + "operator": "=", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "right": { + "type": "ObjectExpression", + "properties": [ + { + "type": "Property", + "key": { + "type": "Identifier", + "name": "false", + "loc": { + "start": { + "line": 1, + "column": 6 + }, + "end": { + "line": 1, + "column": 11 + } + } + }, + "value": { + "type": "Literal", + "value": 42, + "loc": { + "start": { + "line": 1, + "column": 13 + }, + "end": { + "line": 1, + "column": 15 + } + } + }, + "kind": "init" + } + ], + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 17 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 17 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 17 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 17 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/250/actual.js b/packages/babylon/test/fixtures/core/uncategorised/250/actual.js new file mode 100644 index 0000000000..ed1b1e072b --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/250/actual.js @@ -0,0 +1 @@ +while (true) { continue; } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/250/expected.json b/packages/babylon/test/fixtures/core/uncategorised/250/expected.json new file mode 100644 index 0000000000..7efc30fdb0 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/250/expected.json @@ -0,0 +1,71 @@ +{ + "type": "Program", + "body": [ + { + "type": "WhileStatement", + "test": { + "type": "Literal", + "value": true, + "loc": { + "start": { + "line": 1, + "column": 7 + }, + "end": { + "line": 1, + "column": 11 + } + } + }, + "body": { + "type": "BlockStatement", + "body": [ + { + "type": "ContinueStatement", + "label": null, + "loc": { + "start": { + "line": 1, + "column": 15 + }, + "end": { + "line": 1, + "column": 24 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 13 + }, + "end": { + "line": 1, + "column": 26 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 26 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 26 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/251/actual.js b/packages/babylon/test/fixtures/core/uncategorised/251/actual.js new file mode 100644 index 0000000000..703ffaaca9 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/251/actual.js @@ -0,0 +1 @@ +while (true) { continue } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/251/expected.json b/packages/babylon/test/fixtures/core/uncategorised/251/expected.json new file mode 100644 index 0000000000..8d3b0d067f --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/251/expected.json @@ -0,0 +1,71 @@ +{ + "type": "Program", + "body": [ + { + "type": "WhileStatement", + "test": { + "type": "Literal", + "value": true, + "loc": { + "start": { + "line": 1, + "column": 7 + }, + "end": { + "line": 1, + "column": 11 + } + } + }, + "body": { + "type": "BlockStatement", + "body": [ + { + "type": "ContinueStatement", + "label": null, + "loc": { + "start": { + "line": 1, + "column": 15 + }, + "end": { + "line": 1, + "column": 23 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 13 + }, + "end": { + "line": 1, + "column": 25 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 25 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 25 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/252/actual.js b/packages/babylon/test/fixtures/core/uncategorised/252/actual.js new file mode 100644 index 0000000000..acbaf677c7 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/252/actual.js @@ -0,0 +1 @@ +done: while (true) { continue done } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/252/expected.json b/packages/babylon/test/fixtures/core/uncategorised/252/expected.json new file mode 100644 index 0000000000..73a0589b16 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/252/expected.json @@ -0,0 +1,111 @@ +{ + "type": "Program", + "body": [ + { + "type": "LabeledStatement", + "body": { + "type": "WhileStatement", + "test": { + "type": "Literal", + "value": true, + "loc": { + "start": { + "line": 1, + "column": 13 + }, + "end": { + "line": 1, + "column": 17 + } + } + }, + "body": { + "type": "BlockStatement", + "body": [ + { + "type": "ContinueStatement", + "label": { + "type": "Identifier", + "name": "done", + "loc": { + "start": { + "line": 1, + "column": 30 + }, + "end": { + "line": 1, + "column": 34 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 21 + }, + "end": { + "line": 1, + "column": 34 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 19 + }, + "end": { + "line": 1, + "column": 36 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 6 + }, + "end": { + "line": 1, + "column": 36 + } + } + }, + "label": { + "type": "Identifier", + "name": "done", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 4 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 36 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 36 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/253/actual.js b/packages/babylon/test/fixtures/core/uncategorised/253/actual.js new file mode 100644 index 0000000000..57a848bdb5 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/253/actual.js @@ -0,0 +1 @@ +done: while (true) { continue done; } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/253/expected.json b/packages/babylon/test/fixtures/core/uncategorised/253/expected.json new file mode 100644 index 0000000000..e83212253b --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/253/expected.json @@ -0,0 +1,111 @@ +{ + "type": "Program", + "body": [ + { + "type": "LabeledStatement", + "body": { + "type": "WhileStatement", + "test": { + "type": "Literal", + "value": true, + "loc": { + "start": { + "line": 1, + "column": 13 + }, + "end": { + "line": 1, + "column": 17 + } + } + }, + "body": { + "type": "BlockStatement", + "body": [ + { + "type": "ContinueStatement", + "label": { + "type": "Identifier", + "name": "done", + "loc": { + "start": { + "line": 1, + "column": 30 + }, + "end": { + "line": 1, + "column": 34 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 21 + }, + "end": { + "line": 1, + "column": 35 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 19 + }, + "end": { + "line": 1, + "column": 37 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 6 + }, + "end": { + "line": 1, + "column": 37 + } + } + }, + "label": { + "type": "Identifier", + "name": "done", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 4 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 37 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 37 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/254/actual.js b/packages/babylon/test/fixtures/core/uncategorised/254/actual.js new file mode 100644 index 0000000000..9fbb13a214 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/254/actual.js @@ -0,0 +1 @@ +while (true) { break } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/254/expected.json b/packages/babylon/test/fixtures/core/uncategorised/254/expected.json new file mode 100644 index 0000000000..eb738ab13b --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/254/expected.json @@ -0,0 +1,71 @@ +{ + "type": "Program", + "body": [ + { + "type": "WhileStatement", + "test": { + "type": "Literal", + "value": true, + "loc": { + "start": { + "line": 1, + "column": 7 + }, + "end": { + "line": 1, + "column": 11 + } + } + }, + "body": { + "type": "BlockStatement", + "body": [ + { + "type": "BreakStatement", + "label": null, + "loc": { + "start": { + "line": 1, + "column": 15 + }, + "end": { + "line": 1, + "column": 20 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 13 + }, + "end": { + "line": 1, + "column": 22 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 22 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 22 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/255/actual.js b/packages/babylon/test/fixtures/core/uncategorised/255/actual.js new file mode 100644 index 0000000000..89388f75c4 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/255/actual.js @@ -0,0 +1 @@ +done: while (true) { break done } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/255/expected.json b/packages/babylon/test/fixtures/core/uncategorised/255/expected.json new file mode 100644 index 0000000000..d98d298853 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/255/expected.json @@ -0,0 +1,111 @@ +{ + "type": "Program", + "body": [ + { + "type": "LabeledStatement", + "body": { + "type": "WhileStatement", + "test": { + "type": "Literal", + "value": true, + "loc": { + "start": { + "line": 1, + "column": 13 + }, + "end": { + "line": 1, + "column": 17 + } + } + }, + "body": { + "type": "BlockStatement", + "body": [ + { + "type": "BreakStatement", + "label": { + "type": "Identifier", + "name": "done", + "loc": { + "start": { + "line": 1, + "column": 27 + }, + "end": { + "line": 1, + "column": 31 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 21 + }, + "end": { + "line": 1, + "column": 31 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 19 + }, + "end": { + "line": 1, + "column": 33 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 6 + }, + "end": { + "line": 1, + "column": 33 + } + } + }, + "label": { + "type": "Identifier", + "name": "done", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 4 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 33 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 33 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/256/actual.js b/packages/babylon/test/fixtures/core/uncategorised/256/actual.js new file mode 100644 index 0000000000..f8f5f5f11a --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/256/actual.js @@ -0,0 +1 @@ +done: while (true) { break done; } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/256/expected.json b/packages/babylon/test/fixtures/core/uncategorised/256/expected.json new file mode 100644 index 0000000000..f1d77d0bef --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/256/expected.json @@ -0,0 +1,111 @@ +{ + "type": "Program", + "body": [ + { + "type": "LabeledStatement", + "body": { + "type": "WhileStatement", + "test": { + "type": "Literal", + "value": true, + "loc": { + "start": { + "line": 1, + "column": 13 + }, + "end": { + "line": 1, + "column": 17 + } + } + }, + "body": { + "type": "BlockStatement", + "body": [ + { + "type": "BreakStatement", + "label": { + "type": "Identifier", + "name": "done", + "loc": { + "start": { + "line": 1, + "column": 27 + }, + "end": { + "line": 1, + "column": 31 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 21 + }, + "end": { + "line": 1, + "column": 32 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 19 + }, + "end": { + "line": 1, + "column": 34 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 6 + }, + "end": { + "line": 1, + "column": 34 + } + } + }, + "label": { + "type": "Identifier", + "name": "done", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 4 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 34 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 34 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/257/actual.js b/packages/babylon/test/fixtures/core/uncategorised/257/actual.js new file mode 100644 index 0000000000..3f7820f4aa --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/257/actual.js @@ -0,0 +1 @@ +target1: target2: while (true) { continue target1; } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/257/expected.json b/packages/babylon/test/fixtures/core/uncategorised/257/expected.json new file mode 100644 index 0000000000..9e26dfeeb6 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/257/expected.json @@ -0,0 +1 @@ +{} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/258/actual.js b/packages/babylon/test/fixtures/core/uncategorised/258/actual.js new file mode 100644 index 0000000000..20860af8a4 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/258/actual.js @@ -0,0 +1 @@ +target1: target2: target3: while (true) { continue target1; } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/258/expected.json b/packages/babylon/test/fixtures/core/uncategorised/258/expected.json new file mode 100644 index 0000000000..9e26dfeeb6 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/258/expected.json @@ -0,0 +1 @@ +{} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/259/actual.js b/packages/babylon/test/fixtures/core/uncategorised/259/actual.js new file mode 100644 index 0000000000..7619e9fc5e --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/259/actual.js @@ -0,0 +1 @@ +(function(){ return }) \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/259/expected.json b/packages/babylon/test/fixtures/core/uncategorised/259/expected.json new file mode 100644 index 0000000000..543fa99419 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/259/expected.json @@ -0,0 +1,72 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "FunctionExpression", + "id": null, + "params": [], + "body": { + "type": "BlockStatement", + "body": [ + { + "type": "ReturnStatement", + "argument": null, + "loc": { + "start": { + "line": 1, + "column": 13 + }, + "end": { + "line": 1, + "column": 19 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 11 + }, + "end": { + "line": 1, + "column": 21 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 1 + }, + "end": { + "line": 1, + "column": 21 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 22 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 22 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/26/actual.js b/packages/babylon/test/fixtures/core/uncategorised/26/actual.js new file mode 100644 index 0000000000..73fedb55da --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/26/actual.js @@ -0,0 +1 @@ +x = { null: 42 } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/26/expected.json b/packages/babylon/test/fixtures/core/uncategorised/26/expected.json new file mode 100644 index 0000000000..2e26a73fc9 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/26/expected.json @@ -0,0 +1,103 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "AssignmentExpression", + "operator": "=", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "right": { + "type": "ObjectExpression", + "properties": [ + { + "type": "Property", + "key": { + "type": "Identifier", + "name": "null", + "loc": { + "start": { + "line": 1, + "column": 6 + }, + "end": { + "line": 1, + "column": 10 + } + } + }, + "value": { + "type": "Literal", + "value": 42, + "loc": { + "start": { + "line": 1, + "column": 12 + }, + "end": { + "line": 1, + "column": 14 + } + } + }, + "kind": "init" + } + ], + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 16 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 16 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 16 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 16 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/260/actual.js b/packages/babylon/test/fixtures/core/uncategorised/260/actual.js new file mode 100644 index 0000000000..1a2219d708 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/260/actual.js @@ -0,0 +1 @@ +(function(){ return; }) \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/260/expected.json b/packages/babylon/test/fixtures/core/uncategorised/260/expected.json new file mode 100644 index 0000000000..3ee4467138 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/260/expected.json @@ -0,0 +1,72 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "FunctionExpression", + "id": null, + "params": [], + "body": { + "type": "BlockStatement", + "body": [ + { + "type": "ReturnStatement", + "argument": null, + "loc": { + "start": { + "line": 1, + "column": 13 + }, + "end": { + "line": 1, + "column": 20 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 11 + }, + "end": { + "line": 1, + "column": 22 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 1 + }, + "end": { + "line": 1, + "column": 22 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 23 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 23 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/261/actual.js b/packages/babylon/test/fixtures/core/uncategorised/261/actual.js new file mode 100644 index 0000000000..2e2bb6f335 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/261/actual.js @@ -0,0 +1 @@ +(function(){ return x; }) \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/261/expected.json b/packages/babylon/test/fixtures/core/uncategorised/261/expected.json new file mode 100644 index 0000000000..baa6406ea3 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/261/expected.json @@ -0,0 +1,85 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "FunctionExpression", + "id": null, + "params": [], + "body": { + "type": "BlockStatement", + "body": [ + { + "type": "ReturnStatement", + "argument": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 20 + }, + "end": { + "line": 1, + "column": 21 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 13 + }, + "end": { + "line": 1, + "column": 22 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 11 + }, + "end": { + "line": 1, + "column": 24 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 1 + }, + "end": { + "line": 1, + "column": 24 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 25 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 25 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/262/actual.js b/packages/babylon/test/fixtures/core/uncategorised/262/actual.js new file mode 100644 index 0000000000..0deb010a90 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/262/actual.js @@ -0,0 +1 @@ +(function(){ return x * y }) \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/262/expected.json b/packages/babylon/test/fixtures/core/uncategorised/262/expected.json new file mode 100644 index 0000000000..c2fb7b8e0f --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/262/expected.json @@ -0,0 +1,113 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "FunctionExpression", + "id": null, + "params": [], + "body": { + "type": "BlockStatement", + "body": [ + { + "type": "ReturnStatement", + "argument": { + "type": "BinaryExpression", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 20 + }, + "end": { + "line": 1, + "column": 21 + } + } + }, + "operator": "*", + "right": { + "type": "Identifier", + "name": "y", + "loc": { + "start": { + "line": 1, + "column": 24 + }, + "end": { + "line": 1, + "column": 25 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 20 + }, + "end": { + "line": 1, + "column": 25 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 13 + }, + "end": { + "line": 1, + "column": 25 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 11 + }, + "end": { + "line": 1, + "column": 27 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 1 + }, + "end": { + "line": 1, + "column": 27 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 28 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 28 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/263/actual.js b/packages/babylon/test/fixtures/core/uncategorised/263/actual.js new file mode 100644 index 0000000000..5cedbbfaec --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/263/actual.js @@ -0,0 +1 @@ +'use\x20strict'; with (x) foo = bar; \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/263/expected.json b/packages/babylon/test/fixtures/core/uncategorised/263/expected.json new file mode 100644 index 0000000000..9e26dfeeb6 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/263/expected.json @@ -0,0 +1 @@ +{} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/264/actual.js b/packages/babylon/test/fixtures/core/uncategorised/264/actual.js new file mode 100644 index 0000000000..89c3b99025 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/264/actual.js @@ -0,0 +1 @@ +"use\x20strict"; with (x) foo = bar; \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/264/expected.json b/packages/babylon/test/fixtures/core/uncategorised/264/expected.json new file mode 100644 index 0000000000..9e26dfeeb6 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/264/expected.json @@ -0,0 +1 @@ +{} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/265/actual.js b/packages/babylon/test/fixtures/core/uncategorised/265/actual.js new file mode 100644 index 0000000000..aaa12b6a83 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/265/actual.js @@ -0,0 +1 @@ +with (x) foo = bar \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/265/expected.json b/packages/babylon/test/fixtures/core/uncategorised/265/expected.json new file mode 100644 index 0000000000..72d3487e27 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/265/expected.json @@ -0,0 +1,97 @@ +{ + "type": "Program", + "body": [ + { + "type": "WithStatement", + "object": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 6 + }, + "end": { + "line": 1, + "column": 7 + } + } + }, + "body": { + "type": "ExpressionStatement", + "expression": { + "type": "AssignmentExpression", + "operator": "=", + "left": { + "type": "Identifier", + "name": "foo", + "loc": { + "start": { + "line": 1, + "column": 9 + }, + "end": { + "line": 1, + "column": 12 + } + } + }, + "right": { + "type": "Identifier", + "name": "bar", + "loc": { + "start": { + "line": 1, + "column": 15 + }, + "end": { + "line": 1, + "column": 18 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 9 + }, + "end": { + "line": 1, + "column": 18 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 9 + }, + "end": { + "line": 1, + "column": 18 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 18 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 18 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/266/actual.js b/packages/babylon/test/fixtures/core/uncategorised/266/actual.js new file mode 100644 index 0000000000..56807e9dd1 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/266/actual.js @@ -0,0 +1 @@ +with (x) foo = bar; \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/266/expected.json b/packages/babylon/test/fixtures/core/uncategorised/266/expected.json new file mode 100644 index 0000000000..fe101ff2ea --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/266/expected.json @@ -0,0 +1,97 @@ +{ + "type": "Program", + "body": [ + { + "type": "WithStatement", + "object": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 6 + }, + "end": { + "line": 1, + "column": 7 + } + } + }, + "body": { + "type": "ExpressionStatement", + "expression": { + "type": "AssignmentExpression", + "operator": "=", + "left": { + "type": "Identifier", + "name": "foo", + "loc": { + "start": { + "line": 1, + "column": 9 + }, + "end": { + "line": 1, + "column": 12 + } + } + }, + "right": { + "type": "Identifier", + "name": "bar", + "loc": { + "start": { + "line": 1, + "column": 15 + }, + "end": { + "line": 1, + "column": 18 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 9 + }, + "end": { + "line": 1, + "column": 18 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 9 + }, + "end": { + "line": 1, + "column": 19 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 19 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 19 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/267/actual.js b/packages/babylon/test/fixtures/core/uncategorised/267/actual.js new file mode 100644 index 0000000000..4faa234590 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/267/actual.js @@ -0,0 +1 @@ +with (x) { foo = bar } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/267/expected.json b/packages/babylon/test/fixtures/core/uncategorised/267/expected.json new file mode 100644 index 0000000000..8fece2fe47 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/267/expected.json @@ -0,0 +1,112 @@ +{ + "type": "Program", + "body": [ + { + "type": "WithStatement", + "object": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 6 + }, + "end": { + "line": 1, + "column": 7 + } + } + }, + "body": { + "type": "BlockStatement", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "AssignmentExpression", + "operator": "=", + "left": { + "type": "Identifier", + "name": "foo", + "loc": { + "start": { + "line": 1, + "column": 11 + }, + "end": { + "line": 1, + "column": 14 + } + } + }, + "right": { + "type": "Identifier", + "name": "bar", + "loc": { + "start": { + "line": 1, + "column": 17 + }, + "end": { + "line": 1, + "column": 20 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 11 + }, + "end": { + "line": 1, + "column": 20 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 11 + }, + "end": { + "line": 1, + "column": 20 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 9 + }, + "end": { + "line": 1, + "column": 22 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 22 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 22 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/268/actual.js b/packages/babylon/test/fixtures/core/uncategorised/268/actual.js new file mode 100644 index 0000000000..d571ea8113 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/268/actual.js @@ -0,0 +1 @@ +switch (x) {} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/268/expected.json b/packages/babylon/test/fixtures/core/uncategorised/268/expected.json new file mode 100644 index 0000000000..55dbb7d6f6 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/268/expected.json @@ -0,0 +1,43 @@ +{ + "type": "Program", + "body": [ + { + "type": "SwitchStatement", + "discriminant": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 8 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + "cases": [], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 13 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 13 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/269/actual.js b/packages/babylon/test/fixtures/core/uncategorised/269/actual.js new file mode 100644 index 0000000000..fd9a2cb6c5 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/269/actual.js @@ -0,0 +1 @@ +switch (answer) { case 42: hi(); break; } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/269/expected.json b/packages/babylon/test/fixtures/core/uncategorised/269/expected.json new file mode 100644 index 0000000000..9f9b759893 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/269/expected.json @@ -0,0 +1,128 @@ +{ + "type": "Program", + "body": [ + { + "type": "SwitchStatement", + "discriminant": { + "type": "Identifier", + "name": "answer", + "loc": { + "start": { + "line": 1, + "column": 8 + }, + "end": { + "line": 1, + "column": 14 + } + } + }, + "cases": [ + { + "type": "SwitchCase", + "consequent": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "CallExpression", + "callee": { + "type": "Identifier", + "name": "hi", + "loc": { + "start": { + "line": 1, + "column": 27 + }, + "end": { + "line": 1, + "column": 29 + } + } + }, + "arguments": [], + "loc": { + "start": { + "line": 1, + "column": 27 + }, + "end": { + "line": 1, + "column": 31 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 27 + }, + "end": { + "line": 1, + "column": 32 + } + } + }, + { + "type": "BreakStatement", + "label": null, + "loc": { + "start": { + "line": 1, + "column": 33 + }, + "end": { + "line": 1, + "column": 39 + } + } + } + ], + "test": { + "type": "Literal", + "value": 42, + "loc": { + "start": { + "line": 1, + "column": 23 + }, + "end": { + "line": 1, + "column": 25 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 18 + }, + "end": { + "line": 1, + "column": 39 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 41 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 41 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/27/actual.js b/packages/babylon/test/fixtures/core/uncategorised/27/actual.js new file mode 100644 index 0000000000..080fc0eb69 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/27/actual.js @@ -0,0 +1 @@ +x = { "answer": 42 } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/27/expected.json b/packages/babylon/test/fixtures/core/uncategorised/27/expected.json new file mode 100644 index 0000000000..7f87a9b615 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/27/expected.json @@ -0,0 +1,103 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "AssignmentExpression", + "operator": "=", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "right": { + "type": "ObjectExpression", + "properties": [ + { + "type": "Property", + "key": { + "type": "Literal", + "value": "answer", + "loc": { + "start": { + "line": 1, + "column": 6 + }, + "end": { + "line": 1, + "column": 14 + } + } + }, + "value": { + "type": "Literal", + "value": 42, + "loc": { + "start": { + "line": 1, + "column": 16 + }, + "end": { + "line": 1, + "column": 18 + } + } + }, + "kind": "init" + } + ], + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 20 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 20 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 20 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 20 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/270/actual.js b/packages/babylon/test/fixtures/core/uncategorised/270/actual.js new file mode 100644 index 0000000000..a945c132d5 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/270/actual.js @@ -0,0 +1 @@ +switch (answer) { case 42: hi(); break; default: break } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/270/expected.json b/packages/babylon/test/fixtures/core/uncategorised/270/expected.json new file mode 100644 index 0000000000..0422bd04db --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/270/expected.json @@ -0,0 +1,158 @@ +{ + "type": "Program", + "body": [ + { + "type": "SwitchStatement", + "discriminant": { + "type": "Identifier", + "name": "answer", + "loc": { + "start": { + "line": 1, + "column": 8 + }, + "end": { + "line": 1, + "column": 14 + } + } + }, + "cases": [ + { + "type": "SwitchCase", + "consequent": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "CallExpression", + "callee": { + "type": "Identifier", + "name": "hi", + "loc": { + "start": { + "line": 1, + "column": 27 + }, + "end": { + "line": 1, + "column": 29 + } + } + }, + "arguments": [], + "loc": { + "start": { + "line": 1, + "column": 27 + }, + "end": { + "line": 1, + "column": 31 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 27 + }, + "end": { + "line": 1, + "column": 32 + } + } + }, + { + "type": "BreakStatement", + "label": null, + "loc": { + "start": { + "line": 1, + "column": 33 + }, + "end": { + "line": 1, + "column": 39 + } + } + } + ], + "test": { + "type": "Literal", + "value": 42, + "loc": { + "start": { + "line": 1, + "column": 23 + }, + "end": { + "line": 1, + "column": 25 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 18 + }, + "end": { + "line": 1, + "column": 39 + } + } + }, + { + "type": "SwitchCase", + "consequent": [ + { + "type": "BreakStatement", + "label": null, + "loc": { + "start": { + "line": 1, + "column": 49 + }, + "end": { + "line": 1, + "column": 54 + } + } + } + ], + "test": null, + "loc": { + "start": { + "line": 1, + "column": 40 + }, + "end": { + "line": 1, + "column": 54 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 56 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 56 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/271/actual.js b/packages/babylon/test/fixtures/core/uncategorised/271/actual.js new file mode 100644 index 0000000000..818f601164 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/271/actual.js @@ -0,0 +1 @@ +start: for (;;) break start \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/271/expected.json b/packages/babylon/test/fixtures/core/uncategorised/271/expected.json new file mode 100644 index 0000000000..8e8bbb28f1 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/271/expected.json @@ -0,0 +1,85 @@ +{ + "type": "Program", + "body": [ + { + "type": "LabeledStatement", + "body": { + "type": "ForStatement", + "init": null, + "test": null, + "update": null, + "body": { + "type": "BreakStatement", + "label": { + "type": "Identifier", + "name": "start", + "loc": { + "start": { + "line": 1, + "column": 22 + }, + "end": { + "line": 1, + "column": 27 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 16 + }, + "end": { + "line": 1, + "column": 27 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 7 + }, + "end": { + "line": 1, + "column": 27 + } + } + }, + "label": { + "type": "Identifier", + "name": "start", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 27 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 27 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/272/actual.js b/packages/babylon/test/fixtures/core/uncategorised/272/actual.js new file mode 100644 index 0000000000..d7a526be49 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/272/actual.js @@ -0,0 +1 @@ +start: while (true) break start \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/272/expected.json b/packages/babylon/test/fixtures/core/uncategorised/272/expected.json new file mode 100644 index 0000000000..d21a759a3c --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/272/expected.json @@ -0,0 +1,96 @@ +{ + "type": "Program", + "body": [ + { + "type": "LabeledStatement", + "body": { + "type": "WhileStatement", + "test": { + "type": "Literal", + "value": true, + "loc": { + "start": { + "line": 1, + "column": 14 + }, + "end": { + "line": 1, + "column": 18 + } + } + }, + "body": { + "type": "BreakStatement", + "label": { + "type": "Identifier", + "name": "start", + "loc": { + "start": { + "line": 1, + "column": 26 + }, + "end": { + "line": 1, + "column": 31 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 20 + }, + "end": { + "line": 1, + "column": 31 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 7 + }, + "end": { + "line": 1, + "column": 31 + } + } + }, + "label": { + "type": "Identifier", + "name": "start", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 31 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 31 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/273/actual.js b/packages/babylon/test/fixtures/core/uncategorised/273/actual.js new file mode 100644 index 0000000000..073d0271ea --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/273/actual.js @@ -0,0 +1 @@ +throw x; \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/273/expected.json b/packages/babylon/test/fixtures/core/uncategorised/273/expected.json new file mode 100644 index 0000000000..6f0e51bccb --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/273/expected.json @@ -0,0 +1,42 @@ +{ + "type": "Program", + "body": [ + { + "type": "ThrowStatement", + "argument": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 6 + }, + "end": { + "line": 1, + "column": 7 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 8 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 8 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/274/actual.js b/packages/babylon/test/fixtures/core/uncategorised/274/actual.js new file mode 100644 index 0000000000..4593b61961 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/274/actual.js @@ -0,0 +1 @@ +throw x * y \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/274/expected.json b/packages/babylon/test/fixtures/core/uncategorised/274/expected.json new file mode 100644 index 0000000000..60755a161a --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/274/expected.json @@ -0,0 +1,70 @@ +{ + "type": "Program", + "body": [ + { + "type": "ThrowStatement", + "argument": { + "type": "BinaryExpression", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 6 + }, + "end": { + "line": 1, + "column": 7 + } + } + }, + "operator": "*", + "right": { + "type": "Identifier", + "name": "y", + "loc": { + "start": { + "line": 1, + "column": 10 + }, + "end": { + "line": 1, + "column": 11 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 6 + }, + "end": { + "line": 1, + "column": 11 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 11 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 11 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/275/actual.js b/packages/babylon/test/fixtures/core/uncategorised/275/actual.js new file mode 100644 index 0000000000..e529bfabae --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/275/actual.js @@ -0,0 +1 @@ +throw { message: "Error" } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/275/expected.json b/packages/babylon/test/fixtures/core/uncategorised/275/expected.json new file mode 100644 index 0000000000..c3151851c8 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/275/expected.json @@ -0,0 +1,75 @@ +{ + "type": "Program", + "body": [ + { + "type": "ThrowStatement", + "argument": { + "type": "ObjectExpression", + "properties": [ + { + "type": "Property", + "key": { + "type": "Identifier", + "name": "message", + "loc": { + "start": { + "line": 1, + "column": 8 + }, + "end": { + "line": 1, + "column": 15 + } + } + }, + "value": { + "type": "Literal", + "value": "Error", + "loc": { + "start": { + "line": 1, + "column": 17 + }, + "end": { + "line": 1, + "column": 24 + } + } + }, + "kind": "init" + } + ], + "loc": { + "start": { + "line": 1, + "column": 6 + }, + "end": { + "line": 1, + "column": 26 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 26 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 26 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/276/actual.js b/packages/babylon/test/fixtures/core/uncategorised/276/actual.js new file mode 100644 index 0000000000..73f247b7af --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/276/actual.js @@ -0,0 +1 @@ +try { } catch (e) { } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/276/expected.json b/packages/babylon/test/fixtures/core/uncategorised/276/expected.json new file mode 100644 index 0000000000..08a09f9b8d --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/276/expected.json @@ -0,0 +1,84 @@ +{ + "type": "Program", + "body": [ + { + "type": "TryStatement", + "block": { + "type": "BlockStatement", + "body": [], + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 7 + } + } + }, + "handler": { + "type": "CatchClause", + "param": { + "type": "Identifier", + "name": "e", + "loc": { + "start": { + "line": 1, + "column": 15 + }, + "end": { + "line": 1, + "column": 16 + } + } + }, + "body": { + "type": "BlockStatement", + "body": [], + "loc": { + "start": { + "line": 1, + "column": 18 + }, + "end": { + "line": 1, + "column": 21 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 8 + }, + "end": { + "line": 1, + "column": 21 + } + } + }, + "finalizer": null, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 21 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 21 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/277/actual.js b/packages/babylon/test/fixtures/core/uncategorised/277/actual.js new file mode 100644 index 0000000000..9f28761f40 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/277/actual.js @@ -0,0 +1 @@ +try { } catch (eval) { } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/277/expected.json b/packages/babylon/test/fixtures/core/uncategorised/277/expected.json new file mode 100644 index 0000000000..b7306ad5c3 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/277/expected.json @@ -0,0 +1,84 @@ +{ + "type": "Program", + "body": [ + { + "type": "TryStatement", + "block": { + "type": "BlockStatement", + "body": [], + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 7 + } + } + }, + "handler": { + "type": "CatchClause", + "param": { + "type": "Identifier", + "name": "eval", + "loc": { + "start": { + "line": 1, + "column": 15 + }, + "end": { + "line": 1, + "column": 19 + } + } + }, + "body": { + "type": "BlockStatement", + "body": [], + "loc": { + "start": { + "line": 1, + "column": 21 + }, + "end": { + "line": 1, + "column": 24 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 8 + }, + "end": { + "line": 1, + "column": 24 + } + } + }, + "finalizer": null, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 24 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 24 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/278/actual.js b/packages/babylon/test/fixtures/core/uncategorised/278/actual.js new file mode 100644 index 0000000000..4a6beaf122 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/278/actual.js @@ -0,0 +1 @@ +try { } catch (arguments) { } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/278/expected.json b/packages/babylon/test/fixtures/core/uncategorised/278/expected.json new file mode 100644 index 0000000000..1615f88a80 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/278/expected.json @@ -0,0 +1,84 @@ +{ + "type": "Program", + "body": [ + { + "type": "TryStatement", + "block": { + "type": "BlockStatement", + "body": [], + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 7 + } + } + }, + "handler": { + "type": "CatchClause", + "param": { + "type": "Identifier", + "name": "arguments", + "loc": { + "start": { + "line": 1, + "column": 15 + }, + "end": { + "line": 1, + "column": 24 + } + } + }, + "body": { + "type": "BlockStatement", + "body": [], + "loc": { + "start": { + "line": 1, + "column": 26 + }, + "end": { + "line": 1, + "column": 29 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 8 + }, + "end": { + "line": 1, + "column": 29 + } + } + }, + "finalizer": null, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 29 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 29 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/279/actual.js b/packages/babylon/test/fixtures/core/uncategorised/279/actual.js new file mode 100644 index 0000000000..f8e09cdea0 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/279/actual.js @@ -0,0 +1 @@ +try { } catch (e) { say(e) } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/279/expected.json b/packages/babylon/test/fixtures/core/uncategorised/279/expected.json new file mode 100644 index 0000000000..e5cb93d599 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/279/expected.json @@ -0,0 +1,141 @@ +{ + "type": "Program", + "body": [ + { + "type": "TryStatement", + "block": { + "type": "BlockStatement", + "body": [], + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 7 + } + } + }, + "handler": { + "type": "CatchClause", + "param": { + "type": "Identifier", + "name": "e", + "loc": { + "start": { + "line": 1, + "column": 15 + }, + "end": { + "line": 1, + "column": 16 + } + } + }, + "body": { + "type": "BlockStatement", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "CallExpression", + "callee": { + "type": "Identifier", + "name": "say", + "loc": { + "start": { + "line": 1, + "column": 20 + }, + "end": { + "line": 1, + "column": 23 + } + } + }, + "arguments": [ + { + "type": "Identifier", + "name": "e", + "loc": { + "start": { + "line": 1, + "column": 24 + }, + "end": { + "line": 1, + "column": 25 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 20 + }, + "end": { + "line": 1, + "column": 26 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 20 + }, + "end": { + "line": 1, + "column": 26 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 18 + }, + "end": { + "line": 1, + "column": 28 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 8 + }, + "end": { + "line": 1, + "column": 28 + } + } + }, + "finalizer": null, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 28 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 28 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/28/actual.js b/packages/babylon/test/fixtures/core/uncategorised/28/actual.js new file mode 100644 index 0000000000..27dc99aa13 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/28/actual.js @@ -0,0 +1 @@ +x = { x: 1, x: 2 } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/28/expected.json b/packages/babylon/test/fixtures/core/uncategorised/28/expected.json new file mode 100644 index 0000000000..26d314d52e --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/28/expected.json @@ -0,0 +1,135 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "AssignmentExpression", + "operator": "=", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "right": { + "type": "ObjectExpression", + "properties": [ + { + "type": "Property", + "key": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 6 + }, + "end": { + "line": 1, + "column": 7 + } + } + }, + "value": { + "type": "Literal", + "value": 1, + "loc": { + "start": { + "line": 1, + "column": 9 + }, + "end": { + "line": 1, + "column": 10 + } + } + }, + "kind": "init" + }, + { + "type": "Property", + "key": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 12 + }, + "end": { + "line": 1, + "column": 13 + } + } + }, + "value": { + "type": "Literal", + "value": 2, + "loc": { + "start": { + "line": 1, + "column": 15 + }, + "end": { + "line": 1, + "column": 16 + } + } + }, + "kind": "init" + } + ], + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 18 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 18 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 18 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 18 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/280/actual.js b/packages/babylon/test/fixtures/core/uncategorised/280/actual.js new file mode 100644 index 0000000000..08ff3b55f0 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/280/actual.js @@ -0,0 +1 @@ +try { } finally { cleanup(stuff) } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/280/expected.json b/packages/babylon/test/fixtures/core/uncategorised/280/expected.json new file mode 100644 index 0000000000..edd04bab82 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/280/expected.json @@ -0,0 +1,114 @@ +{ + "type": "Program", + "body": [ + { + "type": "TryStatement", + "block": { + "type": "BlockStatement", + "body": [], + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 7 + } + } + }, + "handler": null, + "finalizer": { + "type": "BlockStatement", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "CallExpression", + "callee": { + "type": "Identifier", + "name": "cleanup", + "loc": { + "start": { + "line": 1, + "column": 18 + }, + "end": { + "line": 1, + "column": 25 + } + } + }, + "arguments": [ + { + "type": "Identifier", + "name": "stuff", + "loc": { + "start": { + "line": 1, + "column": 26 + }, + "end": { + "line": 1, + "column": 31 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 18 + }, + "end": { + "line": 1, + "column": 32 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 18 + }, + "end": { + "line": 1, + "column": 32 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 16 + }, + "end": { + "line": 1, + "column": 34 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 34 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 34 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/281/actual.js b/packages/babylon/test/fixtures/core/uncategorised/281/actual.js new file mode 100644 index 0000000000..a9e58c6a3a --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/281/actual.js @@ -0,0 +1 @@ +try { doThat(); } catch (e) { say(e) } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/281/expected.json b/packages/babylon/test/fixtures/core/uncategorised/281/expected.json new file mode 100644 index 0000000000..8986a4d029 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/281/expected.json @@ -0,0 +1,183 @@ +{ + "type": "Program", + "body": [ + { + "type": "TryStatement", + "block": { + "type": "BlockStatement", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "CallExpression", + "callee": { + "type": "Identifier", + "name": "doThat", + "loc": { + "start": { + "line": 1, + "column": 6 + }, + "end": { + "line": 1, + "column": 12 + } + } + }, + "arguments": [], + "loc": { + "start": { + "line": 1, + "column": 6 + }, + "end": { + "line": 1, + "column": 14 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 6 + }, + "end": { + "line": 1, + "column": 15 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 17 + } + } + }, + "handler": { + "type": "CatchClause", + "param": { + "type": "Identifier", + "name": "e", + "loc": { + "start": { + "line": 1, + "column": 25 + }, + "end": { + "line": 1, + "column": 26 + } + } + }, + "body": { + "type": "BlockStatement", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "CallExpression", + "callee": { + "type": "Identifier", + "name": "say", + "loc": { + "start": { + "line": 1, + "column": 30 + }, + "end": { + "line": 1, + "column": 33 + } + } + }, + "arguments": [ + { + "type": "Identifier", + "name": "e", + "loc": { + "start": { + "line": 1, + "column": 34 + }, + "end": { + "line": 1, + "column": 35 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 30 + }, + "end": { + "line": 1, + "column": 36 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 30 + }, + "end": { + "line": 1, + "column": 36 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 28 + }, + "end": { + "line": 1, + "column": 38 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 18 + }, + "end": { + "line": 1, + "column": 38 + } + } + }, + "finalizer": null, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 38 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 38 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/282/actual.js b/packages/babylon/test/fixtures/core/uncategorised/282/actual.js new file mode 100644 index 0000000000..e457d7facd --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/282/actual.js @@ -0,0 +1 @@ +try { doThat(); } catch (e) { say(e) } finally { cleanup(stuff) } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/282/expected.json b/packages/babylon/test/fixtures/core/uncategorised/282/expected.json new file mode 100644 index 0000000000..70f7460324 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/282/expected.json @@ -0,0 +1,253 @@ +{ + "type": "Program", + "body": [ + { + "type": "TryStatement", + "block": { + "type": "BlockStatement", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "CallExpression", + "callee": { + "type": "Identifier", + "name": "doThat", + "loc": { + "start": { + "line": 1, + "column": 6 + }, + "end": { + "line": 1, + "column": 12 + } + } + }, + "arguments": [], + "loc": { + "start": { + "line": 1, + "column": 6 + }, + "end": { + "line": 1, + "column": 14 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 6 + }, + "end": { + "line": 1, + "column": 15 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 17 + } + } + }, + "handler": { + "type": "CatchClause", + "param": { + "type": "Identifier", + "name": "e", + "loc": { + "start": { + "line": 1, + "column": 25 + }, + "end": { + "line": 1, + "column": 26 + } + } + }, + "body": { + "type": "BlockStatement", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "CallExpression", + "callee": { + "type": "Identifier", + "name": "say", + "loc": { + "start": { + "line": 1, + "column": 30 + }, + "end": { + "line": 1, + "column": 33 + } + } + }, + "arguments": [ + { + "type": "Identifier", + "name": "e", + "loc": { + "start": { + "line": 1, + "column": 34 + }, + "end": { + "line": 1, + "column": 35 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 30 + }, + "end": { + "line": 1, + "column": 36 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 30 + }, + "end": { + "line": 1, + "column": 36 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 28 + }, + "end": { + "line": 1, + "column": 38 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 18 + }, + "end": { + "line": 1, + "column": 38 + } + } + }, + "finalizer": { + "type": "BlockStatement", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "CallExpression", + "callee": { + "type": "Identifier", + "name": "cleanup", + "loc": { + "start": { + "line": 1, + "column": 49 + }, + "end": { + "line": 1, + "column": 56 + } + } + }, + "arguments": [ + { + "type": "Identifier", + "name": "stuff", + "loc": { + "start": { + "line": 1, + "column": 57 + }, + "end": { + "line": 1, + "column": 62 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 49 + }, + "end": { + "line": 1, + "column": 63 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 49 + }, + "end": { + "line": 1, + "column": 63 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 47 + }, + "end": { + "line": 1, + "column": 65 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 65 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 65 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/283/actual.js b/packages/babylon/test/fixtures/core/uncategorised/283/actual.js new file mode 100644 index 0000000000..9f5fb105ad --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/283/actual.js @@ -0,0 +1 @@ +debugger; \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/283/expected.json b/packages/babylon/test/fixtures/core/uncategorised/283/expected.json new file mode 100644 index 0000000000..0dfebca71e --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/283/expected.json @@ -0,0 +1,28 @@ +{ + "type": "Program", + "body": [ + { + "type": "DebuggerStatement", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/284/actual.js b/packages/babylon/test/fixtures/core/uncategorised/284/actual.js new file mode 100644 index 0000000000..5a9b481f5d --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/284/actual.js @@ -0,0 +1 @@ +function hello() { sayHi(); } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/284/expected.json b/packages/babylon/test/fixtures/core/uncategorised/284/expected.json new file mode 100644 index 0000000000..5ee992a111 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/284/expected.json @@ -0,0 +1,99 @@ +{ + "type": "Program", + "body": [ + { + "type": "FunctionDeclaration", + "id": { + "type": "Identifier", + "name": "hello", + "loc": { + "start": { + "line": 1, + "column": 9 + }, + "end": { + "line": 1, + "column": 14 + } + } + }, + "params": [], + "body": { + "type": "BlockStatement", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "CallExpression", + "callee": { + "type": "Identifier", + "name": "sayHi", + "loc": { + "start": { + "line": 1, + "column": 19 + }, + "end": { + "line": 1, + "column": 24 + } + } + }, + "arguments": [], + "loc": { + "start": { + "line": 1, + "column": 19 + }, + "end": { + "line": 1, + "column": 26 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 19 + }, + "end": { + "line": 1, + "column": 27 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 17 + }, + "end": { + "line": 1, + "column": 29 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 29 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 29 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/285/actual.js b/packages/babylon/test/fixtures/core/uncategorised/285/actual.js new file mode 100644 index 0000000000..e2ecc80e0a --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/285/actual.js @@ -0,0 +1 @@ +function eval() { } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/285/expected.json b/packages/babylon/test/fixtures/core/uncategorised/285/expected.json new file mode 100644 index 0000000000..7833226c19 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/285/expected.json @@ -0,0 +1,57 @@ +{ + "type": "Program", + "body": [ + { + "type": "FunctionDeclaration", + "id": { + "type": "Identifier", + "name": "eval", + "loc": { + "start": { + "line": 1, + "column": 9 + }, + "end": { + "line": 1, + "column": 13 + } + } + }, + "params": [], + "body": { + "type": "BlockStatement", + "body": [], + "loc": { + "start": { + "line": 1, + "column": 16 + }, + "end": { + "line": 1, + "column": 19 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 19 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 19 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/286/actual.js b/packages/babylon/test/fixtures/core/uncategorised/286/actual.js new file mode 100644 index 0000000000..705459a130 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/286/actual.js @@ -0,0 +1 @@ +function arguments() { } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/286/expected.json b/packages/babylon/test/fixtures/core/uncategorised/286/expected.json new file mode 100644 index 0000000000..621e675d7b --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/286/expected.json @@ -0,0 +1,57 @@ +{ + "type": "Program", + "body": [ + { + "type": "FunctionDeclaration", + "id": { + "type": "Identifier", + "name": "arguments", + "loc": { + "start": { + "line": 1, + "column": 9 + }, + "end": { + "line": 1, + "column": 18 + } + } + }, + "params": [], + "body": { + "type": "BlockStatement", + "body": [], + "loc": { + "start": { + "line": 1, + "column": 21 + }, + "end": { + "line": 1, + "column": 24 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 24 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 24 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/287/actual.js b/packages/babylon/test/fixtures/core/uncategorised/287/actual.js new file mode 100644 index 0000000000..f175fd490e --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/287/actual.js @@ -0,0 +1 @@ +function test(t, t) { } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/287/expected.json b/packages/babylon/test/fixtures/core/uncategorised/287/expected.json new file mode 100644 index 0000000000..c8387c81ac --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/287/expected.json @@ -0,0 +1,86 @@ +{ + "type": "Program", + "body": [ + { + "type": "FunctionDeclaration", + "id": { + "type": "Identifier", + "name": "test", + "loc": { + "start": { + "line": 1, + "column": 9 + }, + "end": { + "line": 1, + "column": 13 + } + } + }, + "params": [ + { + "type": "Identifier", + "name": "t", + "loc": { + "start": { + "line": 1, + "column": 14 + }, + "end": { + "line": 1, + "column": 15 + } + } + }, + { + "type": "Identifier", + "name": "t", + "loc": { + "start": { + "line": 1, + "column": 17 + }, + "end": { + "line": 1, + "column": 18 + } + } + } + ], + "body": { + "type": "BlockStatement", + "body": [], + "loc": { + "start": { + "line": 1, + "column": 20 + }, + "end": { + "line": 1, + "column": 23 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 23 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 23 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/288/actual.js b/packages/babylon/test/fixtures/core/uncategorised/288/actual.js new file mode 100644 index 0000000000..c6db60a3b8 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/288/actual.js @@ -0,0 +1 @@ +(function test(t, t) { }) \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/288/expected.json b/packages/babylon/test/fixtures/core/uncategorised/288/expected.json new file mode 100644 index 0000000000..5ddbbf2396 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/288/expected.json @@ -0,0 +1,99 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "FunctionExpression", + "id": { + "type": "Identifier", + "name": "test", + "loc": { + "start": { + "line": 1, + "column": 10 + }, + "end": { + "line": 1, + "column": 14 + } + } + }, + "params": [ + { + "type": "Identifier", + "name": "t", + "loc": { + "start": { + "line": 1, + "column": 15 + }, + "end": { + "line": 1, + "column": 16 + } + } + }, + { + "type": "Identifier", + "name": "t", + "loc": { + "start": { + "line": 1, + "column": 18 + }, + "end": { + "line": 1, + "column": 19 + } + } + } + ], + "body": { + "type": "BlockStatement", + "body": [], + "loc": { + "start": { + "line": 1, + "column": 21 + }, + "end": { + "line": 1, + "column": 24 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 1 + }, + "end": { + "line": 1, + "column": 24 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 25 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 25 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/289/actual.js b/packages/babylon/test/fixtures/core/uncategorised/289/actual.js new file mode 100644 index 0000000000..d273ac11a0 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/289/actual.js @@ -0,0 +1 @@ +function eval() { function inner() { "use strict" } } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/289/expected.json b/packages/babylon/test/fixtures/core/uncategorised/289/expected.json new file mode 100644 index 0000000000..8ba2d6394d --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/289/expected.json @@ -0,0 +1,128 @@ +{ + "type": "Program", + "body": [ + { + "type": "FunctionDeclaration", + "id": { + "type": "Identifier", + "name": "eval", + "loc": { + "start": { + "line": 1, + "column": 9 + }, + "end": { + "line": 1, + "column": 13 + } + } + }, + "params": [], + "body": { + "type": "BlockStatement", + "body": [ + { + "type": "FunctionDeclaration", + "id": { + "type": "Identifier", + "name": "inner", + "loc": { + "start": { + "line": 1, + "column": 27 + }, + "end": { + "line": 1, + "column": 32 + } + } + }, + "params": [], + "body": { + "type": "BlockStatement", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "Literal", + "value": "use strict", + "loc": { + "start": { + "line": 1, + "column": 37 + }, + "end": { + "line": 1, + "column": 49 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 37 + }, + "end": { + "line": 1, + "column": 49 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 35 + }, + "end": { + "line": 1, + "column": 51 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 18 + }, + "end": { + "line": 1, + "column": 51 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 16 + }, + "end": { + "line": 1, + "column": 53 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 53 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 53 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/29/actual.js b/packages/babylon/test/fixtures/core/uncategorised/29/actual.js new file mode 100644 index 0000000000..6184558260 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/29/actual.js @@ -0,0 +1 @@ +x = { get width() { return m_width } } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/29/expected.json b/packages/babylon/test/fixtures/core/uncategorised/29/expected.json new file mode 100644 index 0000000000..afb4307190 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/29/expected.json @@ -0,0 +1,146 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "AssignmentExpression", + "operator": "=", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "right": { + "type": "ObjectExpression", + "properties": [ + { + "type": "Property", + "key": { + "type": "Identifier", + "name": "width", + "loc": { + "start": { + "line": 1, + "column": 10 + }, + "end": { + "line": 1, + "column": 15 + } + } + }, + "kind": "get", + "value": { + "type": "FunctionExpression", + "id": null, + "params": [], + "body": { + "type": "BlockStatement", + "body": [ + { + "type": "ReturnStatement", + "argument": { + "type": "Identifier", + "name": "m_width", + "loc": { + "start": { + "line": 1, + "column": 27 + }, + "end": { + "line": 1, + "column": 34 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 20 + }, + "end": { + "line": 1, + "column": 34 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 18 + }, + "end": { + "line": 1, + "column": 36 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 15 + }, + "end": { + "line": 1, + "column": 36 + } + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 38 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 38 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 38 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 38 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/290/actual.js b/packages/babylon/test/fixtures/core/uncategorised/290/actual.js new file mode 100644 index 0000000000..e8689d11fc --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/290/actual.js @@ -0,0 +1 @@ +function hello(a) { sayHi(); } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/290/expected.json b/packages/babylon/test/fixtures/core/uncategorised/290/expected.json new file mode 100644 index 0000000000..1bbafe042f --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/290/expected.json @@ -0,0 +1,114 @@ +{ + "type": "Program", + "body": [ + { + "type": "FunctionDeclaration", + "id": { + "type": "Identifier", + "name": "hello", + "loc": { + "start": { + "line": 1, + "column": 9 + }, + "end": { + "line": 1, + "column": 14 + } + } + }, + "params": [ + { + "type": "Identifier", + "name": "a", + "loc": { + "start": { + "line": 1, + "column": 15 + }, + "end": { + "line": 1, + "column": 16 + } + } + } + ], + "body": { + "type": "BlockStatement", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "CallExpression", + "callee": { + "type": "Identifier", + "name": "sayHi", + "loc": { + "start": { + "line": 1, + "column": 20 + }, + "end": { + "line": 1, + "column": 25 + } + } + }, + "arguments": [], + "loc": { + "start": { + "line": 1, + "column": 20 + }, + "end": { + "line": 1, + "column": 27 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 20 + }, + "end": { + "line": 1, + "column": 28 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 18 + }, + "end": { + "line": 1, + "column": 30 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 30 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 30 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/291/actual.js b/packages/babylon/test/fixtures/core/uncategorised/291/actual.js new file mode 100644 index 0000000000..6bed4aef96 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/291/actual.js @@ -0,0 +1 @@ +function hello(a, b) { sayHi(); } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/291/expected.json b/packages/babylon/test/fixtures/core/uncategorised/291/expected.json new file mode 100644 index 0000000000..77c1953458 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/291/expected.json @@ -0,0 +1,128 @@ +{ + "type": "Program", + "body": [ + { + "type": "FunctionDeclaration", + "id": { + "type": "Identifier", + "name": "hello", + "loc": { + "start": { + "line": 1, + "column": 9 + }, + "end": { + "line": 1, + "column": 14 + } + } + }, + "params": [ + { + "type": "Identifier", + "name": "a", + "loc": { + "start": { + "line": 1, + "column": 15 + }, + "end": { + "line": 1, + "column": 16 + } + } + }, + { + "type": "Identifier", + "name": "b", + "loc": { + "start": { + "line": 1, + "column": 18 + }, + "end": { + "line": 1, + "column": 19 + } + } + } + ], + "body": { + "type": "BlockStatement", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "CallExpression", + "callee": { + "type": "Identifier", + "name": "sayHi", + "loc": { + "start": { + "line": 1, + "column": 23 + }, + "end": { + "line": 1, + "column": 28 + } + } + }, + "arguments": [], + "loc": { + "start": { + "line": 1, + "column": 23 + }, + "end": { + "line": 1, + "column": 30 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 23 + }, + "end": { + "line": 1, + "column": 31 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 21 + }, + "end": { + "line": 1, + "column": 33 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 33 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 33 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/292/actual.js b/packages/babylon/test/fixtures/core/uncategorised/292/actual.js new file mode 100644 index 0000000000..930c571193 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/292/actual.js @@ -0,0 +1 @@ +function hello(...rest) { } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/292/expected.json b/packages/babylon/test/fixtures/core/uncategorised/292/expected.json new file mode 100644 index 0000000000..350aa3f2a2 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/292/expected.json @@ -0,0 +1,75 @@ +{ + "type": "Program", + "body": [ + { + "type": "FunctionDeclaration", + "id": { + "type": "Identifier", + "name": "hello", + "loc": { + "start": { + "line": 1, + "column": 9 + }, + "end": { + "line": 1, + "column": 14 + } + } + }, + "params": [ + { + "type": "RestElement", + "argument": { + "type": "Identifier", + "name": "rest", + "loc": { + "start": { + "line": 1, + "column": 18 + }, + "end": { + "line": 1, + "column": 22 + } + } + } + } + ], + "body": { + "type": "BlockStatement", + "body": [], + "loc": { + "start": { + "line": 1, + "column": 24 + }, + "end": { + "line": 1, + "column": 27 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 27 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 27 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/293/actual.js b/packages/babylon/test/fixtures/core/uncategorised/293/actual.js new file mode 100644 index 0000000000..be03fa511c --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/293/actual.js @@ -0,0 +1 @@ +function hello(a, ...rest) { } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/293/expected.json b/packages/babylon/test/fixtures/core/uncategorised/293/expected.json new file mode 100644 index 0000000000..105ef534fe --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/293/expected.json @@ -0,0 +1,89 @@ +{ + "type": "Program", + "body": [ + { + "type": "FunctionDeclaration", + "id": { + "type": "Identifier", + "name": "hello", + "loc": { + "start": { + "line": 1, + "column": 9 + }, + "end": { + "line": 1, + "column": 14 + } + } + }, + "params": [ + { + "type": "Identifier", + "name": "a", + "loc": { + "start": { + "line": 1, + "column": 15 + }, + "end": { + "line": 1, + "column": 16 + } + } + }, + { + "type": "RestElement", + "argument": { + "type": "Identifier", + "name": "rest", + "loc": { + "start": { + "line": 1, + "column": 21 + }, + "end": { + "line": 1, + "column": 25 + } + } + } + } + ], + "body": { + "type": "BlockStatement", + "body": [], + "loc": { + "start": { + "line": 1, + "column": 27 + }, + "end": { + "line": 1, + "column": 30 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 30 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 30 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/294/actual.js b/packages/babylon/test/fixtures/core/uncategorised/294/actual.js new file mode 100644 index 0000000000..93adf3f6a9 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/294/actual.js @@ -0,0 +1 @@ +var hi = function() { sayHi() }; \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/294/expected.json b/packages/babylon/test/fixtures/core/uncategorised/294/expected.json new file mode 100644 index 0000000000..876dee77aa --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/294/expected.json @@ -0,0 +1,129 @@ +{ + "type": "Program", + "body": [ + { + "type": "VariableDeclaration", + "declarations": [ + { + "type": "VariableDeclarator", + "id": { + "type": "Identifier", + "name": "hi", + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 6 + } + } + }, + "init": { + "type": "FunctionExpression", + "id": null, + "params": [], + "body": { + "type": "BlockStatement", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "CallExpression", + "callee": { + "type": "Identifier", + "name": "sayHi", + "loc": { + "start": { + "line": 1, + "column": 22 + }, + "end": { + "line": 1, + "column": 27 + } + } + }, + "arguments": [], + "loc": { + "start": { + "line": 1, + "column": 22 + }, + "end": { + "line": 1, + "column": 29 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 22 + }, + "end": { + "line": 1, + "column": 29 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 20 + }, + "end": { + "line": 1, + "column": 31 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 9 + }, + "end": { + "line": 1, + "column": 31 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 31 + } + } + } + ], + "kind": "var", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 32 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 32 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/295/actual.js b/packages/babylon/test/fixtures/core/uncategorised/295/actual.js new file mode 100644 index 0000000000..13ffc75668 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/295/actual.js @@ -0,0 +1 @@ +var hi = function (...r) { sayHi() }; \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/295/expected.json b/packages/babylon/test/fixtures/core/uncategorised/295/expected.json new file mode 100644 index 0000000000..007386e963 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/295/expected.json @@ -0,0 +1,147 @@ +{ + "type": "Program", + "body": [ + { + "type": "VariableDeclaration", + "declarations": [ + { + "type": "VariableDeclarator", + "id": { + "type": "Identifier", + "name": "hi", + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 6 + } + } + }, + "init": { + "type": "FunctionExpression", + "id": null, + "params": [ + { + "type": "RestElement", + "argument": { + "type": "Identifier", + "name": "r", + "loc": { + "start": { + "line": 1, + "column": 22 + }, + "end": { + "line": 1, + "column": 23 + } + } + } + } + ], + "body": { + "type": "BlockStatement", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "CallExpression", + "callee": { + "type": "Identifier", + "name": "sayHi", + "loc": { + "start": { + "line": 1, + "column": 27 + }, + "end": { + "line": 1, + "column": 32 + } + } + }, + "arguments": [], + "loc": { + "start": { + "line": 1, + "column": 27 + }, + "end": { + "line": 1, + "column": 34 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 27 + }, + "end": { + "line": 1, + "column": 34 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 25 + }, + "end": { + "line": 1, + "column": 36 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 9 + }, + "end": { + "line": 1, + "column": 36 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 36 + } + } + } + ], + "kind": "var", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 37 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 37 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/296/actual.js b/packages/babylon/test/fixtures/core/uncategorised/296/actual.js new file mode 100644 index 0000000000..f1f907ef65 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/296/actual.js @@ -0,0 +1 @@ +var hi = function eval() { }; \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/296/expected.json b/packages/babylon/test/fixtures/core/uncategorised/296/expected.json new file mode 100644 index 0000000000..438dba8044 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/296/expected.json @@ -0,0 +1,100 @@ +{ + "type": "Program", + "body": [ + { + "type": "VariableDeclaration", + "declarations": [ + { + "type": "VariableDeclarator", + "id": { + "type": "Identifier", + "name": "hi", + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 6 + } + } + }, + "init": { + "type": "FunctionExpression", + "id": { + "type": "Identifier", + "name": "eval", + "loc": { + "start": { + "line": 1, + "column": 18 + }, + "end": { + "line": 1, + "column": 22 + } + } + }, + "params": [], + "body": { + "type": "BlockStatement", + "body": [], + "loc": { + "start": { + "line": 1, + "column": 25 + }, + "end": { + "line": 1, + "column": 28 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 9 + }, + "end": { + "line": 1, + "column": 28 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 28 + } + } + } + ], + "kind": "var", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 29 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 29 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/297/actual.js b/packages/babylon/test/fixtures/core/uncategorised/297/actual.js new file mode 100644 index 0000000000..4f643b12a7 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/297/actual.js @@ -0,0 +1 @@ +var hi = function arguments() { }; \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/297/expected.json b/packages/babylon/test/fixtures/core/uncategorised/297/expected.json new file mode 100644 index 0000000000..8cbcab195a --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/297/expected.json @@ -0,0 +1,100 @@ +{ + "type": "Program", + "body": [ + { + "type": "VariableDeclaration", + "declarations": [ + { + "type": "VariableDeclarator", + "id": { + "type": "Identifier", + "name": "hi", + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 6 + } + } + }, + "init": { + "type": "FunctionExpression", + "id": { + "type": "Identifier", + "name": "arguments", + "loc": { + "start": { + "line": 1, + "column": 18 + }, + "end": { + "line": 1, + "column": 27 + } + } + }, + "params": [], + "body": { + "type": "BlockStatement", + "body": [], + "loc": { + "start": { + "line": 1, + "column": 30 + }, + "end": { + "line": 1, + "column": 33 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 9 + }, + "end": { + "line": 1, + "column": 33 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 33 + } + } + } + ], + "kind": "var", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 34 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 34 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/298/actual.js b/packages/babylon/test/fixtures/core/uncategorised/298/actual.js new file mode 100644 index 0000000000..a531f59b06 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/298/actual.js @@ -0,0 +1 @@ +var hello = function hi() { sayHi() }; \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/298/expected.json b/packages/babylon/test/fixtures/core/uncategorised/298/expected.json new file mode 100644 index 0000000000..ad34c55881 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/298/expected.json @@ -0,0 +1,142 @@ +{ + "type": "Program", + "body": [ + { + "type": "VariableDeclaration", + "declarations": [ + { + "type": "VariableDeclarator", + "id": { + "type": "Identifier", + "name": "hello", + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + "init": { + "type": "FunctionExpression", + "id": { + "type": "Identifier", + "name": "hi", + "loc": { + "start": { + "line": 1, + "column": 21 + }, + "end": { + "line": 1, + "column": 23 + } + } + }, + "params": [], + "body": { + "type": "BlockStatement", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "CallExpression", + "callee": { + "type": "Identifier", + "name": "sayHi", + "loc": { + "start": { + "line": 1, + "column": 28 + }, + "end": { + "line": 1, + "column": 33 + } + } + }, + "arguments": [], + "loc": { + "start": { + "line": 1, + "column": 28 + }, + "end": { + "line": 1, + "column": 35 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 28 + }, + "end": { + "line": 1, + "column": 35 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 26 + }, + "end": { + "line": 1, + "column": 37 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 12 + }, + "end": { + "line": 1, + "column": 37 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 37 + } + } + } + ], + "kind": "var", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 38 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 38 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/299/actual.js b/packages/babylon/test/fixtures/core/uncategorised/299/actual.js new file mode 100644 index 0000000000..4c206a3f48 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/299/actual.js @@ -0,0 +1 @@ +(function(){}) \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/299/expected.json b/packages/babylon/test/fixtures/core/uncategorised/299/expected.json new file mode 100644 index 0000000000..87a2546c72 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/299/expected.json @@ -0,0 +1,57 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "FunctionExpression", + "id": null, + "params": [], + "body": { + "type": "BlockStatement", + "body": [], + "loc": { + "start": { + "line": 1, + "column": 11 + }, + "end": { + "line": 1, + "column": 13 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 1 + }, + "end": { + "line": 1, + "column": 13 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 14 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 14 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/3/actual.js b/packages/babylon/test/fixtures/core/uncategorised/3/actual.js new file mode 100644 index 0000000000..aa5dcabcca --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/3/actual.js @@ -0,0 +1,3 @@ + + 42 + diff --git a/packages/babylon/test/fixtures/core/uncategorised/3/expected.json b/packages/babylon/test/fixtures/core/uncategorised/3/expected.json new file mode 100644 index 0000000000..b7637b18d9 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/3/expected.json @@ -0,0 +1,51 @@ +{ + "type": "Program", + "start": 0, + "end": 7, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 2, + "column": 6 + } + }, + "sourceType": "script", + "body": [ + { + "type": "ExpressionStatement", + "start": 5, + "end": 7, + "loc": { + "start": { + "line": 2, + "column": 4 + }, + "end": { + "line": 2, + "column": 6 + } + }, + "expression": { + "type": "Literal", + "start": 5, + "end": 7, + "loc": { + "start": { + "line": 2, + "column": 4 + }, + "end": { + "line": 2, + "column": 6 + } + }, + "value": 42, + "rawValue": 42, + "raw": "42" + } + } + ] +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/30/actual.js b/packages/babylon/test/fixtures/core/uncategorised/30/actual.js new file mode 100644 index 0000000000..31858315e9 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/30/actual.js @@ -0,0 +1 @@ +x = { get undef() {} } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/30/expected.json b/packages/babylon/test/fixtures/core/uncategorised/30/expected.json new file mode 100644 index 0000000000..bbc41a35af --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/30/expected.json @@ -0,0 +1,118 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "AssignmentExpression", + "operator": "=", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "right": { + "type": "ObjectExpression", + "properties": [ + { + "type": "Property", + "key": { + "type": "Identifier", + "name": "undef", + "loc": { + "start": { + "line": 1, + "column": 10 + }, + "end": { + "line": 1, + "column": 15 + } + } + }, + "kind": "get", + "value": { + "type": "FunctionExpression", + "id": null, + "params": [], + "body": { + "type": "BlockStatement", + "body": [], + "loc": { + "start": { + "line": 1, + "column": 18 + }, + "end": { + "line": 1, + "column": 20 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 15 + }, + "end": { + "line": 1, + "column": 20 + } + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 22 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 22 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 22 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 22 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/300/actual.js b/packages/babylon/test/fixtures/core/uncategorised/300/actual.js new file mode 100644 index 0000000000..27d3601cea --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/300/actual.js @@ -0,0 +1,2 @@ +{ x +++y } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/300/expected.json b/packages/babylon/test/fixtures/core/uncategorised/300/expected.json new file mode 100644 index 0000000000..cd22c4fb29 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/300/expected.json @@ -0,0 +1,99 @@ +{ + "type": "Program", + "body": [ + { + "type": "BlockStatement", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 2 + }, + "end": { + "line": 1, + "column": 3 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 2 + }, + "end": { + "line": 1, + "column": 3 + } + } + }, + { + "type": "ExpressionStatement", + "expression": { + "type": "UpdateExpression", + "operator": "++", + "prefix": true, + "argument": { + "type": "Identifier", + "name": "y", + "loc": { + "start": { + "line": 2, + "column": 2 + }, + "end": { + "line": 2, + "column": 3 + } + } + }, + "loc": { + "start": { + "line": 2, + "column": 0 + }, + "end": { + "line": 2, + "column": 3 + } + } + }, + "loc": { + "start": { + "line": 2, + "column": 0 + }, + "end": { + "line": 2, + "column": 3 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 2, + "column": 5 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 2, + "column": 5 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/301/actual.js b/packages/babylon/test/fixtures/core/uncategorised/301/actual.js new file mode 100644 index 0000000000..7291b9f9dc --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/301/actual.js @@ -0,0 +1,2 @@ +{ x +--y } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/301/expected.json b/packages/babylon/test/fixtures/core/uncategorised/301/expected.json new file mode 100644 index 0000000000..ee3fee07e2 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/301/expected.json @@ -0,0 +1,99 @@ +{ + "type": "Program", + "body": [ + { + "type": "BlockStatement", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 2 + }, + "end": { + "line": 1, + "column": 3 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 2 + }, + "end": { + "line": 1, + "column": 3 + } + } + }, + { + "type": "ExpressionStatement", + "expression": { + "type": "UpdateExpression", + "operator": "--", + "prefix": true, + "argument": { + "type": "Identifier", + "name": "y", + "loc": { + "start": { + "line": 2, + "column": 2 + }, + "end": { + "line": 2, + "column": 3 + } + } + }, + "loc": { + "start": { + "line": 2, + "column": 0 + }, + "end": { + "line": 2, + "column": 3 + } + } + }, + "loc": { + "start": { + "line": 2, + "column": 0 + }, + "end": { + "line": 2, + "column": 3 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 2, + "column": 5 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 2, + "column": 5 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/302/actual.js b/packages/babylon/test/fixtures/core/uncategorised/302/actual.js new file mode 100644 index 0000000000..8997f17ef6 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/302/actual.js @@ -0,0 +1 @@ +var x /* comment */; \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/302/expected.json b/packages/babylon/test/fixtures/core/uncategorised/302/expected.json new file mode 100644 index 0000000000..51bb077835 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/302/expected.json @@ -0,0 +1,59 @@ +{ + "type": "Program", + "body": [ + { + "type": "VariableDeclaration", + "declarations": [ + { + "type": "VariableDeclarator", + "id": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "init": null, + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 5 + } + } + } + ], + "kind": "var", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 20 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 20 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/303/actual.js b/packages/babylon/test/fixtures/core/uncategorised/303/actual.js new file mode 100644 index 0000000000..d9fb2e4f8d --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/303/actual.js @@ -0,0 +1,2 @@ +{ var x = 14, y = 3 +z; } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/303/expected.json b/packages/babylon/test/fixtures/core/uncategorised/303/expected.json new file mode 100644 index 0000000000..c6c5c13d74 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/303/expected.json @@ -0,0 +1,155 @@ +{ + "type": "Program", + "body": [ + { + "type": "BlockStatement", + "body": [ + { + "type": "VariableDeclaration", + "declarations": [ + { + "type": "VariableDeclarator", + "id": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 6 + }, + "end": { + "line": 1, + "column": 7 + } + } + }, + "init": { + "type": "Literal", + "value": 14, + "loc": { + "start": { + "line": 1, + "column": 10 + }, + "end": { + "line": 1, + "column": 12 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 6 + }, + "end": { + "line": 1, + "column": 12 + } + } + }, + { + "type": "VariableDeclarator", + "id": { + "type": "Identifier", + "name": "y", + "loc": { + "start": { + "line": 1, + "column": 14 + }, + "end": { + "line": 1, + "column": 15 + } + } + }, + "init": { + "type": "Literal", + "value": 3, + "loc": { + "start": { + "line": 1, + "column": 18 + }, + "end": { + "line": 1, + "column": 19 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 14 + }, + "end": { + "line": 1, + "column": 19 + } + } + } + ], + "kind": "var", + "loc": { + "start": { + "line": 1, + "column": 2 + }, + "end": { + "line": 1, + "column": 19 + } + } + }, + { + "type": "ExpressionStatement", + "expression": { + "type": "Identifier", + "name": "z", + "loc": { + "start": { + "line": 2, + "column": 0 + }, + "end": { + "line": 2, + "column": 1 + } + } + }, + "loc": { + "start": { + "line": 2, + "column": 0 + }, + "end": { + "line": 2, + "column": 2 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 2, + "column": 4 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 2, + "column": 4 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/304/actual.js b/packages/babylon/test/fixtures/core/uncategorised/304/actual.js new file mode 100644 index 0000000000..2d427099f5 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/304/actual.js @@ -0,0 +1,2 @@ +while (true) { continue +there; } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/304/expected.json b/packages/babylon/test/fixtures/core/uncategorised/304/expected.json new file mode 100644 index 0000000000..d2714f41fc --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/304/expected.json @@ -0,0 +1,98 @@ +{ + "type": "Program", + "body": [ + { + "type": "WhileStatement", + "test": { + "type": "Literal", + "value": true, + "loc": { + "start": { + "line": 1, + "column": 7 + }, + "end": { + "line": 1, + "column": 11 + } + } + }, + "body": { + "type": "BlockStatement", + "body": [ + { + "type": "ContinueStatement", + "label": null, + "loc": { + "start": { + "line": 1, + "column": 15 + }, + "end": { + "line": 1, + "column": 23 + } + } + }, + { + "type": "ExpressionStatement", + "expression": { + "type": "Identifier", + "name": "there", + "loc": { + "start": { + "line": 2, + "column": 0 + }, + "end": { + "line": 2, + "column": 5 + } + } + }, + "loc": { + "start": { + "line": 2, + "column": 0 + }, + "end": { + "line": 2, + "column": 6 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 13 + }, + "end": { + "line": 2, + "column": 8 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 2, + "column": 8 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 2, + "column": 8 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/305/actual.js b/packages/babylon/test/fixtures/core/uncategorised/305/actual.js new file mode 100644 index 0000000000..acff166099 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/305/actual.js @@ -0,0 +1,2 @@ +while (true) { continue // Comment +there; } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/305/expected.json b/packages/babylon/test/fixtures/core/uncategorised/305/expected.json new file mode 100644 index 0000000000..d2714f41fc --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/305/expected.json @@ -0,0 +1,98 @@ +{ + "type": "Program", + "body": [ + { + "type": "WhileStatement", + "test": { + "type": "Literal", + "value": true, + "loc": { + "start": { + "line": 1, + "column": 7 + }, + "end": { + "line": 1, + "column": 11 + } + } + }, + "body": { + "type": "BlockStatement", + "body": [ + { + "type": "ContinueStatement", + "label": null, + "loc": { + "start": { + "line": 1, + "column": 15 + }, + "end": { + "line": 1, + "column": 23 + } + } + }, + { + "type": "ExpressionStatement", + "expression": { + "type": "Identifier", + "name": "there", + "loc": { + "start": { + "line": 2, + "column": 0 + }, + "end": { + "line": 2, + "column": 5 + } + } + }, + "loc": { + "start": { + "line": 2, + "column": 0 + }, + "end": { + "line": 2, + "column": 6 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 13 + }, + "end": { + "line": 2, + "column": 8 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 2, + "column": 8 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 2, + "column": 8 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/306/actual.js b/packages/babylon/test/fixtures/core/uncategorised/306/actual.js new file mode 100644 index 0000000000..91c90d27cf --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/306/actual.js @@ -0,0 +1,2 @@ +while (true) { continue /* Multiline +Comment */there; } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/306/expected.json b/packages/babylon/test/fixtures/core/uncategorised/306/expected.json new file mode 100644 index 0000000000..41a196ed9f --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/306/expected.json @@ -0,0 +1,98 @@ +{ + "type": "Program", + "body": [ + { + "type": "WhileStatement", + "test": { + "type": "Literal", + "value": true, + "loc": { + "start": { + "line": 1, + "column": 7 + }, + "end": { + "line": 1, + "column": 11 + } + } + }, + "body": { + "type": "BlockStatement", + "body": [ + { + "type": "ContinueStatement", + "label": null, + "loc": { + "start": { + "line": 1, + "column": 15 + }, + "end": { + "line": 1, + "column": 23 + } + } + }, + { + "type": "ExpressionStatement", + "expression": { + "type": "Identifier", + "name": "there", + "loc": { + "start": { + "line": 2, + "column": 10 + }, + "end": { + "line": 2, + "column": 15 + } + } + }, + "loc": { + "start": { + "line": 2, + "column": 10 + }, + "end": { + "line": 2, + "column": 16 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 13 + }, + "end": { + "line": 2, + "column": 18 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 2, + "column": 18 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 2, + "column": 18 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/307/actual.js b/packages/babylon/test/fixtures/core/uncategorised/307/actual.js new file mode 100644 index 0000000000..f88d9ebe33 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/307/actual.js @@ -0,0 +1,2 @@ +while (true) { break +there; } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/307/expected.json b/packages/babylon/test/fixtures/core/uncategorised/307/expected.json new file mode 100644 index 0000000000..0a0418a45d --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/307/expected.json @@ -0,0 +1,98 @@ +{ + "type": "Program", + "body": [ + { + "type": "WhileStatement", + "test": { + "type": "Literal", + "value": true, + "loc": { + "start": { + "line": 1, + "column": 7 + }, + "end": { + "line": 1, + "column": 11 + } + } + }, + "body": { + "type": "BlockStatement", + "body": [ + { + "type": "BreakStatement", + "label": null, + "loc": { + "start": { + "line": 1, + "column": 15 + }, + "end": { + "line": 1, + "column": 20 + } + } + }, + { + "type": "ExpressionStatement", + "expression": { + "type": "Identifier", + "name": "there", + "loc": { + "start": { + "line": 2, + "column": 0 + }, + "end": { + "line": 2, + "column": 5 + } + } + }, + "loc": { + "start": { + "line": 2, + "column": 0 + }, + "end": { + "line": 2, + "column": 6 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 13 + }, + "end": { + "line": 2, + "column": 8 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 2, + "column": 8 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 2, + "column": 8 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/308/actual.js b/packages/babylon/test/fixtures/core/uncategorised/308/actual.js new file mode 100644 index 0000000000..ca7755f113 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/308/actual.js @@ -0,0 +1,2 @@ +while (true) { break // Comment +there; } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/308/expected.json b/packages/babylon/test/fixtures/core/uncategorised/308/expected.json new file mode 100644 index 0000000000..0a0418a45d --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/308/expected.json @@ -0,0 +1,98 @@ +{ + "type": "Program", + "body": [ + { + "type": "WhileStatement", + "test": { + "type": "Literal", + "value": true, + "loc": { + "start": { + "line": 1, + "column": 7 + }, + "end": { + "line": 1, + "column": 11 + } + } + }, + "body": { + "type": "BlockStatement", + "body": [ + { + "type": "BreakStatement", + "label": null, + "loc": { + "start": { + "line": 1, + "column": 15 + }, + "end": { + "line": 1, + "column": 20 + } + } + }, + { + "type": "ExpressionStatement", + "expression": { + "type": "Identifier", + "name": "there", + "loc": { + "start": { + "line": 2, + "column": 0 + }, + "end": { + "line": 2, + "column": 5 + } + } + }, + "loc": { + "start": { + "line": 2, + "column": 0 + }, + "end": { + "line": 2, + "column": 6 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 13 + }, + "end": { + "line": 2, + "column": 8 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 2, + "column": 8 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 2, + "column": 8 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/309/actual.js b/packages/babylon/test/fixtures/core/uncategorised/309/actual.js new file mode 100644 index 0000000000..f689faf2b5 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/309/actual.js @@ -0,0 +1,2 @@ +while (true) { break /* Multiline +Comment */there; } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/309/expected.json b/packages/babylon/test/fixtures/core/uncategorised/309/expected.json new file mode 100644 index 0000000000..312cbfb418 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/309/expected.json @@ -0,0 +1,98 @@ +{ + "type": "Program", + "body": [ + { + "type": "WhileStatement", + "test": { + "type": "Literal", + "value": true, + "loc": { + "start": { + "line": 1, + "column": 7 + }, + "end": { + "line": 1, + "column": 11 + } + } + }, + "body": { + "type": "BlockStatement", + "body": [ + { + "type": "BreakStatement", + "label": null, + "loc": { + "start": { + "line": 1, + "column": 15 + }, + "end": { + "line": 1, + "column": 20 + } + } + }, + { + "type": "ExpressionStatement", + "expression": { + "type": "Identifier", + "name": "there", + "loc": { + "start": { + "line": 2, + "column": 10 + }, + "end": { + "line": 2, + "column": 15 + } + } + }, + "loc": { + "start": { + "line": 2, + "column": 10 + }, + "end": { + "line": 2, + "column": 16 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 13 + }, + "end": { + "line": 2, + "column": 18 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 2, + "column": 18 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 2, + "column": 18 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/31/actual.js b/packages/babylon/test/fixtures/core/uncategorised/31/actual.js new file mode 100644 index 0000000000..d36a62233b --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/31/actual.js @@ -0,0 +1 @@ +x = { get if() {} } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/31/expected.json b/packages/babylon/test/fixtures/core/uncategorised/31/expected.json new file mode 100644 index 0000000000..b3798b19ba --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/31/expected.json @@ -0,0 +1,118 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "AssignmentExpression", + "operator": "=", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "right": { + "type": "ObjectExpression", + "properties": [ + { + "type": "Property", + "key": { + "type": "Identifier", + "name": "if", + "loc": { + "start": { + "line": 1, + "column": 10 + }, + "end": { + "line": 1, + "column": 12 + } + } + }, + "kind": "get", + "value": { + "type": "FunctionExpression", + "id": null, + "params": [], + "body": { + "type": "BlockStatement", + "body": [], + "loc": { + "start": { + "line": 1, + "column": 15 + }, + "end": { + "line": 1, + "column": 17 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 12 + }, + "end": { + "line": 1, + "column": 17 + } + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 19 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 19 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 19 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 19 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/310/actual.js b/packages/babylon/test/fixtures/core/uncategorised/310/actual.js new file mode 100644 index 0000000000..8fa031ad16 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/310/actual.js @@ -0,0 +1,2 @@ +(function(){ return +x; }) \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/310/expected.json b/packages/babylon/test/fixtures/core/uncategorised/310/expected.json new file mode 100644 index 0000000000..cb564bb40f --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/310/expected.json @@ -0,0 +1,99 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "FunctionExpression", + "id": null, + "params": [], + "body": { + "type": "BlockStatement", + "body": [ + { + "type": "ReturnStatement", + "argument": null, + "loc": { + "start": { + "line": 1, + "column": 13 + }, + "end": { + "line": 1, + "column": 19 + } + } + }, + { + "type": "ExpressionStatement", + "expression": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 2, + "column": 0 + }, + "end": { + "line": 2, + "column": 1 + } + } + }, + "loc": { + "start": { + "line": 2, + "column": 0 + }, + "end": { + "line": 2, + "column": 2 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 11 + }, + "end": { + "line": 2, + "column": 4 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 1 + }, + "end": { + "line": 2, + "column": 4 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 2, + "column": 5 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 2, + "column": 5 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/311/actual.js b/packages/babylon/test/fixtures/core/uncategorised/311/actual.js new file mode 100644 index 0000000000..fe3fb4ab97 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/311/actual.js @@ -0,0 +1,2 @@ +(function(){ return // Comment +x; }) \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/311/expected.json b/packages/babylon/test/fixtures/core/uncategorised/311/expected.json new file mode 100644 index 0000000000..cb564bb40f --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/311/expected.json @@ -0,0 +1,99 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "FunctionExpression", + "id": null, + "params": [], + "body": { + "type": "BlockStatement", + "body": [ + { + "type": "ReturnStatement", + "argument": null, + "loc": { + "start": { + "line": 1, + "column": 13 + }, + "end": { + "line": 1, + "column": 19 + } + } + }, + { + "type": "ExpressionStatement", + "expression": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 2, + "column": 0 + }, + "end": { + "line": 2, + "column": 1 + } + } + }, + "loc": { + "start": { + "line": 2, + "column": 0 + }, + "end": { + "line": 2, + "column": 2 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 11 + }, + "end": { + "line": 2, + "column": 4 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 1 + }, + "end": { + "line": 2, + "column": 4 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 2, + "column": 5 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 2, + "column": 5 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/312/actual.js b/packages/babylon/test/fixtures/core/uncategorised/312/actual.js new file mode 100644 index 0000000000..fcd344be01 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/312/actual.js @@ -0,0 +1,2 @@ +(function(){ return/* Multiline +Comment */x; }) \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/312/expected.json b/packages/babylon/test/fixtures/core/uncategorised/312/expected.json new file mode 100644 index 0000000000..a451b76b12 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/312/expected.json @@ -0,0 +1,99 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "FunctionExpression", + "id": null, + "params": [], + "body": { + "type": "BlockStatement", + "body": [ + { + "type": "ReturnStatement", + "argument": null, + "loc": { + "start": { + "line": 1, + "column": 13 + }, + "end": { + "line": 1, + "column": 19 + } + } + }, + { + "type": "ExpressionStatement", + "expression": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 2, + "column": 10 + }, + "end": { + "line": 2, + "column": 11 + } + } + }, + "loc": { + "start": { + "line": 2, + "column": 10 + }, + "end": { + "line": 2, + "column": 12 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 11 + }, + "end": { + "line": 2, + "column": 14 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 1 + }, + "end": { + "line": 2, + "column": 14 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 2, + "column": 15 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 2, + "column": 15 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/313/actual.js b/packages/babylon/test/fixtures/core/uncategorised/313/actual.js new file mode 100644 index 0000000000..6431b5a20b --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/313/actual.js @@ -0,0 +1,2 @@ +{ throw error +error; } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/313/expected.json b/packages/babylon/test/fixtures/core/uncategorised/313/expected.json new file mode 100644 index 0000000000..83b1e30f9e --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/313/expected.json @@ -0,0 +1,84 @@ +{ + "type": "Program", + "body": [ + { + "type": "BlockStatement", + "body": [ + { + "type": "ThrowStatement", + "argument": { + "type": "Identifier", + "name": "error", + "loc": { + "start": { + "line": 1, + "column": 8 + }, + "end": { + "line": 1, + "column": 13 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 2 + }, + "end": { + "line": 1, + "column": 13 + } + } + }, + { + "type": "ExpressionStatement", + "expression": { + "type": "Identifier", + "name": "error", + "loc": { + "start": { + "line": 2, + "column": 0 + }, + "end": { + "line": 2, + "column": 5 + } + } + }, + "loc": { + "start": { + "line": 2, + "column": 0 + }, + "end": { + "line": 2, + "column": 6 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 2, + "column": 8 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 2, + "column": 8 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/314/actual.js b/packages/babylon/test/fixtures/core/uncategorised/314/actual.js new file mode 100644 index 0000000000..46c1a5021f --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/314/actual.js @@ -0,0 +1,2 @@ +{ throw error// Comment +error; } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/314/expected.json b/packages/babylon/test/fixtures/core/uncategorised/314/expected.json new file mode 100644 index 0000000000..83b1e30f9e --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/314/expected.json @@ -0,0 +1,84 @@ +{ + "type": "Program", + "body": [ + { + "type": "BlockStatement", + "body": [ + { + "type": "ThrowStatement", + "argument": { + "type": "Identifier", + "name": "error", + "loc": { + "start": { + "line": 1, + "column": 8 + }, + "end": { + "line": 1, + "column": 13 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 2 + }, + "end": { + "line": 1, + "column": 13 + } + } + }, + { + "type": "ExpressionStatement", + "expression": { + "type": "Identifier", + "name": "error", + "loc": { + "start": { + "line": 2, + "column": 0 + }, + "end": { + "line": 2, + "column": 5 + } + } + }, + "loc": { + "start": { + "line": 2, + "column": 0 + }, + "end": { + "line": 2, + "column": 6 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 2, + "column": 8 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 2, + "column": 8 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/315/actual.js b/packages/babylon/test/fixtures/core/uncategorised/315/actual.js new file mode 100644 index 0000000000..21b8c27ab5 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/315/actual.js @@ -0,0 +1,2 @@ +{ throw error/* Multiline +Comment */error; } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/315/expected.json b/packages/babylon/test/fixtures/core/uncategorised/315/expected.json new file mode 100644 index 0000000000..d56eea3cd0 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/315/expected.json @@ -0,0 +1,84 @@ +{ + "type": "Program", + "body": [ + { + "type": "BlockStatement", + "body": [ + { + "type": "ThrowStatement", + "argument": { + "type": "Identifier", + "name": "error", + "loc": { + "start": { + "line": 1, + "column": 8 + }, + "end": { + "line": 1, + "column": 13 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 2 + }, + "end": { + "line": 1, + "column": 13 + } + } + }, + { + "type": "ExpressionStatement", + "expression": { + "type": "Identifier", + "name": "error", + "loc": { + "start": { + "line": 2, + "column": 10 + }, + "end": { + "line": 2, + "column": 15 + } + } + }, + "loc": { + "start": { + "line": 2, + "column": 10 + }, + "end": { + "line": 2, + "column": 16 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 2, + "column": 18 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 2, + "column": 18 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/316/actual.js b/packages/babylon/test/fixtures/core/uncategorised/316/actual.js new file mode 100644 index 0000000000..e69de29bb2 diff --git a/packages/babylon/test/fixtures/core/uncategorised/316/expected.json b/packages/babylon/test/fixtures/core/uncategorised/316/expected.json new file mode 100644 index 0000000000..6605671082 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/316/expected.json @@ -0,0 +1,14 @@ +{ + "type": "Program", + "body": [], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 0 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/317/actual.js b/packages/babylon/test/fixtures/core/uncategorised/317/actual.js new file mode 100644 index 0000000000..98aa78f179 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/317/actual.js @@ -0,0 +1 @@ +foo: if (true) break foo; \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/317/expected.json b/packages/babylon/test/fixtures/core/uncategorised/317/expected.json new file mode 100644 index 0000000000..58ab24f1dd --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/317/expected.json @@ -0,0 +1,97 @@ +{ + "type": "Program", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 25 + } + }, + "body": [ + { + "type": "LabeledStatement", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 25 + } + }, + "body": { + "type": "IfStatement", + "loc": { + "start": { + "line": 1, + "column": 5 + }, + "end": { + "line": 1, + "column": 25 + } + }, + "test": { + "type": "Literal", + "loc": { + "start": { + "line": 1, + "column": 9 + }, + "end": { + "line": 1, + "column": 13 + } + }, + "value": true + }, + "consequent": { + "type": "BreakStatement", + "loc": { + "start": { + "line": 1, + "column": 15 + }, + "end": { + "line": 1, + "column": 25 + } + }, + "label": { + "type": "Identifier", + "loc": { + "start": { + "line": 1, + "column": 21 + }, + "end": { + "line": 1, + "column": 24 + } + }, + "name": "foo" + } + }, + "alternate": null + }, + "label": { + "type": "Identifier", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 3 + } + }, + "name": "foo" + } + } + ] +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/318/actual.js b/packages/babylon/test/fixtures/core/uncategorised/318/actual.js new file mode 100644 index 0000000000..56dc3180f6 Binary files /dev/null and b/packages/babylon/test/fixtures/core/uncategorised/318/actual.js differ diff --git a/packages/babylon/test/fixtures/core/uncategorised/318/expected.json b/packages/babylon/test/fixtures/core/uncategorised/318/expected.json new file mode 100644 index 0000000000..d0c2574676 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/318/expected.json @@ -0,0 +1,126 @@ +{ + "type": "Program", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 4, + "column": 4 + } + }, + "body": [ + { + "type": "ExpressionStatement", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 4, + "column": 4 + } + }, + "expression": { + "type": "CallExpression", + "loc": { + "start": { + "line": 1, + "column": 1 + }, + "end": { + "line": 4, + "column": 3 + } + }, + "callee": { + "type": "FunctionExpression", + "loc": { + "start": { + "line": 1, + "column": 1 + }, + "end": { + "line": 4, + "column": 1 + } + }, + "id": null, + "params": [], + "body": { + "type": "BlockStatement", + "loc": { + "start": { + "line": 1, + "column": 13 + }, + "end": { + "line": 4, + "column": 1 + } + }, + "body": [ + { + "type": "ExpressionStatement", + "loc": { + "start": { + "line": 2, + "column": 1 + }, + "end": { + "line": 2, + "column": 14 + } + }, + "expression": { + "type": "Literal", + "loc": { + "start": { + "line": 2, + "column": 1 + }, + "end": { + "line": 2, + "column": 13 + } + }, + "value": "use strict" + } + }, + { + "type": "ExpressionStatement", + "loc": { + "start": { + "line": 3, + "column": 1 + }, + "end": { + "line": 3, + "column": 5 + } + }, + "expression": { + "type": "Literal", + "loc": { + "start": { + "line": 3, + "column": 1 + }, + "end": { + "line": 3, + "column": 4 + } + }, + "value": "\u0000" + } + } + ] + } + }, + "arguments": [] + } + } + ] +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/319/actual.js b/packages/babylon/test/fixtures/core/uncategorised/319/actual.js new file mode 100644 index 0000000000..ece7de1ea6 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/319/actual.js @@ -0,0 +1 @@ +123..toString(10) \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/319/expected.json b/packages/babylon/test/fixtures/core/uncategorised/319/expected.json new file mode 100644 index 0000000000..420ac0a7e5 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/319/expected.json @@ -0,0 +1,29 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "CallExpression", + "callee": { + "type": "MemberExpression", + "object": { + "type": "Literal", + "value": 123 + }, + "property": { + "type": "Identifier", + "name": "toString" + }, + "computed": false + }, + "arguments": [ + { + "type": "Literal", + "value": 10 + } + ] + } + } + ] +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/32/actual.js b/packages/babylon/test/fixtures/core/uncategorised/32/actual.js new file mode 100644 index 0000000000..d1eebe34eb --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/32/actual.js @@ -0,0 +1 @@ +x = { get true() {} } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/32/expected.json b/packages/babylon/test/fixtures/core/uncategorised/32/expected.json new file mode 100644 index 0000000000..298a4d14dd --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/32/expected.json @@ -0,0 +1,118 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "AssignmentExpression", + "operator": "=", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "right": { + "type": "ObjectExpression", + "properties": [ + { + "type": "Property", + "key": { + "type": "Identifier", + "name": "true", + "loc": { + "start": { + "line": 1, + "column": 10 + }, + "end": { + "line": 1, + "column": 14 + } + } + }, + "kind": "get", + "value": { + "type": "FunctionExpression", + "id": null, + "params": [], + "body": { + "type": "BlockStatement", + "body": [], + "loc": { + "start": { + "line": 1, + "column": 17 + }, + "end": { + "line": 1, + "column": 19 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 14 + }, + "end": { + "line": 1, + "column": 19 + } + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 21 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 21 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 21 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 21 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/320/actual.js b/packages/babylon/test/fixtures/core/uncategorised/320/actual.js new file mode 100644 index 0000000000..5932e46314 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/320/actual.js @@ -0,0 +1 @@ +123.+2 \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/320/expected.json b/packages/babylon/test/fixtures/core/uncategorised/320/expected.json new file mode 100644 index 0000000000..0a80f897a3 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/320/expected.json @@ -0,0 +1,20 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "BinaryExpression", + "left": { + "type": "Literal", + "value": 123 + }, + "operator": "+", + "right": { + "type": "Literal", + "value": 2 + } + } + } + ] +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/321/actual.js b/packages/babylon/test/fixtures/core/uncategorised/321/actual.js new file mode 100644 index 0000000000..86a40e71e8 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/321/actual.js @@ -0,0 +1 @@ +a
b \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/321/expected.json b/packages/babylon/test/fixtures/core/uncategorised/321/expected.json new file mode 100644 index 0000000000..4ee9db8038 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/321/expected.json @@ -0,0 +1,19 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "Identifier", + "name": "a" + } + }, + { + "type": "ExpressionStatement", + "expression": { + "type": "Identifier", + "name": "b" + } + } + ] +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/322/actual.js b/packages/babylon/test/fixtures/core/uncategorised/322/actual.js new file mode 100644 index 0000000000..5d518f2551 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/322/actual.js @@ -0,0 +1 @@ +'a\u0026b' \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/322/expected.json b/packages/babylon/test/fixtures/core/uncategorised/322/expected.json new file mode 100644 index 0000000000..93d210e45d --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/322/expected.json @@ -0,0 +1,12 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "Literal", + "value": "a&b" + } + } + ] +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/323/actual.js b/packages/babylon/test/fixtures/core/uncategorised/323/actual.js new file mode 100644 index 0000000000..b406f6d7d7 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/323/actual.js @@ -0,0 +1 @@ +foo: 10; foo: 20; \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/323/expected.json b/packages/babylon/test/fixtures/core/uncategorised/323/expected.json new file mode 100644 index 0000000000..7229089d51 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/323/expected.json @@ -0,0 +1,35 @@ +{ + "type": "Program", + "body": [ + { + "type": "LabeledStatement", + "body": { + "type": "ExpressionStatement", + "expression": { + "type": "Literal", + "value": 10, + "raw": "10" + } + }, + "label": { + "type": "Identifier", + "name": "foo" + } + }, + { + "type": "LabeledStatement", + "body": { + "type": "ExpressionStatement", + "expression": { + "type": "Literal", + "value": 20, + "raw": "20" + } + }, + "label": { + "type": "Identifier", + "name": "foo" + } + } + ] +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/324/actual.js b/packages/babylon/test/fixtures/core/uncategorised/324/actual.js new file mode 100644 index 0000000000..63d6f3d9ea --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/324/actual.js @@ -0,0 +1 @@ +if(1)/ foo/ \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/324/expected.json b/packages/babylon/test/fixtures/core/uncategorised/324/expected.json new file mode 100644 index 0000000000..6970b65879 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/324/expected.json @@ -0,0 +1,21 @@ +{ + "type": "Program", + "body": [ + { + "type": "IfStatement", + "test": { + "type": "Literal", + "value": 1, + "raw": "1" + }, + "consequent": { + "type": "ExpressionStatement", + "expression": { + "type": "Literal", + "raw": "/ foo/" + } + }, + "alternate": null + } + ] +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/325/actual.js b/packages/babylon/test/fixtures/core/uncategorised/325/actual.js new file mode 100644 index 0000000000..01c94c4f7f --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/325/actual.js @@ -0,0 +1 @@ +price_9̶9̶_89 \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/325/expected.json b/packages/babylon/test/fixtures/core/uncategorised/325/expected.json new file mode 100644 index 0000000000..66714d2adf --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/325/expected.json @@ -0,0 +1,12 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "Identifier", + "name": "price_9̶9̶_89" + } + } + ] +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/326/actual.js b/packages/babylon/test/fixtures/core/uncategorised/326/actual.js new file mode 100644 index 0000000000..327addc1de --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/326/actual.js @@ -0,0 +1 @@ +a.in / b \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/326/expected.json b/packages/babylon/test/fixtures/core/uncategorised/326/expected.json new file mode 100644 index 0000000000..4fb2fc4901 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/326/expected.json @@ -0,0 +1,28 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "BinaryExpression", + "left": { + "type": "MemberExpression", + "object": { + "type": "Identifier", + "name": "a" + }, + "property": { + "type": "Identifier", + "name": "in" + }, + "computed": false + }, + "operator": "/", + "right": { + "type": "Identifier", + "name": "b" + } + } + } + ] +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/327/actual.js b/packages/babylon/test/fixtures/core/uncategorised/327/actual.js new file mode 100644 index 0000000000..6f465a9b08 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/327/actual.js @@ -0,0 +1 @@ +return {} / 2 \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/327/expected.json b/packages/babylon/test/fixtures/core/uncategorised/327/expected.json new file mode 100644 index 0000000000..9e26dfeeb6 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/327/expected.json @@ -0,0 +1 @@ +{} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/327/options.json b/packages/babylon/test/fixtures/core/uncategorised/327/options.json new file mode 100644 index 0000000000..85f061e80b --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/327/options.json @@ -0,0 +1,3 @@ +{ + "allowReturnOutsideFunction": true +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/328/actual.js b/packages/babylon/test/fixtures/core/uncategorised/328/actual.js new file mode 100644 index 0000000000..b5ac87b945 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/328/actual.js @@ -0,0 +1,3 @@ +return +{} +/foo/ \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/328/expected.json b/packages/babylon/test/fixtures/core/uncategorised/328/expected.json new file mode 100644 index 0000000000..9e26dfeeb6 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/328/expected.json @@ -0,0 +1 @@ +{} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/328/options.json b/packages/babylon/test/fixtures/core/uncategorised/328/options.json new file mode 100644 index 0000000000..85f061e80b --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/328/options.json @@ -0,0 +1,3 @@ +{ + "allowReturnOutsideFunction": true +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/329/actual.js b/packages/babylon/test/fixtures/core/uncategorised/329/actual.js new file mode 100644 index 0000000000..3bc2feca57 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/329/actual.js @@ -0,0 +1 @@ ++{} / 2 \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/329/expected.json b/packages/babylon/test/fixtures/core/uncategorised/329/expected.json new file mode 100644 index 0000000000..9e26dfeeb6 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/329/expected.json @@ -0,0 +1 @@ +{} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/33/actual.js b/packages/babylon/test/fixtures/core/uncategorised/33/actual.js new file mode 100644 index 0000000000..bfdd86e7bc --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/33/actual.js @@ -0,0 +1 @@ +x = { get false() {} } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/33/expected.json b/packages/babylon/test/fixtures/core/uncategorised/33/expected.json new file mode 100644 index 0000000000..1570064db1 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/33/expected.json @@ -0,0 +1,118 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "AssignmentExpression", + "operator": "=", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "right": { + "type": "ObjectExpression", + "properties": [ + { + "type": "Property", + "key": { + "type": "Identifier", + "name": "false", + "loc": { + "start": { + "line": 1, + "column": 10 + }, + "end": { + "line": 1, + "column": 15 + } + } + }, + "kind": "get", + "value": { + "type": "FunctionExpression", + "id": null, + "params": [], + "body": { + "type": "BlockStatement", + "body": [], + "loc": { + "start": { + "line": 1, + "column": 18 + }, + "end": { + "line": 1, + "column": 20 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 15 + }, + "end": { + "line": 1, + "column": 20 + } + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 22 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 22 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 22 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 22 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/330/actual.js b/packages/babylon/test/fixtures/core/uncategorised/330/actual.js new file mode 100644 index 0000000000..51a1c56d5b --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/330/actual.js @@ -0,0 +1,2 @@ +{} +/foo/ \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/330/expected.json b/packages/babylon/test/fixtures/core/uncategorised/330/expected.json new file mode 100644 index 0000000000..9e26dfeeb6 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/330/expected.json @@ -0,0 +1 @@ +{} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/331/actual.js b/packages/babylon/test/fixtures/core/uncategorised/331/actual.js new file mode 100644 index 0000000000..5944632ee9 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/331/actual.js @@ -0,0 +1,3 @@ +x++ +{} +/foo/ \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/331/expected.json b/packages/babylon/test/fixtures/core/uncategorised/331/expected.json new file mode 100644 index 0000000000..9e26dfeeb6 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/331/expected.json @@ -0,0 +1 @@ +{} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/332/actual.js b/packages/babylon/test/fixtures/core/uncategorised/332/actual.js new file mode 100644 index 0000000000..7230d15ccb --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/332/actual.js @@ -0,0 +1,2 @@ +{{} +/foo/} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/332/expected.json b/packages/babylon/test/fixtures/core/uncategorised/332/expected.json new file mode 100644 index 0000000000..9e26dfeeb6 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/332/expected.json @@ -0,0 +1 @@ +{} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/333/actual.js b/packages/babylon/test/fixtures/core/uncategorised/333/actual.js new file mode 100644 index 0000000000..609fe2c973 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/333/actual.js @@ -0,0 +1 @@ +while (1) /foo/ \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/333/expected.json b/packages/babylon/test/fixtures/core/uncategorised/333/expected.json new file mode 100644 index 0000000000..9e26dfeeb6 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/333/expected.json @@ -0,0 +1 @@ +{} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/334/actual.js b/packages/babylon/test/fixtures/core/uncategorised/334/actual.js new file mode 100644 index 0000000000..514d730235 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/334/actual.js @@ -0,0 +1 @@ +(1) / 2 \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/334/expected.json b/packages/babylon/test/fixtures/core/uncategorised/334/expected.json new file mode 100644 index 0000000000..9e26dfeeb6 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/334/expected.json @@ -0,0 +1 @@ +{} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/335/actual.js b/packages/babylon/test/fixtures/core/uncategorised/335/actual.js new file mode 100644 index 0000000000..d708d3cc3c --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/335/actual.js @@ -0,0 +1 @@ +({a: [1]}+[]) / 2 \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/335/expected.json b/packages/babylon/test/fixtures/core/uncategorised/335/expected.json new file mode 100644 index 0000000000..9e26dfeeb6 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/335/expected.json @@ -0,0 +1 @@ +{} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/336/actual.js b/packages/babylon/test/fixtures/core/uncategorised/336/actual.js new file mode 100644 index 0000000000..93b003cc91 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/336/actual.js @@ -0,0 +1,2 @@ +{[1]} +/foo/ \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/336/expected.json b/packages/babylon/test/fixtures/core/uncategorised/336/expected.json new file mode 100644 index 0000000000..9e26dfeeb6 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/336/expected.json @@ -0,0 +1 @@ +{} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/337/actual.js b/packages/babylon/test/fixtures/core/uncategorised/337/actual.js new file mode 100644 index 0000000000..26e9f20296 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/337/actual.js @@ -0,0 +1,2 @@ +switch(a) { case 1: {} +/foo/ } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/337/expected.json b/packages/babylon/test/fixtures/core/uncategorised/337/expected.json new file mode 100644 index 0000000000..9e26dfeeb6 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/337/expected.json @@ -0,0 +1 @@ +{} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/338/actual.js b/packages/babylon/test/fixtures/core/uncategorised/338/actual.js new file mode 100644 index 0000000000..d7c1cb00eb --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/338/actual.js @@ -0,0 +1 @@ +({1: {} / 2}) \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/338/expected.json b/packages/babylon/test/fixtures/core/uncategorised/338/expected.json new file mode 100644 index 0000000000..9e26dfeeb6 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/338/expected.json @@ -0,0 +1 @@ +{} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/339/actual.js b/packages/babylon/test/fixtures/core/uncategorised/339/actual.js new file mode 100644 index 0000000000..979d53f02f --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/339/actual.js @@ -0,0 +1 @@ ++x++ / 2 \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/339/expected.json b/packages/babylon/test/fixtures/core/uncategorised/339/expected.json new file mode 100644 index 0000000000..9e26dfeeb6 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/339/expected.json @@ -0,0 +1 @@ +{} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/34/actual.js b/packages/babylon/test/fixtures/core/uncategorised/34/actual.js new file mode 100644 index 0000000000..11f3416e4d --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/34/actual.js @@ -0,0 +1 @@ +x = { get null() {} } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/34/expected.json b/packages/babylon/test/fixtures/core/uncategorised/34/expected.json new file mode 100644 index 0000000000..21c70541de --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/34/expected.json @@ -0,0 +1,118 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "AssignmentExpression", + "operator": "=", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "right": { + "type": "ObjectExpression", + "properties": [ + { + "type": "Property", + "key": { + "type": "Identifier", + "name": "null", + "loc": { + "start": { + "line": 1, + "column": 10 + }, + "end": { + "line": 1, + "column": 14 + } + } + }, + "kind": "get", + "value": { + "type": "FunctionExpression", + "id": null, + "params": [], + "body": { + "type": "BlockStatement", + "body": [], + "loc": { + "start": { + "line": 1, + "column": 17 + }, + "end": { + "line": 1, + "column": 19 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 14 + }, + "end": { + "line": 1, + "column": 19 + } + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 21 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 21 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 21 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 21 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/340/actual.js b/packages/babylon/test/fixtures/core/uncategorised/340/actual.js new file mode 100644 index 0000000000..5c11416be2 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/340/actual.js @@ -0,0 +1,3 @@ +foo.in +{} +/foo/ \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/340/expected.json b/packages/babylon/test/fixtures/core/uncategorised/340/expected.json new file mode 100644 index 0000000000..9e26dfeeb6 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/340/expected.json @@ -0,0 +1 @@ +{} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/341/actual.js b/packages/babylon/test/fixtures/core/uncategorised/341/actual.js new file mode 100644 index 0000000000..7f707c1d13 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/341/actual.js @@ -0,0 +1 @@ +{}/=/ \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/341/expected.json b/packages/babylon/test/fixtures/core/uncategorised/341/expected.json new file mode 100644 index 0000000000..a6bce01434 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/341/expected.json @@ -0,0 +1,16 @@ +{ + "type": "Program", + "body": [ + { + "type": "BlockStatement", + "body": [] + }, + { + "type": "ExpressionStatement", + "expression": { + "type": "Literal", + "raw": "/=/" + } + } + ] +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/342/actual.js b/packages/babylon/test/fixtures/core/uncategorised/342/actual.js new file mode 100644 index 0000000000..0a57b3e831 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/342/actual.js @@ -0,0 +1,2 @@ +foo 10; + --> nothing \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/343/expected.json b/packages/babylon/test/fixtures/core/uncategorised/343/expected.json new file mode 100644 index 0000000000..d6c7a2b209 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/343/expected.json @@ -0,0 +1,33 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "AssignmentExpression", + "operator": "=", + "left": { + "type": "Identifier", + "name": "x" + }, + "right": { + "type": "BinaryExpression", + "left": { + "type": "UpdateExpression", + "operator": "--", + "prefix": false, + "argument": { + "type": "Identifier", + "name": "y" + } + }, + "operator": ">", + "right": { + "type": "Literal", + "value": 10 + } + } + } + } + ] +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/344/actual.js b/packages/babylon/test/fixtures/core/uncategorised/344/actual.js new file mode 100644 index 0000000000..fde231178f --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/344/actual.js @@ -0,0 +1,2 @@ +'use strict'; +object.static(); \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/344/expected.json b/packages/babylon/test/fixtures/core/uncategorised/344/expected.json new file mode 100644 index 0000000000..43d34396f7 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/344/expected.json @@ -0,0 +1,32 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "Literal", + "value": "use strict", + "raw": "'use strict'" + } + }, + { + "type": "ExpressionStatement", + "expression": { + "type": "CallExpression", + "callee": { + "type": "MemberExpression", + "object": { + "type": "Identifier", + "name": "object" + }, + "property": { + "type": "Identifier", + "name": "static" + }, + "computed": false + }, + "arguments": [] + } + } + ] +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/345/actual.js b/packages/babylon/test/fixtures/core/uncategorised/345/actual.js new file mode 100644 index 0000000000..81750b96f9 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/345/actual.js @@ -0,0 +1 @@ +{ \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/345/options.json b/packages/babylon/test/fixtures/core/uncategorised/345/options.json new file mode 100644 index 0000000000..04b967a2ee --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/345/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unexpected token (1:1)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/346/actual.js b/packages/babylon/test/fixtures/core/uncategorised/346/actual.js new file mode 100644 index 0000000000..ff30235f07 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/346/actual.js @@ -0,0 +1 @@ +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/346/options.json b/packages/babylon/test/fixtures/core/uncategorised/346/options.json new file mode 100644 index 0000000000..919c05ec87 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/346/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unexpected token (1:0)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/347/actual.js b/packages/babylon/test/fixtures/core/uncategorised/347/actual.js new file mode 100644 index 0000000000..74f6857fa1 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/347/actual.js @@ -0,0 +1 @@ +3ea \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/347/options.json b/packages/babylon/test/fixtures/core/uncategorised/347/options.json new file mode 100644 index 0000000000..cf3086295c --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/347/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Invalid number (1:0)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/348/actual.js b/packages/babylon/test/fixtures/core/uncategorised/348/actual.js new file mode 100644 index 0000000000..d72fce0408 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/348/actual.js @@ -0,0 +1 @@ +3in [] \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/348/options.json b/packages/babylon/test/fixtures/core/uncategorised/348/options.json new file mode 100644 index 0000000000..b239abb159 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/348/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Identifier directly after number (1:1)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/349/actual.js b/packages/babylon/test/fixtures/core/uncategorised/349/actual.js new file mode 100644 index 0000000000..42bd7f5582 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/349/actual.js @@ -0,0 +1 @@ +3e \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/349/options.json b/packages/babylon/test/fixtures/core/uncategorised/349/options.json new file mode 100644 index 0000000000..cf3086295c --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/349/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Invalid number (1:0)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/35/actual.js b/packages/babylon/test/fixtures/core/uncategorised/35/actual.js new file mode 100644 index 0000000000..6b2adc2768 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/35/actual.js @@ -0,0 +1 @@ +x = { get "undef"() {} } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/35/expected.json b/packages/babylon/test/fixtures/core/uncategorised/35/expected.json new file mode 100644 index 0000000000..79053d1df8 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/35/expected.json @@ -0,0 +1,118 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "AssignmentExpression", + "operator": "=", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "right": { + "type": "ObjectExpression", + "properties": [ + { + "type": "Property", + "key": { + "type": "Literal", + "value": "undef", + "loc": { + "start": { + "line": 1, + "column": 10 + }, + "end": { + "line": 1, + "column": 17 + } + } + }, + "kind": "get", + "value": { + "type": "FunctionExpression", + "id": null, + "params": [], + "body": { + "type": "BlockStatement", + "body": [], + "loc": { + "start": { + "line": 1, + "column": 20 + }, + "end": { + "line": 1, + "column": 22 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 17 + }, + "end": { + "line": 1, + "column": 22 + } + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 24 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 24 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 24 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 24 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/350/actual.js b/packages/babylon/test/fixtures/core/uncategorised/350/actual.js new file mode 100644 index 0000000000..587c30758b --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/350/actual.js @@ -0,0 +1 @@ +3e+ \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/350/options.json b/packages/babylon/test/fixtures/core/uncategorised/350/options.json new file mode 100644 index 0000000000..cf3086295c --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/350/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Invalid number (1:0)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/351/actual.js b/packages/babylon/test/fixtures/core/uncategorised/351/actual.js new file mode 100644 index 0000000000..5af2393b8b --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/351/actual.js @@ -0,0 +1 @@ +3e- \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/351/options.json b/packages/babylon/test/fixtures/core/uncategorised/351/options.json new file mode 100644 index 0000000000..cf3086295c --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/351/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Invalid number (1:0)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/352/actual.js b/packages/babylon/test/fixtures/core/uncategorised/352/actual.js new file mode 100644 index 0000000000..ccd6e8857d --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/352/actual.js @@ -0,0 +1 @@ +3x \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/352/options.json b/packages/babylon/test/fixtures/core/uncategorised/352/options.json new file mode 100644 index 0000000000..b239abb159 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/352/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Identifier directly after number (1:1)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/353/actual.js b/packages/babylon/test/fixtures/core/uncategorised/353/actual.js new file mode 100644 index 0000000000..2c08018993 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/353/actual.js @@ -0,0 +1 @@ +3x0 \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/353/options.json b/packages/babylon/test/fixtures/core/uncategorised/353/options.json new file mode 100644 index 0000000000..b239abb159 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/353/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Identifier directly after number (1:1)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/354/actual.js b/packages/babylon/test/fixtures/core/uncategorised/354/actual.js new file mode 100644 index 0000000000..99e07d0f06 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/354/actual.js @@ -0,0 +1 @@ +0x \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/354/options.json b/packages/babylon/test/fixtures/core/uncategorised/354/options.json new file mode 100644 index 0000000000..b4716df8c6 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/354/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Expected number in radix 16 (1:2)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/355/actual.js b/packages/babylon/test/fixtures/core/uncategorised/355/actual.js new file mode 100644 index 0000000000..aa2f0b2695 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/355/actual.js @@ -0,0 +1 @@ +09 \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/355/options.json b/packages/babylon/test/fixtures/core/uncategorised/355/options.json new file mode 100644 index 0000000000..cf3086295c --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/355/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Invalid number (1:0)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/356/actual.js b/packages/babylon/test/fixtures/core/uncategorised/356/actual.js new file mode 100644 index 0000000000..b78f2ecbf7 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/356/actual.js @@ -0,0 +1 @@ +018 \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/356/options.json b/packages/babylon/test/fixtures/core/uncategorised/356/options.json new file mode 100644 index 0000000000..cf3086295c --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/356/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Invalid number (1:0)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/357/actual.js b/packages/babylon/test/fixtures/core/uncategorised/357/actual.js new file mode 100644 index 0000000000..adc4228b3b --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/357/actual.js @@ -0,0 +1 @@ +01a \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/357/options.json b/packages/babylon/test/fixtures/core/uncategorised/357/options.json new file mode 100644 index 0000000000..aa61ff56c2 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/357/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Identifier directly after number (1:2)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/358/actual.js b/packages/babylon/test/fixtures/core/uncategorised/358/actual.js new file mode 100644 index 0000000000..38f8bb7192 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/358/actual.js @@ -0,0 +1 @@ +3in[] \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/358/options.json b/packages/babylon/test/fixtures/core/uncategorised/358/options.json new file mode 100644 index 0000000000..b239abb159 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/358/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Identifier directly after number (1:1)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/359/actual.js b/packages/babylon/test/fixtures/core/uncategorised/359/actual.js new file mode 100644 index 0000000000..6673c561ef --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/359/actual.js @@ -0,0 +1 @@ +0x3in[] \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/359/options.json b/packages/babylon/test/fixtures/core/uncategorised/359/options.json new file mode 100644 index 0000000000..f42de64632 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/359/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Identifier directly after number (1:3)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/36/actual.js b/packages/babylon/test/fixtures/core/uncategorised/36/actual.js new file mode 100644 index 0000000000..a4b31f7f4b --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/36/actual.js @@ -0,0 +1 @@ +x = { get 10() {} } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/36/expected.json b/packages/babylon/test/fixtures/core/uncategorised/36/expected.json new file mode 100644 index 0000000000..3eda42d065 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/36/expected.json @@ -0,0 +1,118 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "AssignmentExpression", + "operator": "=", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "right": { + "type": "ObjectExpression", + "properties": [ + { + "type": "Property", + "key": { + "type": "Literal", + "value": 10, + "loc": { + "start": { + "line": 1, + "column": 10 + }, + "end": { + "line": 1, + "column": 12 + } + } + }, + "kind": "get", + "value": { + "type": "FunctionExpression", + "id": null, + "params": [], + "body": { + "type": "BlockStatement", + "body": [], + "loc": { + "start": { + "line": 1, + "column": 15 + }, + "end": { + "line": 1, + "column": 17 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 12 + }, + "end": { + "line": 1, + "column": 17 + } + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 19 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 19 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 19 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 19 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/360/actual.js b/packages/babylon/test/fixtures/core/uncategorised/360/actual.js new file mode 100644 index 0000000000..cc392622e1 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/360/actual.js @@ -0,0 +1,2 @@ +"Hello +World" \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/360/options.json b/packages/babylon/test/fixtures/core/uncategorised/360/options.json new file mode 100644 index 0000000000..a760565b1b --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/360/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unterminated string constant (1:0)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/361/actual.js b/packages/babylon/test/fixtures/core/uncategorised/361/actual.js new file mode 100644 index 0000000000..08eb2e095a --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/361/actual.js @@ -0,0 +1 @@ +x\ \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/361/options.json b/packages/babylon/test/fixtures/core/uncategorised/361/options.json new file mode 100644 index 0000000000..d08f66903c --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/361/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Expecting Unicode escape sequence \\uXXXX (1:2)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/362/actual.js b/packages/babylon/test/fixtures/core/uncategorised/362/actual.js new file mode 100644 index 0000000000..8ee1fc18c0 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/362/actual.js @@ -0,0 +1 @@ +x\u005c \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/362/options.json b/packages/babylon/test/fixtures/core/uncategorised/362/options.json new file mode 100644 index 0000000000..cd0024d9d9 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/362/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Invalid Unicode escape (1:1)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/363/actual.js b/packages/babylon/test/fixtures/core/uncategorised/363/actual.js new file mode 100644 index 0000000000..618be385ee --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/363/actual.js @@ -0,0 +1 @@ +x\u002a \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/363/options.json b/packages/babylon/test/fixtures/core/uncategorised/363/options.json new file mode 100644 index 0000000000..cd0024d9d9 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/363/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Invalid Unicode escape (1:1)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/364/actual.js b/packages/babylon/test/fixtures/core/uncategorised/364/actual.js new file mode 100644 index 0000000000..35ec3b9d75 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/364/actual.js @@ -0,0 +1 @@ +/ \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/364/options.json b/packages/babylon/test/fixtures/core/uncategorised/364/options.json new file mode 100644 index 0000000000..e07b72599f --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/364/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unterminated regular expression (1:1)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/365/actual.js b/packages/babylon/test/fixtures/core/uncategorised/365/actual.js new file mode 100644 index 0000000000..32bcdf1ac6 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/365/actual.js @@ -0,0 +1 @@ +/test \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/365/options.json b/packages/babylon/test/fixtures/core/uncategorised/365/options.json new file mode 100644 index 0000000000..e07b72599f --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/365/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unterminated regular expression (1:1)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/366/actual.js b/packages/babylon/test/fixtures/core/uncategorised/366/actual.js new file mode 100644 index 0000000000..924bc2b300 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/366/actual.js @@ -0,0 +1 @@ +var x = /[a-z]/\ux \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/366/options.json b/packages/babylon/test/fixtures/core/uncategorised/366/options.json new file mode 100644 index 0000000000..cd4fc8b6bd --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/366/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Bad character escape sequence (1:17)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/367/actual.js b/packages/babylon/test/fixtures/core/uncategorised/367/actual.js new file mode 100644 index 0000000000..f585591485 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/367/actual.js @@ -0,0 +1 @@ +3 = 4 \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/367/options.json b/packages/babylon/test/fixtures/core/uncategorised/367/options.json new file mode 100644 index 0000000000..de19a8ed39 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/367/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Assigning to rvalue (1:0)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/368/actual.js b/packages/babylon/test/fixtures/core/uncategorised/368/actual.js new file mode 100644 index 0000000000..88a4a1129a --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/368/actual.js @@ -0,0 +1 @@ +func() = 4 \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/368/options.json b/packages/babylon/test/fixtures/core/uncategorised/368/options.json new file mode 100644 index 0000000000..de19a8ed39 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/368/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Assigning to rvalue (1:0)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/369/actual.js b/packages/babylon/test/fixtures/core/uncategorised/369/actual.js new file mode 100644 index 0000000000..9ee7f11234 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/369/actual.js @@ -0,0 +1 @@ +(1 + 1) = 10 \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/369/options.json b/packages/babylon/test/fixtures/core/uncategorised/369/options.json new file mode 100644 index 0000000000..4d699b8b0c --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/369/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Assigning to rvalue (1:1)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/37/actual.js b/packages/babylon/test/fixtures/core/uncategorised/37/actual.js new file mode 100644 index 0000000000..195d9af705 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/37/actual.js @@ -0,0 +1 @@ +x = { set width(w) { m_width = w } } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/37/expected.json b/packages/babylon/test/fixtures/core/uncategorised/37/expected.json new file mode 100644 index 0000000000..ce48e303e1 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/37/expected.json @@ -0,0 +1,189 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "AssignmentExpression", + "operator": "=", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "right": { + "type": "ObjectExpression", + "properties": [ + { + "type": "Property", + "key": { + "type": "Identifier", + "name": "width", + "loc": { + "start": { + "line": 1, + "column": 10 + }, + "end": { + "line": 1, + "column": 15 + } + } + }, + "kind": "set", + "value": { + "type": "FunctionExpression", + "id": null, + "params": [ + { + "type": "Identifier", + "name": "w", + "loc": { + "start": { + "line": 1, + "column": 16 + }, + "end": { + "line": 1, + "column": 17 + } + } + } + ], + "body": { + "type": "BlockStatement", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "AssignmentExpression", + "operator": "=", + "left": { + "type": "Identifier", + "name": "m_width", + "loc": { + "start": { + "line": 1, + "column": 21 + }, + "end": { + "line": 1, + "column": 28 + } + } + }, + "right": { + "type": "Identifier", + "name": "w", + "loc": { + "start": { + "line": 1, + "column": 31 + }, + "end": { + "line": 1, + "column": 32 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 21 + }, + "end": { + "line": 1, + "column": 32 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 21 + }, + "end": { + "line": 1, + "column": 32 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 19 + }, + "end": { + "line": 1, + "column": 34 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 15 + }, + "end": { + "line": 1, + "column": 34 + } + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 36 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 36 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 36 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 36 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/370/actual.js b/packages/babylon/test/fixtures/core/uncategorised/370/actual.js new file mode 100644 index 0000000000..1c8af926bf --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/370/actual.js @@ -0,0 +1 @@ +1++ \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/370/options.json b/packages/babylon/test/fixtures/core/uncategorised/370/options.json new file mode 100644 index 0000000000..de19a8ed39 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/370/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Assigning to rvalue (1:0)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/371/actual.js b/packages/babylon/test/fixtures/core/uncategorised/371/actual.js new file mode 100644 index 0000000000..6a5ca8a328 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/371/actual.js @@ -0,0 +1 @@ +1-- \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/371/options.json b/packages/babylon/test/fixtures/core/uncategorised/371/options.json new file mode 100644 index 0000000000..de19a8ed39 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/371/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Assigning to rvalue (1:0)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/372/actual.js b/packages/babylon/test/fixtures/core/uncategorised/372/actual.js new file mode 100644 index 0000000000..e3bc4bd9b6 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/372/actual.js @@ -0,0 +1 @@ +++1 \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/372/options.json b/packages/babylon/test/fixtures/core/uncategorised/372/options.json new file mode 100644 index 0000000000..0b53e4963e --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/372/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Assigning to rvalue (1:2)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/373/actual.js b/packages/babylon/test/fixtures/core/uncategorised/373/actual.js new file mode 100644 index 0000000000..bfbbe2bf6a --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/373/actual.js @@ -0,0 +1 @@ +--1 \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/373/options.json b/packages/babylon/test/fixtures/core/uncategorised/373/options.json new file mode 100644 index 0000000000..0b53e4963e --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/373/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Assigning to rvalue (1:2)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/374/actual.js b/packages/babylon/test/fixtures/core/uncategorised/374/actual.js new file mode 100644 index 0000000000..1aed2d9997 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/374/actual.js @@ -0,0 +1 @@ +for((1 + 1) in list) process(x); \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/374/options.json b/packages/babylon/test/fixtures/core/uncategorised/374/options.json new file mode 100644 index 0000000000..85f6f01102 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/374/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Assigning to rvalue (1:5)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/375/actual.js b/packages/babylon/test/fixtures/core/uncategorised/375/actual.js new file mode 100644 index 0000000000..8e2f0bef13 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/375/actual.js @@ -0,0 +1 @@ +[ \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/375/options.json b/packages/babylon/test/fixtures/core/uncategorised/375/options.json new file mode 100644 index 0000000000..04b967a2ee --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/375/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unexpected token (1:1)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/376/actual.js b/packages/babylon/test/fixtures/core/uncategorised/376/actual.js new file mode 100644 index 0000000000..6295fdc36d --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/376/actual.js @@ -0,0 +1 @@ +[, \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/376/options.json b/packages/babylon/test/fixtures/core/uncategorised/376/options.json new file mode 100644 index 0000000000..e68fbb6aec --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/376/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unexpected token (1:2)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/377/actual.js b/packages/babylon/test/fixtures/core/uncategorised/377/actual.js new file mode 100644 index 0000000000..fb324a5cf3 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/377/actual.js @@ -0,0 +1 @@ +1 + { \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/377/options.json b/packages/babylon/test/fixtures/core/uncategorised/377/options.json new file mode 100644 index 0000000000..0ab445fe47 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/377/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unexpected token (1:5)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/378/actual.js b/packages/babylon/test/fixtures/core/uncategorised/378/actual.js new file mode 100644 index 0000000000..5518c1faaf --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/378/actual.js @@ -0,0 +1 @@ +1 + { t:t diff --git a/packages/babylon/test/fixtures/core/uncategorised/378/options.json b/packages/babylon/test/fixtures/core/uncategorised/378/options.json new file mode 100644 index 0000000000..2a28555f76 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/378/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unexpected token (1:9)" +} diff --git a/packages/babylon/test/fixtures/core/uncategorised/379/actual.js b/packages/babylon/test/fixtures/core/uncategorised/379/actual.js new file mode 100644 index 0000000000..91e132b46f --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/379/actual.js @@ -0,0 +1 @@ +1 + { t:t, \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/379/options.json b/packages/babylon/test/fixtures/core/uncategorised/379/options.json new file mode 100644 index 0000000000..328b1ddde8 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/379/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unexpected token (1:10)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/38/actual.js b/packages/babylon/test/fixtures/core/uncategorised/38/actual.js new file mode 100644 index 0000000000..5a84a53efe --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/38/actual.js @@ -0,0 +1 @@ +x = { set if(w) { m_if = w } } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/38/expected.json b/packages/babylon/test/fixtures/core/uncategorised/38/expected.json new file mode 100644 index 0000000000..d5018c2302 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/38/expected.json @@ -0,0 +1,189 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "AssignmentExpression", + "operator": "=", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "right": { + "type": "ObjectExpression", + "properties": [ + { + "type": "Property", + "key": { + "type": "Identifier", + "name": "if", + "loc": { + "start": { + "line": 1, + "column": 10 + }, + "end": { + "line": 1, + "column": 12 + } + } + }, + "kind": "set", + "value": { + "type": "FunctionExpression", + "id": null, + "params": [ + { + "type": "Identifier", + "name": "w", + "loc": { + "start": { + "line": 1, + "column": 13 + }, + "end": { + "line": 1, + "column": 14 + } + } + } + ], + "body": { + "type": "BlockStatement", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "AssignmentExpression", + "operator": "=", + "left": { + "type": "Identifier", + "name": "m_if", + "loc": { + "start": { + "line": 1, + "column": 18 + }, + "end": { + "line": 1, + "column": 22 + } + } + }, + "right": { + "type": "Identifier", + "name": "w", + "loc": { + "start": { + "line": 1, + "column": 25 + }, + "end": { + "line": 1, + "column": 26 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 18 + }, + "end": { + "line": 1, + "column": 26 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 18 + }, + "end": { + "line": 1, + "column": 26 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 16 + }, + "end": { + "line": 1, + "column": 28 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 12 + }, + "end": { + "line": 1, + "column": 28 + } + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 30 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 30 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 30 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 30 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/380/actual.js b/packages/babylon/test/fixtures/core/uncategorised/380/actual.js new file mode 100644 index 0000000000..8c4bbafc28 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/380/actual.js @@ -0,0 +1,2 @@ +var x = / +/ \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/380/options.json b/packages/babylon/test/fixtures/core/uncategorised/380/options.json new file mode 100644 index 0000000000..d5e4b52d5c --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/380/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unterminated regular expression (1:9)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/381/actual.js b/packages/babylon/test/fixtures/core/uncategorised/381/actual.js new file mode 100644 index 0000000000..66386204a9 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/381/actual.js @@ -0,0 +1 @@ +var x = " diff --git a/packages/babylon/test/fixtures/core/uncategorised/381/options.json b/packages/babylon/test/fixtures/core/uncategorised/381/options.json new file mode 100644 index 0000000000..78a668d16d --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/381/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unterminated string constant (1:8)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/382/actual.js b/packages/babylon/test/fixtures/core/uncategorised/382/actual.js new file mode 100644 index 0000000000..1f929174d2 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/382/actual.js @@ -0,0 +1 @@ +var if = 42 \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/382/options.json b/packages/babylon/test/fixtures/core/uncategorised/382/options.json new file mode 100644 index 0000000000..9f7910a413 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/382/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unexpected token (1:4)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/383/actual.js b/packages/babylon/test/fixtures/core/uncategorised/383/actual.js new file mode 100644 index 0000000000..dc8424ab98 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/383/actual.js @@ -0,0 +1 @@ +i + 2 = 42 \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/383/options.json b/packages/babylon/test/fixtures/core/uncategorised/383/options.json new file mode 100644 index 0000000000..de19a8ed39 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/383/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Assigning to rvalue (1:0)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/384/actual.js b/packages/babylon/test/fixtures/core/uncategorised/384/actual.js new file mode 100644 index 0000000000..71b4fc4700 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/384/actual.js @@ -0,0 +1 @@ ++i = 42 \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/384/options.json b/packages/babylon/test/fixtures/core/uncategorised/384/options.json new file mode 100644 index 0000000000..de19a8ed39 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/384/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Assigning to rvalue (1:0)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/385/actual.js b/packages/babylon/test/fixtures/core/uncategorised/385/actual.js new file mode 100644 index 0000000000..7c6a458d13 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/385/actual.js @@ -0,0 +1 @@ +1 + ( \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/385/options.json b/packages/babylon/test/fixtures/core/uncategorised/385/options.json new file mode 100644 index 0000000000..0ab445fe47 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/385/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unexpected token (1:5)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/386/actual.js b/packages/babylon/test/fixtures/core/uncategorised/386/actual.js new file mode 100644 index 0000000000..f820c95d89 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/386/actual.js @@ -0,0 +1,4 @@ + + + +{ \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/386/options.json b/packages/babylon/test/fixtures/core/uncategorised/386/options.json new file mode 100644 index 0000000000..476d7fff91 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/386/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unexpected token (4:1)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/387/actual.js b/packages/babylon/test/fixtures/core/uncategorised/387/actual.js new file mode 100644 index 0000000000..de71d5f6e0 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/387/actual.js @@ -0,0 +1,4 @@ + +/* Some multiline +comment */ +) \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/387/options.json b/packages/babylon/test/fixtures/core/uncategorised/387/options.json new file mode 100644 index 0000000000..62cf5da64b --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/387/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unexpected token (4:0)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/388/actual.js b/packages/babylon/test/fixtures/core/uncategorised/388/actual.js new file mode 100644 index 0000000000..0b86a72847 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/388/actual.js @@ -0,0 +1 @@ +{ set 1 } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/388/options.json b/packages/babylon/test/fixtures/core/uncategorised/388/options.json new file mode 100644 index 0000000000..515b971673 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/388/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unexpected token (1:6)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/389/actual.js b/packages/babylon/test/fixtures/core/uncategorised/389/actual.js new file mode 100644 index 0000000000..c4250ca114 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/389/actual.js @@ -0,0 +1 @@ +{ get 2 } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/389/options.json b/packages/babylon/test/fixtures/core/uncategorised/389/options.json new file mode 100644 index 0000000000..515b971673 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/389/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unexpected token (1:6)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/39/actual.js b/packages/babylon/test/fixtures/core/uncategorised/39/actual.js new file mode 100644 index 0000000000..9a2f22a04c --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/39/actual.js @@ -0,0 +1 @@ +x = { set true(w) { m_true = w } } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/39/expected.json b/packages/babylon/test/fixtures/core/uncategorised/39/expected.json new file mode 100644 index 0000000000..e6c3f5a308 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/39/expected.json @@ -0,0 +1,189 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "AssignmentExpression", + "operator": "=", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "right": { + "type": "ObjectExpression", + "properties": [ + { + "type": "Property", + "key": { + "type": "Identifier", + "name": "true", + "loc": { + "start": { + "line": 1, + "column": 10 + }, + "end": { + "line": 1, + "column": 14 + } + } + }, + "kind": "set", + "value": { + "type": "FunctionExpression", + "id": null, + "params": [ + { + "type": "Identifier", + "name": "w", + "loc": { + "start": { + "line": 1, + "column": 15 + }, + "end": { + "line": 1, + "column": 16 + } + } + } + ], + "body": { + "type": "BlockStatement", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "AssignmentExpression", + "operator": "=", + "left": { + "type": "Identifier", + "name": "m_true", + "loc": { + "start": { + "line": 1, + "column": 20 + }, + "end": { + "line": 1, + "column": 26 + } + } + }, + "right": { + "type": "Identifier", + "name": "w", + "loc": { + "start": { + "line": 1, + "column": 29 + }, + "end": { + "line": 1, + "column": 30 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 20 + }, + "end": { + "line": 1, + "column": 30 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 20 + }, + "end": { + "line": 1, + "column": 30 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 18 + }, + "end": { + "line": 1, + "column": 32 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 14 + }, + "end": { + "line": 1, + "column": 32 + } + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 34 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 34 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 34 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 34 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/390/actual.js b/packages/babylon/test/fixtures/core/uncategorised/390/actual.js new file mode 100644 index 0000000000..b96ae85fb2 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/390/actual.js @@ -0,0 +1 @@ +({ set: s(if) { } }) \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/390/options.json b/packages/babylon/test/fixtures/core/uncategorised/390/options.json new file mode 100644 index 0000000000..328b1ddde8 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/390/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unexpected token (1:10)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/391/actual.js b/packages/babylon/test/fixtures/core/uncategorised/391/actual.js new file mode 100644 index 0000000000..8dbf3e2b1e --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/391/actual.js @@ -0,0 +1 @@ +({ set s(.) { } }) \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/391/options.json b/packages/babylon/test/fixtures/core/uncategorised/391/options.json new file mode 100644 index 0000000000..93db7641c7 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/391/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unexpected token (1:9)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/392/actual.js b/packages/babylon/test/fixtures/core/uncategorised/392/actual.js new file mode 100644 index 0000000000..32ecb82f88 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/392/actual.js @@ -0,0 +1 @@ +({ set: s() { } }) \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/392/options.json b/packages/babylon/test/fixtures/core/uncategorised/392/options.json new file mode 100644 index 0000000000..358068a16a --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/392/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unexpected token (1:12)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/393/actual.js b/packages/babylon/test/fixtures/core/uncategorised/393/actual.js new file mode 100644 index 0000000000..6d70b15607 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/393/actual.js @@ -0,0 +1 @@ +({ set: s(a, b) { } }) \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/393/options.json b/packages/babylon/test/fixtures/core/uncategorised/393/options.json new file mode 100644 index 0000000000..89e36d9013 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/393/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unexpected token (1:16)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/394/actual.js b/packages/babylon/test/fixtures/core/uncategorised/394/actual.js new file mode 100644 index 0000000000..b1df4de03a --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/394/actual.js @@ -0,0 +1 @@ +({ get: g(d) { } }) \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/394/options.json b/packages/babylon/test/fixtures/core/uncategorised/394/options.json new file mode 100644 index 0000000000..27f6e27de8 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/394/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unexpected token (1:13)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/395/actual.js b/packages/babylon/test/fixtures/core/uncategorised/395/actual.js new file mode 100644 index 0000000000..ef525bd729 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/395/actual.js @@ -0,0 +1 @@ +function t(...) { } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/395/options.json b/packages/babylon/test/fixtures/core/uncategorised/395/options.json new file mode 100644 index 0000000000..51c483f3d3 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/395/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unexpected token (1:14)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/396/actual.js b/packages/babylon/test/fixtures/core/uncategorised/396/actual.js new file mode 100644 index 0000000000..9a10137a73 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/396/actual.js @@ -0,0 +1 @@ +function t(...rest, b) { } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/396/options.json b/packages/babylon/test/fixtures/core/uncategorised/396/options.json new file mode 100644 index 0000000000..2a73699bc2 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/396/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unexpected token (1:18)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/397/actual.js b/packages/babylon/test/fixtures/core/uncategorised/397/actual.js new file mode 100644 index 0000000000..9746c91113 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/397/actual.js @@ -0,0 +1 @@ +function t(if) { } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/397/options.json b/packages/babylon/test/fixtures/core/uncategorised/397/options.json new file mode 100644 index 0000000000..3e33f7730f --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/397/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unexpected token (1:11)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/398/actual.js b/packages/babylon/test/fixtures/core/uncategorised/398/actual.js new file mode 100644 index 0000000000..5ab609e681 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/398/actual.js @@ -0,0 +1 @@ +function t(true) { } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/398/options.json b/packages/babylon/test/fixtures/core/uncategorised/398/options.json new file mode 100644 index 0000000000..3e33f7730f --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/398/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unexpected token (1:11)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/399/actual.js b/packages/babylon/test/fixtures/core/uncategorised/399/actual.js new file mode 100644 index 0000000000..b126b597c1 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/399/actual.js @@ -0,0 +1 @@ +function t(false) { } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/399/options.json b/packages/babylon/test/fixtures/core/uncategorised/399/options.json new file mode 100644 index 0000000000..3e33f7730f --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/399/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unexpected token (1:11)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/4/actual.js b/packages/babylon/test/fixtures/core/uncategorised/4/actual.js new file mode 100644 index 0000000000..dbeef09056 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/4/actual.js @@ -0,0 +1 @@ +/foobar/ \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/4/expected.json b/packages/babylon/test/fixtures/core/uncategorised/4/expected.json new file mode 100644 index 0000000000..55ace9408f --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/4/expected.json @@ -0,0 +1,25 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "Literal", + "regex": { + "pattern": "foobar", + "flags": "" + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 8 + } + } + } + } + ] +} diff --git a/packages/babylon/test/fixtures/core/uncategorised/40/actual.js b/packages/babylon/test/fixtures/core/uncategorised/40/actual.js new file mode 100644 index 0000000000..8689324d5f --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/40/actual.js @@ -0,0 +1 @@ +x = { set false(w) { m_false = w } } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/40/expected.json b/packages/babylon/test/fixtures/core/uncategorised/40/expected.json new file mode 100644 index 0000000000..3ea234a071 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/40/expected.json @@ -0,0 +1,189 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "AssignmentExpression", + "operator": "=", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "right": { + "type": "ObjectExpression", + "properties": [ + { + "type": "Property", + "key": { + "type": "Identifier", + "name": "false", + "loc": { + "start": { + "line": 1, + "column": 10 + }, + "end": { + "line": 1, + "column": 15 + } + } + }, + "kind": "set", + "value": { + "type": "FunctionExpression", + "id": null, + "params": [ + { + "type": "Identifier", + "name": "w", + "loc": { + "start": { + "line": 1, + "column": 16 + }, + "end": { + "line": 1, + "column": 17 + } + } + } + ], + "body": { + "type": "BlockStatement", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "AssignmentExpression", + "operator": "=", + "left": { + "type": "Identifier", + "name": "m_false", + "loc": { + "start": { + "line": 1, + "column": 21 + }, + "end": { + "line": 1, + "column": 28 + } + } + }, + "right": { + "type": "Identifier", + "name": "w", + "loc": { + "start": { + "line": 1, + "column": 31 + }, + "end": { + "line": 1, + "column": 32 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 21 + }, + "end": { + "line": 1, + "column": 32 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 21 + }, + "end": { + "line": 1, + "column": 32 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 19 + }, + "end": { + "line": 1, + "column": 34 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 15 + }, + "end": { + "line": 1, + "column": 34 + } + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 36 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 36 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 36 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 36 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/400/actual.js b/packages/babylon/test/fixtures/core/uncategorised/400/actual.js new file mode 100644 index 0000000000..d5910a52eb --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/400/actual.js @@ -0,0 +1 @@ +function t(null) { } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/400/options.json b/packages/babylon/test/fixtures/core/uncategorised/400/options.json new file mode 100644 index 0000000000..3e33f7730f --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/400/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unexpected token (1:11)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/401/actual.js b/packages/babylon/test/fixtures/core/uncategorised/401/actual.js new file mode 100644 index 0000000000..f724653722 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/401/actual.js @@ -0,0 +1 @@ +function null() { } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/401/options.json b/packages/babylon/test/fixtures/core/uncategorised/401/options.json new file mode 100644 index 0000000000..93db7641c7 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/401/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unexpected token (1:9)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/402/actual.js b/packages/babylon/test/fixtures/core/uncategorised/402/actual.js new file mode 100644 index 0000000000..9ccba00e4a --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/402/actual.js @@ -0,0 +1 @@ +function true() { } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/402/options.json b/packages/babylon/test/fixtures/core/uncategorised/402/options.json new file mode 100644 index 0000000000..93db7641c7 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/402/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unexpected token (1:9)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/403/actual.js b/packages/babylon/test/fixtures/core/uncategorised/403/actual.js new file mode 100644 index 0000000000..99192a0303 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/403/actual.js @@ -0,0 +1 @@ +function false() { } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/403/options.json b/packages/babylon/test/fixtures/core/uncategorised/403/options.json new file mode 100644 index 0000000000..93db7641c7 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/403/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unexpected token (1:9)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/404/actual.js b/packages/babylon/test/fixtures/core/uncategorised/404/actual.js new file mode 100644 index 0000000000..60ae5cccef --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/404/actual.js @@ -0,0 +1 @@ +function if() { } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/404/options.json b/packages/babylon/test/fixtures/core/uncategorised/404/options.json new file mode 100644 index 0000000000..93db7641c7 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/404/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unexpected token (1:9)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/405/actual.js b/packages/babylon/test/fixtures/core/uncategorised/405/actual.js new file mode 100644 index 0000000000..2fd34315ad --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/405/actual.js @@ -0,0 +1 @@ +a b; \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/405/options.json b/packages/babylon/test/fixtures/core/uncategorised/405/options.json new file mode 100644 index 0000000000..e68fbb6aec --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/405/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unexpected token (1:2)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/406/actual.js b/packages/babylon/test/fixtures/core/uncategorised/406/actual.js new file mode 100644 index 0000000000..28f63db288 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/406/actual.js @@ -0,0 +1 @@ +if.a; \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/406/options.json b/packages/babylon/test/fixtures/core/uncategorised/406/options.json new file mode 100644 index 0000000000..e68fbb6aec --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/406/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unexpected token (1:2)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/407/actual.js b/packages/babylon/test/fixtures/core/uncategorised/407/actual.js new file mode 100644 index 0000000000..06050b10ce --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/407/actual.js @@ -0,0 +1 @@ +a if; \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/407/options.json b/packages/babylon/test/fixtures/core/uncategorised/407/options.json new file mode 100644 index 0000000000..e68fbb6aec --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/407/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unexpected token (1:2)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/408/actual.js b/packages/babylon/test/fixtures/core/uncategorised/408/actual.js new file mode 100644 index 0000000000..6da2429bca --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/408/actual.js @@ -0,0 +1 @@ +a class; \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/408/options.json b/packages/babylon/test/fixtures/core/uncategorised/408/options.json new file mode 100644 index 0000000000..e68fbb6aec --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/408/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unexpected token (1:2)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/409/actual.js b/packages/babylon/test/fixtures/core/uncategorised/409/actual.js new file mode 100644 index 0000000000..bf3fdcd662 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/409/actual.js @@ -0,0 +1 @@ +break diff --git a/packages/babylon/test/fixtures/core/uncategorised/409/options.json b/packages/babylon/test/fixtures/core/uncategorised/409/options.json new file mode 100644 index 0000000000..6ccbfe923d --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/409/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unsyntactic break (1:0)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/41/actual.js b/packages/babylon/test/fixtures/core/uncategorised/41/actual.js new file mode 100644 index 0000000000..2694a883bd --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/41/actual.js @@ -0,0 +1 @@ +x = { set null(w) { m_null = w } } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/41/expected.json b/packages/babylon/test/fixtures/core/uncategorised/41/expected.json new file mode 100644 index 0000000000..ce5e7a6e6b --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/41/expected.json @@ -0,0 +1,189 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "AssignmentExpression", + "operator": "=", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "right": { + "type": "ObjectExpression", + "properties": [ + { + "type": "Property", + "key": { + "type": "Identifier", + "name": "null", + "loc": { + "start": { + "line": 1, + "column": 10 + }, + "end": { + "line": 1, + "column": 14 + } + } + }, + "kind": "set", + "value": { + "type": "FunctionExpression", + "id": null, + "params": [ + { + "type": "Identifier", + "name": "w", + "loc": { + "start": { + "line": 1, + "column": 15 + }, + "end": { + "line": 1, + "column": 16 + } + } + } + ], + "body": { + "type": "BlockStatement", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "AssignmentExpression", + "operator": "=", + "left": { + "type": "Identifier", + "name": "m_null", + "loc": { + "start": { + "line": 1, + "column": 20 + }, + "end": { + "line": 1, + "column": 26 + } + } + }, + "right": { + "type": "Identifier", + "name": "w", + "loc": { + "start": { + "line": 1, + "column": 29 + }, + "end": { + "line": 1, + "column": 30 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 20 + }, + "end": { + "line": 1, + "column": 30 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 20 + }, + "end": { + "line": 1, + "column": 30 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 18 + }, + "end": { + "line": 1, + "column": 32 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 14 + }, + "end": { + "line": 1, + "column": 32 + } + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 34 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 34 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 34 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 34 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/410/actual.js b/packages/babylon/test/fixtures/core/uncategorised/410/actual.js new file mode 100644 index 0000000000..ecbca055ab --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/410/actual.js @@ -0,0 +1 @@ +break 1; \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/410/options.json b/packages/babylon/test/fixtures/core/uncategorised/410/options.json new file mode 100644 index 0000000000..515b971673 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/410/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unexpected token (1:6)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/411/actual.js b/packages/babylon/test/fixtures/core/uncategorised/411/actual.js new file mode 100644 index 0000000000..44c5d7d65e --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/411/actual.js @@ -0,0 +1 @@ +continue diff --git a/packages/babylon/test/fixtures/core/uncategorised/411/options.json b/packages/babylon/test/fixtures/core/uncategorised/411/options.json new file mode 100644 index 0000000000..14a50290d0 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/411/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unsyntactic continue (1:0)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/412/actual.js b/packages/babylon/test/fixtures/core/uncategorised/412/actual.js new file mode 100644 index 0000000000..5ff072b231 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/412/actual.js @@ -0,0 +1 @@ +continue 2; \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/412/options.json b/packages/babylon/test/fixtures/core/uncategorised/412/options.json new file mode 100644 index 0000000000..93db7641c7 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/412/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unexpected token (1:9)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/413/actual.js b/packages/babylon/test/fixtures/core/uncategorised/413/actual.js new file mode 100644 index 0000000000..755c8ff384 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/413/actual.js @@ -0,0 +1 @@ +throw \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/413/options.json b/packages/babylon/test/fixtures/core/uncategorised/413/options.json new file mode 100644 index 0000000000..0ab445fe47 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/413/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unexpected token (1:5)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/414/actual.js b/packages/babylon/test/fixtures/core/uncategorised/414/actual.js new file mode 100644 index 0000000000..bcd16c628e --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/414/actual.js @@ -0,0 +1 @@ +throw; \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/414/options.json b/packages/babylon/test/fixtures/core/uncategorised/414/options.json new file mode 100644 index 0000000000..0ab445fe47 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/414/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unexpected token (1:5)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/415/actual.js b/packages/babylon/test/fixtures/core/uncategorised/415/actual.js new file mode 100644 index 0000000000..5d5757515f --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/415/actual.js @@ -0,0 +1 @@ +for (var i, i2 in {}); \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/415/options.json b/packages/babylon/test/fixtures/core/uncategorised/415/options.json new file mode 100644 index 0000000000..7ca1e1ffbb --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/415/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unexpected token (1:15)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/416/actual.js b/packages/babylon/test/fixtures/core/uncategorised/416/actual.js new file mode 100644 index 0000000000..fba65c91d1 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/416/actual.js @@ -0,0 +1 @@ +for ((i in {})); \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/416/options.json b/packages/babylon/test/fixtures/core/uncategorised/416/options.json new file mode 100644 index 0000000000..51c483f3d3 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/416/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unexpected token (1:14)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/417/actual.js b/packages/babylon/test/fixtures/core/uncategorised/417/actual.js new file mode 100644 index 0000000000..ec4b3d7eed --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/417/actual.js @@ -0,0 +1 @@ +for (i + 1 in {}); \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/417/options.json b/packages/babylon/test/fixtures/core/uncategorised/417/options.json new file mode 100644 index 0000000000..85f6f01102 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/417/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Assigning to rvalue (1:5)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/418/actual.js b/packages/babylon/test/fixtures/core/uncategorised/418/actual.js new file mode 100644 index 0000000000..296d2bb399 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/418/actual.js @@ -0,0 +1 @@ +for (+i in {}); \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/418/options.json b/packages/babylon/test/fixtures/core/uncategorised/418/options.json new file mode 100644 index 0000000000..85f6f01102 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/418/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Assigning to rvalue (1:5)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/419/actual.js b/packages/babylon/test/fixtures/core/uncategorised/419/actual.js new file mode 100644 index 0000000000..edefc106d6 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/419/actual.js @@ -0,0 +1 @@ +if(false) \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/419/options.json b/packages/babylon/test/fixtures/core/uncategorised/419/options.json new file mode 100644 index 0000000000..93db7641c7 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/419/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unexpected token (1:9)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/42/actual.js b/packages/babylon/test/fixtures/core/uncategorised/42/actual.js new file mode 100644 index 0000000000..46712ca95a --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/42/actual.js @@ -0,0 +1 @@ +x = { set "null"(w) { m_null = w } } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/42/expected.json b/packages/babylon/test/fixtures/core/uncategorised/42/expected.json new file mode 100644 index 0000000000..1c17723f61 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/42/expected.json @@ -0,0 +1,189 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "AssignmentExpression", + "operator": "=", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "right": { + "type": "ObjectExpression", + "properties": [ + { + "type": "Property", + "key": { + "type": "Literal", + "value": "null", + "loc": { + "start": { + "line": 1, + "column": 10 + }, + "end": { + "line": 1, + "column": 16 + } + } + }, + "kind": "set", + "value": { + "type": "FunctionExpression", + "id": null, + "params": [ + { + "type": "Identifier", + "name": "w", + "loc": { + "start": { + "line": 1, + "column": 17 + }, + "end": { + "line": 1, + "column": 18 + } + } + } + ], + "body": { + "type": "BlockStatement", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "AssignmentExpression", + "operator": "=", + "left": { + "type": "Identifier", + "name": "m_null", + "loc": { + "start": { + "line": 1, + "column": 22 + }, + "end": { + "line": 1, + "column": 28 + } + } + }, + "right": { + "type": "Identifier", + "name": "w", + "loc": { + "start": { + "line": 1, + "column": 31 + }, + "end": { + "line": 1, + "column": 32 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 22 + }, + "end": { + "line": 1, + "column": 32 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 22 + }, + "end": { + "line": 1, + "column": 32 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 20 + }, + "end": { + "line": 1, + "column": 34 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 16 + }, + "end": { + "line": 1, + "column": 34 + } + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 36 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 36 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 36 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 36 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/420/actual.js b/packages/babylon/test/fixtures/core/uncategorised/420/actual.js new file mode 100644 index 0000000000..71b98df679 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/420/actual.js @@ -0,0 +1 @@ +if(false) doThis(); else \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/420/options.json b/packages/babylon/test/fixtures/core/uncategorised/420/options.json new file mode 100644 index 0000000000..0c5f4deed6 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/420/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unexpected token (1:24)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/421/actual.js b/packages/babylon/test/fixtures/core/uncategorised/421/actual.js new file mode 100644 index 0000000000..7d46b283ba --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/421/actual.js @@ -0,0 +1 @@ +do \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/421/options.json b/packages/babylon/test/fixtures/core/uncategorised/421/options.json new file mode 100644 index 0000000000..e68fbb6aec --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/421/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unexpected token (1:2)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/422/actual.js b/packages/babylon/test/fixtures/core/uncategorised/422/actual.js new file mode 100644 index 0000000000..b321f19a27 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/422/actual.js @@ -0,0 +1 @@ +while(false) \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/422/options.json b/packages/babylon/test/fixtures/core/uncategorised/422/options.json new file mode 100644 index 0000000000..358068a16a --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/422/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unexpected token (1:12)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/423/actual.js b/packages/babylon/test/fixtures/core/uncategorised/423/actual.js new file mode 100644 index 0000000000..3cee0cd400 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/423/actual.js @@ -0,0 +1 @@ +for(;;) \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/423/options.json b/packages/babylon/test/fixtures/core/uncategorised/423/options.json new file mode 100644 index 0000000000..167116741e --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/423/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unexpected token (1:7)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/424/actual.js b/packages/babylon/test/fixtures/core/uncategorised/424/actual.js new file mode 100644 index 0000000000..c6bdc6dd80 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/424/actual.js @@ -0,0 +1 @@ +with(x) \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/424/options.json b/packages/babylon/test/fixtures/core/uncategorised/424/options.json new file mode 100644 index 0000000000..167116741e --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/424/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unexpected token (1:7)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/425/actual.js b/packages/babylon/test/fixtures/core/uncategorised/425/actual.js new file mode 100644 index 0000000000..1b2a04396a --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/425/actual.js @@ -0,0 +1 @@ +try { } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/425/options.json b/packages/babylon/test/fixtures/core/uncategorised/425/options.json new file mode 100644 index 0000000000..9b3d4185f1 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/425/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Missing catch or finally clause (1:0)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/426/actual.js b/packages/babylon/test/fixtures/core/uncategorised/426/actual.js new file mode 100644 index 0000000000..bf457f6517 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/426/actual.js @@ -0,0 +1 @@ +‿ = 10 \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/426/options.json b/packages/babylon/test/fixtures/core/uncategorised/426/options.json new file mode 100644 index 0000000000..439961e8ea --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/426/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unexpected character '‿' (1:0)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/427/actual.js b/packages/babylon/test/fixtures/core/uncategorised/427/actual.js new file mode 100644 index 0000000000..e95f25434a --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/427/actual.js @@ -0,0 +1 @@ +switch (c) { default: default: } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/427/options.json b/packages/babylon/test/fixtures/core/uncategorised/427/options.json new file mode 100644 index 0000000000..8ded4af443 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/427/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Multiple default clauses (1:22)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/428/actual.js b/packages/babylon/test/fixtures/core/uncategorised/428/actual.js new file mode 100644 index 0000000000..07afe03ddd --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/428/actual.js @@ -0,0 +1 @@ +new X()."s" \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/428/options.json b/packages/babylon/test/fixtures/core/uncategorised/428/options.json new file mode 100644 index 0000000000..65ef4a184a --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/428/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unexpected token (1:8)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/429/actual.js b/packages/babylon/test/fixtures/core/uncategorised/429/actual.js new file mode 100644 index 0000000000..22e83649f7 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/429/actual.js @@ -0,0 +1 @@ +/* \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/429/options.json b/packages/babylon/test/fixtures/core/uncategorised/429/options.json new file mode 100644 index 0000000000..228eff80e8 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/429/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unterminated comment (1:0)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/43/actual.js b/packages/babylon/test/fixtures/core/uncategorised/43/actual.js new file mode 100644 index 0000000000..c5e8300a63 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/43/actual.js @@ -0,0 +1 @@ +x = { set 10(w) { m_null = w } } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/43/expected.json b/packages/babylon/test/fixtures/core/uncategorised/43/expected.json new file mode 100644 index 0000000000..7b570465a9 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/43/expected.json @@ -0,0 +1,189 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "AssignmentExpression", + "operator": "=", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "right": { + "type": "ObjectExpression", + "properties": [ + { + "type": "Property", + "key": { + "type": "Literal", + "value": 10, + "loc": { + "start": { + "line": 1, + "column": 10 + }, + "end": { + "line": 1, + "column": 12 + } + } + }, + "kind": "set", + "value": { + "type": "FunctionExpression", + "id": null, + "params": [ + { + "type": "Identifier", + "name": "w", + "loc": { + "start": { + "line": 1, + "column": 13 + }, + "end": { + "line": 1, + "column": 14 + } + } + } + ], + "body": { + "type": "BlockStatement", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "AssignmentExpression", + "operator": "=", + "left": { + "type": "Identifier", + "name": "m_null", + "loc": { + "start": { + "line": 1, + "column": 18 + }, + "end": { + "line": 1, + "column": 24 + } + } + }, + "right": { + "type": "Identifier", + "name": "w", + "loc": { + "start": { + "line": 1, + "column": 27 + }, + "end": { + "line": 1, + "column": 28 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 18 + }, + "end": { + "line": 1, + "column": 28 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 18 + }, + "end": { + "line": 1, + "column": 28 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 16 + }, + "end": { + "line": 1, + "column": 30 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 12 + }, + "end": { + "line": 1, + "column": 30 + } + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 32 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 32 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 32 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 32 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/430/actual.js b/packages/babylon/test/fixtures/core/uncategorised/430/actual.js new file mode 100644 index 0000000000..c9a4262e23 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/430/actual.js @@ -0,0 +1,3 @@ +/* + + diff --git a/packages/babylon/test/fixtures/core/uncategorised/430/options.json b/packages/babylon/test/fixtures/core/uncategorised/430/options.json new file mode 100644 index 0000000000..228eff80e8 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/430/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unterminated comment (1:0)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/431/actual.js b/packages/babylon/test/fixtures/core/uncategorised/431/actual.js new file mode 100644 index 0000000000..45ee88f1be --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/431/actual.js @@ -0,0 +1 @@ +/** \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/431/options.json b/packages/babylon/test/fixtures/core/uncategorised/431/options.json new file mode 100644 index 0000000000..228eff80e8 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/431/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unterminated comment (1:0)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/432/actual.js b/packages/babylon/test/fixtures/core/uncategorised/432/actual.js new file mode 100644 index 0000000000..95a6f3a2b6 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/432/actual.js @@ -0,0 +1,3 @@ +/* + +* \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/432/options.json b/packages/babylon/test/fixtures/core/uncategorised/432/options.json new file mode 100644 index 0000000000..228eff80e8 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/432/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unterminated comment (1:0)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/433/actual.js b/packages/babylon/test/fixtures/core/uncategorised/433/actual.js new file mode 100644 index 0000000000..c1dc0e4664 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/433/actual.js @@ -0,0 +1 @@ +/*hello \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/433/options.json b/packages/babylon/test/fixtures/core/uncategorised/433/options.json new file mode 100644 index 0000000000..228eff80e8 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/433/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unterminated comment (1:0)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/434/actual.js b/packages/babylon/test/fixtures/core/uncategorised/434/actual.js new file mode 100644 index 0000000000..f2999098ae --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/434/actual.js @@ -0,0 +1 @@ +/*hello * \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/434/options.json b/packages/babylon/test/fixtures/core/uncategorised/434/options.json new file mode 100644 index 0000000000..228eff80e8 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/434/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unterminated comment (1:0)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/435/actual.js b/packages/babylon/test/fixtures/core/uncategorised/435/actual.js new file mode 100644 index 0000000000..4edaa423c5 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/435/actual.js @@ -0,0 +1,2 @@ + +] \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/435/options.json b/packages/babylon/test/fixtures/core/uncategorised/435/options.json new file mode 100644 index 0000000000..0361d7c7d2 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/435/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unexpected token (2:0)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/436/actual.js b/packages/babylon/test/fixtures/core/uncategorised/436/actual.js new file mode 100644 index 0000000000..5965dc1f86 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/436/actual.js @@ -0,0 +1 @@ + ] \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/436/options.json b/packages/babylon/test/fixtures/core/uncategorised/436/options.json new file mode 100644 index 0000000000..0361d7c7d2 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/436/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unexpected token (2:0)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/437/actual.js b/packages/babylon/test/fixtures/core/uncategorised/437/actual.js new file mode 100644 index 0000000000..0505244ad4 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/437/actual.js @@ -0,0 +1,2 @@ + +] \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/437/options.json b/packages/babylon/test/fixtures/core/uncategorised/437/options.json new file mode 100644 index 0000000000..0361d7c7d2 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/437/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unexpected token (2:0)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/438/actual.js b/packages/babylon/test/fixtures/core/uncategorised/438/actual.js new file mode 100644 index 0000000000..b02ef5aa14 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/438/actual.js @@ -0,0 +1,2 @@ + + ] \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/438/options.json b/packages/babylon/test/fixtures/core/uncategorised/438/options.json new file mode 100644 index 0000000000..aa8239233c --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/438/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unexpected token (3:0)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/439/actual.js b/packages/babylon/test/fixtures/core/uncategorised/439/actual.js new file mode 100644 index 0000000000..c5a7dbbee9 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/439/actual.js @@ -0,0 +1,2 @@ +// +] \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/439/options.json b/packages/babylon/test/fixtures/core/uncategorised/439/options.json new file mode 100644 index 0000000000..0361d7c7d2 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/439/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unexpected token (2:0)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/44/actual.js b/packages/babylon/test/fixtures/core/uncategorised/44/actual.js new file mode 100644 index 0000000000..12174c643f --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/44/actual.js @@ -0,0 +1 @@ +x = { get: 42 } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/44/expected.json b/packages/babylon/test/fixtures/core/uncategorised/44/expected.json new file mode 100644 index 0000000000..7ffd0f04b6 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/44/expected.json @@ -0,0 +1,103 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "AssignmentExpression", + "operator": "=", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "right": { + "type": "ObjectExpression", + "properties": [ + { + "type": "Property", + "key": { + "type": "Identifier", + "name": "get", + "loc": { + "start": { + "line": 1, + "column": 6 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + "value": { + "type": "Literal", + "value": 42, + "loc": { + "start": { + "line": 1, + "column": 11 + }, + "end": { + "line": 1, + "column": 13 + } + } + }, + "kind": "init" + } + ], + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 15 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 15 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 15 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 15 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/440/actual.js b/packages/babylon/test/fixtures/core/uncategorised/440/actual.js new file mode 100644 index 0000000000..89ac62245a --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/440/actual.js @@ -0,0 +1,2 @@ +// + ] \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/440/options.json b/packages/babylon/test/fixtures/core/uncategorised/440/options.json new file mode 100644 index 0000000000..aa8239233c --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/440/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unexpected token (3:0)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/441/actual.js b/packages/babylon/test/fixtures/core/uncategorised/441/actual.js new file mode 100644 index 0000000000..706ad61840 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/441/actual.js @@ -0,0 +1,2 @@ +/a\ +/ \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/441/options.json b/packages/babylon/test/fixtures/core/uncategorised/441/options.json new file mode 100644 index 0000000000..e07b72599f --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/441/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unterminated regular expression (1:1)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/442/actual.js b/packages/babylon/test/fixtures/core/uncategorised/442/actual.js new file mode 100644 index 0000000000..e365ebea9e --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/442/actual.js @@ -0,0 +1,2 @@ +// +] \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/442/options.json b/packages/babylon/test/fixtures/core/uncategorised/442/options.json new file mode 100644 index 0000000000..aa8239233c --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/442/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unexpected token (3:0)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/443/actual.js b/packages/babylon/test/fixtures/core/uncategorised/443/actual.js new file mode 100644 index 0000000000..db9e136f44 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/443/actual.js @@ -0,0 +1,2 @@ +/* +*/] \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/443/options.json b/packages/babylon/test/fixtures/core/uncategorised/443/options.json new file mode 100644 index 0000000000..0b22a698d6 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/443/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unexpected token (2:2)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/444/actual.js b/packages/babylon/test/fixtures/core/uncategorised/444/actual.js new file mode 100644 index 0000000000..365f61fb58 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/444/actual.js @@ -0,0 +1,2 @@ +/* + */] \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/444/options.json b/packages/babylon/test/fixtures/core/uncategorised/444/options.json new file mode 100644 index 0000000000..02c5500083 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/444/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unexpected token (3:2)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/445/actual.js b/packages/babylon/test/fixtures/core/uncategorised/445/actual.js new file mode 100644 index 0000000000..7465fdb403 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/445/actual.js @@ -0,0 +1,2 @@ +/* +*/] \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/445/options.json b/packages/babylon/test/fixtures/core/uncategorised/445/options.json new file mode 100644 index 0000000000..02c5500083 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/445/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unexpected token (3:2)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/446/actual.js b/packages/babylon/test/fixtures/core/uncategorised/446/actual.js new file mode 100644 index 0000000000..ea4f9caa99 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/446/actual.js @@ -0,0 +1 @@ +\\ \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/446/options.json b/packages/babylon/test/fixtures/core/uncategorised/446/options.json new file mode 100644 index 0000000000..c5a8baf2b8 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/446/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Expecting Unicode escape sequence \\uXXXX (1:1)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/447/actual.js b/packages/babylon/test/fixtures/core/uncategorised/447/actual.js new file mode 100644 index 0000000000..dbc1a20c64 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/447/actual.js @@ -0,0 +1 @@ +\u005c \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/447/options.json b/packages/babylon/test/fixtures/core/uncategorised/447/options.json new file mode 100644 index 0000000000..b813254a65 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/447/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Invalid Unicode escape (1:0)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/448/actual.js b/packages/babylon/test/fixtures/core/uncategorised/448/actual.js new file mode 100644 index 0000000000..0d4eae5d50 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/448/actual.js @@ -0,0 +1 @@ +\x \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/448/options.json b/packages/babylon/test/fixtures/core/uncategorised/448/options.json new file mode 100644 index 0000000000..c5a8baf2b8 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/448/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Expecting Unicode escape sequence \\uXXXX (1:1)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/449/actual.js b/packages/babylon/test/fixtures/core/uncategorised/449/actual.js new file mode 100644 index 0000000000..9cc2c678a5 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/449/actual.js @@ -0,0 +1 @@ +\u0000 \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/449/options.json b/packages/babylon/test/fixtures/core/uncategorised/449/options.json new file mode 100644 index 0000000000..b813254a65 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/449/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Invalid Unicode escape (1:0)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/45/actual.js b/packages/babylon/test/fixtures/core/uncategorised/45/actual.js new file mode 100644 index 0000000000..3750d76009 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/45/actual.js @@ -0,0 +1 @@ +x = { set: 43 } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/45/expected.json b/packages/babylon/test/fixtures/core/uncategorised/45/expected.json new file mode 100644 index 0000000000..e983e5cf2b --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/45/expected.json @@ -0,0 +1,103 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "AssignmentExpression", + "operator": "=", + "left": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 1 + } + } + }, + "right": { + "type": "ObjectExpression", + "properties": [ + { + "type": "Property", + "key": { + "type": "Identifier", + "name": "set", + "loc": { + "start": { + "line": 1, + "column": 6 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + "value": { + "type": "Literal", + "value": 43, + "loc": { + "start": { + "line": 1, + "column": 11 + }, + "end": { + "line": 1, + "column": 13 + } + } + }, + "kind": "init" + } + ], + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 15 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 15 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 15 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 15 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/450/actual.js b/packages/babylon/test/fixtures/core/uncategorised/450/actual.js new file mode 100644 index 0000000000..7e8819e322 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/450/actual.js @@ -0,0 +1 @@ +‌ = [] \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/450/options.json b/packages/babylon/test/fixtures/core/uncategorised/450/options.json new file mode 100644 index 0000000000..5fa9021849 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/450/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unexpected character '‌' (1:0)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/451/actual.js b/packages/babylon/test/fixtures/core/uncategorised/451/actual.js new file mode 100644 index 0000000000..e9a89a8903 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/451/actual.js @@ -0,0 +1 @@ +‍ = [] \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/451/options.json b/packages/babylon/test/fixtures/core/uncategorised/451/options.json new file mode 100644 index 0000000000..90935f68f4 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/451/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unexpected character '‍' (1:0)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/452/actual.js b/packages/babylon/test/fixtures/core/uncategorised/452/actual.js new file mode 100644 index 0000000000..00a2584008 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/452/actual.js @@ -0,0 +1 @@ +"\ \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/452/options.json b/packages/babylon/test/fixtures/core/uncategorised/452/options.json new file mode 100644 index 0000000000..a760565b1b --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/452/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unterminated string constant (1:0)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/453/actual.js b/packages/babylon/test/fixtures/core/uncategorised/453/actual.js new file mode 100644 index 0000000000..d062943f2d --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/453/actual.js @@ -0,0 +1 @@ +"\u \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/453/options.json b/packages/babylon/test/fixtures/core/uncategorised/453/options.json new file mode 100644 index 0000000000..143c8be643 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/453/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Bad character escape sequence (1:3)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/454/actual.js b/packages/babylon/test/fixtures/core/uncategorised/454/actual.js new file mode 100644 index 0000000000..55b1f0f4f2 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/454/actual.js @@ -0,0 +1 @@ +return \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/454/options.json b/packages/babylon/test/fixtures/core/uncategorised/454/options.json new file mode 100644 index 0000000000..dececd0e83 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/454/options.json @@ -0,0 +1,3 @@ +{ + "throws": "'return' outside of function (1:0)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/455/actual.js b/packages/babylon/test/fixtures/core/uncategorised/455/actual.js new file mode 100644 index 0000000000..5da70343a4 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/455/actual.js @@ -0,0 +1 @@ +break \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/455/options.json b/packages/babylon/test/fixtures/core/uncategorised/455/options.json new file mode 100644 index 0000000000..6ccbfe923d --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/455/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unsyntactic break (1:0)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/456/actual.js b/packages/babylon/test/fixtures/core/uncategorised/456/actual.js new file mode 100644 index 0000000000..b2960313c5 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/456/actual.js @@ -0,0 +1 @@ +continue \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/456/options.json b/packages/babylon/test/fixtures/core/uncategorised/456/options.json new file mode 100644 index 0000000000..14a50290d0 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/456/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unsyntactic continue (1:0)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/457/actual.js b/packages/babylon/test/fixtures/core/uncategorised/457/actual.js new file mode 100644 index 0000000000..4877dbd48b --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/457/actual.js @@ -0,0 +1 @@ +switch (x) { default: continue; } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/457/options.json b/packages/babylon/test/fixtures/core/uncategorised/457/options.json new file mode 100644 index 0000000000..332366a21c --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/457/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unsyntactic continue (1:22)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/458/actual.js b/packages/babylon/test/fixtures/core/uncategorised/458/actual.js new file mode 100644 index 0000000000..d1dab07d16 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/458/actual.js @@ -0,0 +1 @@ +do { x } * \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/458/options.json b/packages/babylon/test/fixtures/core/uncategorised/458/options.json new file mode 100644 index 0000000000..93db7641c7 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/458/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unexpected token (1:9)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/459/actual.js b/packages/babylon/test/fixtures/core/uncategorised/459/actual.js new file mode 100644 index 0000000000..73ddc918ec --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/459/actual.js @@ -0,0 +1 @@ +while (true) { break x; } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/459/options.json b/packages/babylon/test/fixtures/core/uncategorised/459/options.json new file mode 100644 index 0000000000..33bf5f84b8 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/459/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unsyntactic break (1:15)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/46/actual.js b/packages/babylon/test/fixtures/core/uncategorised/46/actual.js new file mode 100644 index 0000000000..69793e89ce --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/46/actual.js @@ -0,0 +1 @@ +/* block comment */ 42 \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/46/expected.json b/packages/babylon/test/fixtures/core/uncategorised/46/expected.json new file mode 100644 index 0000000000..f6801a2335 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/46/expected.json @@ -0,0 +1,42 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "Literal", + "value": 42, + "loc": { + "start": { + "line": 1, + "column": 20 + }, + "end": { + "line": 1, + "column": 22 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 20 + }, + "end": { + "line": 1, + "column": 22 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 22 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/460/actual.js b/packages/babylon/test/fixtures/core/uncategorised/460/actual.js new file mode 100644 index 0000000000..518c9670c4 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/460/actual.js @@ -0,0 +1 @@ +while (true) { continue x; } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/460/options.json b/packages/babylon/test/fixtures/core/uncategorised/460/options.json new file mode 100644 index 0000000000..e75cfed858 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/460/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unsyntactic continue (1:15)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/461/actual.js b/packages/babylon/test/fixtures/core/uncategorised/461/actual.js new file mode 100644 index 0000000000..d925d780fa --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/461/actual.js @@ -0,0 +1 @@ +x: while (true) { (function () { break x; }); } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/461/options.json b/packages/babylon/test/fixtures/core/uncategorised/461/options.json new file mode 100644 index 0000000000..8008848be3 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/461/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unsyntactic break (1:33)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/462/actual.js b/packages/babylon/test/fixtures/core/uncategorised/462/actual.js new file mode 100644 index 0000000000..2b6a7bb846 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/462/actual.js @@ -0,0 +1 @@ +x: while (true) { (function () { continue x; }); } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/462/options.json b/packages/babylon/test/fixtures/core/uncategorised/462/options.json new file mode 100644 index 0000000000..f0faa7faaa --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/462/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unsyntactic continue (1:33)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/463/actual.js b/packages/babylon/test/fixtures/core/uncategorised/463/actual.js new file mode 100644 index 0000000000..f013175d47 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/463/actual.js @@ -0,0 +1 @@ +x: while (true) { (function () { break; }); } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/463/options.json b/packages/babylon/test/fixtures/core/uncategorised/463/options.json new file mode 100644 index 0000000000..8008848be3 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/463/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unsyntactic break (1:33)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/464/actual.js b/packages/babylon/test/fixtures/core/uncategorised/464/actual.js new file mode 100644 index 0000000000..3e0f871e0a --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/464/actual.js @@ -0,0 +1 @@ +x: while (true) { (function () { continue; }); } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/464/options.json b/packages/babylon/test/fixtures/core/uncategorised/464/options.json new file mode 100644 index 0000000000..f0faa7faaa --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/464/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unsyntactic continue (1:33)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/465/actual.js b/packages/babylon/test/fixtures/core/uncategorised/465/actual.js new file mode 100644 index 0000000000..93e3c1cb95 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/465/actual.js @@ -0,0 +1 @@ +x: while (true) { x: while (true) { } } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/465/options.json b/packages/babylon/test/fixtures/core/uncategorised/465/options.json new file mode 100644 index 0000000000..a430baffb5 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/465/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Label 'x' is already declared (1:18)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/466/actual.js b/packages/babylon/test/fixtures/core/uncategorised/466/actual.js new file mode 100644 index 0000000000..9dcd5c466b --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/466/actual.js @@ -0,0 +1 @@ +(function () { 'use strict'; delete i; }()) \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/466/options.json b/packages/babylon/test/fixtures/core/uncategorised/466/options.json new file mode 100644 index 0000000000..8112470453 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/466/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Deleting local variable in strict mode (1:29)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/467/actual.js b/packages/babylon/test/fixtures/core/uncategorised/467/actual.js new file mode 100644 index 0000000000..ab4ab1872c --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/467/actual.js @@ -0,0 +1 @@ +(function () { 'use strict'; with (i); }()) \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/467/options.json b/packages/babylon/test/fixtures/core/uncategorised/467/options.json new file mode 100644 index 0000000000..1b86ef2104 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/467/options.json @@ -0,0 +1,3 @@ +{ + "throws": "'with' in strict mode (1:29)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/468/actual.js b/packages/babylon/test/fixtures/core/uncategorised/468/actual.js new file mode 100644 index 0000000000..9dd57852ff --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/468/actual.js @@ -0,0 +1 @@ +function hello() {'use strict'; var eval = 10; } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/468/options.json b/packages/babylon/test/fixtures/core/uncategorised/468/options.json new file mode 100644 index 0000000000..0e72c82fe8 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/468/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Binding eval in strict mode (1:36)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/469/actual.js b/packages/babylon/test/fixtures/core/uncategorised/469/actual.js new file mode 100644 index 0000000000..20851bb14c --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/469/actual.js @@ -0,0 +1 @@ +function hello() {'use strict'; var arguments = 10; } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/469/options.json b/packages/babylon/test/fixtures/core/uncategorised/469/options.json new file mode 100644 index 0000000000..f171e1b2c8 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/469/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Binding arguments in strict mode (1:36)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/47/actual.js b/packages/babylon/test/fixtures/core/uncategorised/47/actual.js new file mode 100644 index 0000000000..9a549f725c --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/47/actual.js @@ -0,0 +1 @@ +42 /*The*/ /*Answer*/ \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/47/expected.json b/packages/babylon/test/fixtures/core/uncategorised/47/expected.json new file mode 100644 index 0000000000..e1e613dbe8 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/47/expected.json @@ -0,0 +1,42 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "Literal", + "value": 42, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 2 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 2 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 21 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/470/actual.js b/packages/babylon/test/fixtures/core/uncategorised/470/actual.js new file mode 100644 index 0000000000..543da775bc --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/470/actual.js @@ -0,0 +1 @@ +function hello() {'use strict'; try { } catch (eval) { } } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/470/options.json b/packages/babylon/test/fixtures/core/uncategorised/470/options.json new file mode 100644 index 0000000000..52cc5e0c10 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/470/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Binding eval in strict mode (1:47)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/471/actual.js b/packages/babylon/test/fixtures/core/uncategorised/471/actual.js new file mode 100644 index 0000000000..cc1030eb74 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/471/actual.js @@ -0,0 +1 @@ +function hello() {'use strict'; try { } catch (arguments) { } } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/471/options.json b/packages/babylon/test/fixtures/core/uncategorised/471/options.json new file mode 100644 index 0000000000..1c09320e14 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/471/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Binding arguments in strict mode (1:47)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/472/actual.js b/packages/babylon/test/fixtures/core/uncategorised/472/actual.js new file mode 100644 index 0000000000..0b13acf93e --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/472/actual.js @@ -0,0 +1 @@ +function hello() {'use strict'; eval = 10; } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/472/options.json b/packages/babylon/test/fixtures/core/uncategorised/472/options.json new file mode 100644 index 0000000000..e606855bd2 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/472/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Assigning to eval in strict mode (1:32)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/473/actual.js b/packages/babylon/test/fixtures/core/uncategorised/473/actual.js new file mode 100644 index 0000000000..d3f743d5d8 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/473/actual.js @@ -0,0 +1 @@ +function hello() {'use strict'; arguments = 10; } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/473/options.json b/packages/babylon/test/fixtures/core/uncategorised/473/options.json new file mode 100644 index 0000000000..d66800268f --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/473/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Assigning to arguments in strict mode (1:32)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/474/actual.js b/packages/babylon/test/fixtures/core/uncategorised/474/actual.js new file mode 100644 index 0000000000..9908f082fc --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/474/actual.js @@ -0,0 +1 @@ +function hello() {'use strict'; ++eval; } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/474/options.json b/packages/babylon/test/fixtures/core/uncategorised/474/options.json new file mode 100644 index 0000000000..194b27c0a0 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/474/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Assigning to eval in strict mode (1:34)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/475/actual.js b/packages/babylon/test/fixtures/core/uncategorised/475/actual.js new file mode 100644 index 0000000000..b0c96554ee --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/475/actual.js @@ -0,0 +1 @@ +function hello() {'use strict'; --eval; } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/475/options.json b/packages/babylon/test/fixtures/core/uncategorised/475/options.json new file mode 100644 index 0000000000..194b27c0a0 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/475/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Assigning to eval in strict mode (1:34)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/476/actual.js b/packages/babylon/test/fixtures/core/uncategorised/476/actual.js new file mode 100644 index 0000000000..978196de57 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/476/actual.js @@ -0,0 +1 @@ +function hello() {'use strict'; ++arguments; } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/476/options.json b/packages/babylon/test/fixtures/core/uncategorised/476/options.json new file mode 100644 index 0000000000..fa7fd234e5 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/476/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Assigning to arguments in strict mode (1:34)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/477/actual.js b/packages/babylon/test/fixtures/core/uncategorised/477/actual.js new file mode 100644 index 0000000000..b1042bed31 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/477/actual.js @@ -0,0 +1 @@ +function hello() {'use strict'; --arguments; } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/477/options.json b/packages/babylon/test/fixtures/core/uncategorised/477/options.json new file mode 100644 index 0000000000..fa7fd234e5 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/477/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Assigning to arguments in strict mode (1:34)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/478/actual.js b/packages/babylon/test/fixtures/core/uncategorised/478/actual.js new file mode 100644 index 0000000000..0d3bb5a621 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/478/actual.js @@ -0,0 +1 @@ +function hello() {'use strict'; eval++; } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/478/options.json b/packages/babylon/test/fixtures/core/uncategorised/478/options.json new file mode 100644 index 0000000000..e606855bd2 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/478/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Assigning to eval in strict mode (1:32)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/479/actual.js b/packages/babylon/test/fixtures/core/uncategorised/479/actual.js new file mode 100644 index 0000000000..aa25d1fb8d --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/479/actual.js @@ -0,0 +1 @@ +function hello() {'use strict'; eval--; } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/479/options.json b/packages/babylon/test/fixtures/core/uncategorised/479/options.json new file mode 100644 index 0000000000..e606855bd2 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/479/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Assigning to eval in strict mode (1:32)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/48/actual.js b/packages/babylon/test/fixtures/core/uncategorised/48/actual.js new file mode 100644 index 0000000000..515f60493d --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/48/actual.js @@ -0,0 +1 @@ +42 /*the*/ /*answer*/ \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/48/expected.json b/packages/babylon/test/fixtures/core/uncategorised/48/expected.json new file mode 100644 index 0000000000..e1e613dbe8 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/48/expected.json @@ -0,0 +1,42 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "Literal", + "value": 42, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 2 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 2 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 21 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/480/actual.js b/packages/babylon/test/fixtures/core/uncategorised/480/actual.js new file mode 100644 index 0000000000..2cf35cda90 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/480/actual.js @@ -0,0 +1 @@ +function hello() {'use strict'; arguments++; } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/480/options.json b/packages/babylon/test/fixtures/core/uncategorised/480/options.json new file mode 100644 index 0000000000..d66800268f --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/480/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Assigning to arguments in strict mode (1:32)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/481/actual.js b/packages/babylon/test/fixtures/core/uncategorised/481/actual.js new file mode 100644 index 0000000000..4e578c0d7c --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/481/actual.js @@ -0,0 +1 @@ +function hello() {'use strict'; arguments--; } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/481/options.json b/packages/babylon/test/fixtures/core/uncategorised/481/options.json new file mode 100644 index 0000000000..d66800268f --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/481/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Assigning to arguments in strict mode (1:32)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/482/actual.js b/packages/babylon/test/fixtures/core/uncategorised/482/actual.js new file mode 100644 index 0000000000..c7fa960f7e --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/482/actual.js @@ -0,0 +1 @@ +function hello() {'use strict'; function eval() { } } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/482/options.json b/packages/babylon/test/fixtures/core/uncategorised/482/options.json new file mode 100644 index 0000000000..74aee2c177 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/482/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Binding eval in strict mode (1:41)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/483/actual.js b/packages/babylon/test/fixtures/core/uncategorised/483/actual.js new file mode 100644 index 0000000000..59a6aa3983 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/483/actual.js @@ -0,0 +1 @@ +function hello() {'use strict'; function arguments() { } } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/483/options.json b/packages/babylon/test/fixtures/core/uncategorised/483/options.json new file mode 100644 index 0000000000..cb4087319e --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/483/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Binding arguments in strict mode (1:41)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/484/actual.js b/packages/babylon/test/fixtures/core/uncategorised/484/actual.js new file mode 100644 index 0000000000..4b756749ac --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/484/actual.js @@ -0,0 +1 @@ +function eval() {'use strict'; } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/484/options.json b/packages/babylon/test/fixtures/core/uncategorised/484/options.json new file mode 100644 index 0000000000..a49374fb46 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/484/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Binding eval in strict mode (1:9)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/485/actual.js b/packages/babylon/test/fixtures/core/uncategorised/485/actual.js new file mode 100644 index 0000000000..3dca413033 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/485/actual.js @@ -0,0 +1 @@ +function arguments() {'use strict'; } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/485/options.json b/packages/babylon/test/fixtures/core/uncategorised/485/options.json new file mode 100644 index 0000000000..8a3871a0d1 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/485/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Binding arguments in strict mode (1:9)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/486/actual.js b/packages/babylon/test/fixtures/core/uncategorised/486/actual.js new file mode 100644 index 0000000000..94168d78f9 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/486/actual.js @@ -0,0 +1 @@ +function hello() {'use strict'; (function eval() { }()) } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/486/options.json b/packages/babylon/test/fixtures/core/uncategorised/486/options.json new file mode 100644 index 0000000000..9c41225e97 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/486/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Binding eval in strict mode (1:42)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/487/actual.js b/packages/babylon/test/fixtures/core/uncategorised/487/actual.js new file mode 100644 index 0000000000..6f869d7a5a --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/487/actual.js @@ -0,0 +1 @@ +function hello() {'use strict'; (function arguments() { }()) } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/487/options.json b/packages/babylon/test/fixtures/core/uncategorised/487/options.json new file mode 100644 index 0000000000..bc7c65ae7b --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/487/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Binding arguments in strict mode (1:42)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/488/actual.js b/packages/babylon/test/fixtures/core/uncategorised/488/actual.js new file mode 100644 index 0000000000..52727a1991 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/488/actual.js @@ -0,0 +1 @@ +(function eval() {'use strict'; })() \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/488/options.json b/packages/babylon/test/fixtures/core/uncategorised/488/options.json new file mode 100644 index 0000000000..0dcd2b3e58 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/488/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Binding eval in strict mode (1:10)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/489/actual.js b/packages/babylon/test/fixtures/core/uncategorised/489/actual.js new file mode 100644 index 0000000000..485202cf6c --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/489/actual.js @@ -0,0 +1 @@ +(function arguments() {'use strict'; })() \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/489/options.json b/packages/babylon/test/fixtures/core/uncategorised/489/options.json new file mode 100644 index 0000000000..57ba0014b4 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/489/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Binding arguments in strict mode (1:10)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/49/actual.js b/packages/babylon/test/fixtures/core/uncategorised/49/actual.js new file mode 100644 index 0000000000..853fe1bde5 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/49/actual.js @@ -0,0 +1,5 @@ +/* multiline +comment +should +be +ignored */ 42 \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/49/expected.json b/packages/babylon/test/fixtures/core/uncategorised/49/expected.json new file mode 100644 index 0000000000..ca9afb0826 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/49/expected.json @@ -0,0 +1,42 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "Literal", + "value": 42, + "loc": { + "start": { + "line": 5, + "column": 11 + }, + "end": { + "line": 5, + "column": 13 + } + } + }, + "loc": { + "start": { + "line": 5, + "column": 11 + }, + "end": { + "line": 5, + "column": 13 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 5, + "column": 13 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/490/actual.js b/packages/babylon/test/fixtures/core/uncategorised/490/actual.js new file mode 100644 index 0000000000..baf4d38c20 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/490/actual.js @@ -0,0 +1 @@ +function hello() {'use strict'; ({ s: function eval() { } }); } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/490/options.json b/packages/babylon/test/fixtures/core/uncategorised/490/options.json new file mode 100644 index 0000000000..52cc5e0c10 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/490/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Binding eval in strict mode (1:47)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/491/actual.js b/packages/babylon/test/fixtures/core/uncategorised/491/actual.js new file mode 100644 index 0000000000..c915ef6ce3 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/491/actual.js @@ -0,0 +1 @@ +(function package() {'use strict'; })() \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/491/options.json b/packages/babylon/test/fixtures/core/uncategorised/491/options.json new file mode 100644 index 0000000000..94e937fa7c --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/491/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Binding package in strict mode (1:10)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/492/actual.js b/packages/babylon/test/fixtures/core/uncategorised/492/actual.js new file mode 100644 index 0000000000..2a69fbaf93 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/492/actual.js @@ -0,0 +1 @@ +function hello() {'use strict'; ({ i: 10, set s(eval) { } }); } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/492/options.json b/packages/babylon/test/fixtures/core/uncategorised/492/options.json new file mode 100644 index 0000000000..d6f5d89ca6 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/492/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Binding eval in strict mode (1:48)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/493/actual.js b/packages/babylon/test/fixtures/core/uncategorised/493/actual.js new file mode 100644 index 0000000000..82df3d8d31 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/493/actual.js @@ -0,0 +1 @@ +function hello() {'use strict'; ({ set s(eval) { } }); } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/493/options.json b/packages/babylon/test/fixtures/core/uncategorised/493/options.json new file mode 100644 index 0000000000..74aee2c177 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/493/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Binding eval in strict mode (1:41)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/494/actual.js b/packages/babylon/test/fixtures/core/uncategorised/494/actual.js new file mode 100644 index 0000000000..411cc11c36 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/494/actual.js @@ -0,0 +1 @@ +function hello() {'use strict'; ({ s: function s(eval) { } }); } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/494/options.json b/packages/babylon/test/fixtures/core/uncategorised/494/options.json new file mode 100644 index 0000000000..c181de42a2 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/494/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Binding eval in strict mode (1:49)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/495/actual.js b/packages/babylon/test/fixtures/core/uncategorised/495/actual.js new file mode 100644 index 0000000000..80fa1293cf --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/495/actual.js @@ -0,0 +1 @@ +function hello(eval) {'use strict';} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/495/options.json b/packages/babylon/test/fixtures/core/uncategorised/495/options.json new file mode 100644 index 0000000000..8de33328ad --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/495/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Binding eval in strict mode (1:15)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/496/actual.js b/packages/babylon/test/fixtures/core/uncategorised/496/actual.js new file mode 100644 index 0000000000..0dd1babdf1 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/496/actual.js @@ -0,0 +1 @@ +function hello(arguments) {'use strict';} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/496/options.json b/packages/babylon/test/fixtures/core/uncategorised/496/options.json new file mode 100644 index 0000000000..e2b36a2437 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/496/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Binding arguments in strict mode (1:15)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/497/actual.js b/packages/babylon/test/fixtures/core/uncategorised/497/actual.js new file mode 100644 index 0000000000..44fbababe4 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/497/actual.js @@ -0,0 +1 @@ +function hello() { 'use strict'; function inner(eval) {} } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/497/options.json b/packages/babylon/test/fixtures/core/uncategorised/497/options.json new file mode 100644 index 0000000000..d6f5d89ca6 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/497/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Binding eval in strict mode (1:48)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/498/actual.js b/packages/babylon/test/fixtures/core/uncategorised/498/actual.js new file mode 100644 index 0000000000..92c45ed52b --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/498/actual.js @@ -0,0 +1 @@ +function hello() { 'use strict'; function inner(arguments) {} } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/498/options.json b/packages/babylon/test/fixtures/core/uncategorised/498/options.json new file mode 100644 index 0000000000..8ee11e66ca --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/498/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Binding arguments in strict mode (1:48)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/499/actual.js b/packages/babylon/test/fixtures/core/uncategorised/499/actual.js new file mode 100644 index 0000000000..b86f21808d --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/499/actual.js @@ -0,0 +1 @@ +function hello() { 'use strict'; "\1"; } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/499/options.json b/packages/babylon/test/fixtures/core/uncategorised/499/options.json new file mode 100644 index 0000000000..68bfd75832 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/499/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Octal literal in strict mode (1:34)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/5/actual.js b/packages/babylon/test/fixtures/core/uncategorised/5/actual.js new file mode 100644 index 0000000000..830ebe5988 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/5/actual.js @@ -0,0 +1 @@ +/[a-z]/g \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/5/expected.json b/packages/babylon/test/fixtures/core/uncategorised/5/expected.json new file mode 100644 index 0000000000..aa77955d92 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/5/expected.json @@ -0,0 +1,25 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "Literal", + "regex": { + "pattern": "[a-z]", + "flags": "g" + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 8 + } + } + } + } + ] +} diff --git a/packages/babylon/test/fixtures/core/uncategorised/50/actual.js b/packages/babylon/test/fixtures/core/uncategorised/50/actual.js new file mode 100644 index 0000000000..8b7c235cef --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/50/actual.js @@ -0,0 +1,2 @@ +/*a +b*/ 42 \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/50/expected.json b/packages/babylon/test/fixtures/core/uncategorised/50/expected.json new file mode 100644 index 0000000000..49c20f9569 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/50/expected.json @@ -0,0 +1,42 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "Literal", + "value": 42, + "loc": { + "start": { + "line": 2, + "column": 4 + }, + "end": { + "line": 2, + "column": 6 + } + } + }, + "loc": { + "start": { + "line": 2, + "column": 4 + }, + "end": { + "line": 2, + "column": 6 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 2, + "column": 6 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/500/actual.js b/packages/babylon/test/fixtures/core/uncategorised/500/actual.js new file mode 100644 index 0000000000..4545763c31 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/500/actual.js @@ -0,0 +1 @@ +function hello() { 'use strict'; 021; } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/500/options.json b/packages/babylon/test/fixtures/core/uncategorised/500/options.json new file mode 100644 index 0000000000..3711f38eef --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/500/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Invalid number (1:33)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/501/actual.js b/packages/babylon/test/fixtures/core/uncategorised/501/actual.js new file mode 100644 index 0000000000..8994ebca78 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/501/actual.js @@ -0,0 +1 @@ +function hello() { 'use strict'; ({ "\1": 42 }); } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/501/options.json b/packages/babylon/test/fixtures/core/uncategorised/501/options.json new file mode 100644 index 0000000000..fa3a33b55e --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/501/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Octal literal in strict mode (1:37)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/502/actual.js b/packages/babylon/test/fixtures/core/uncategorised/502/actual.js new file mode 100644 index 0000000000..2eeb8bb5f7 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/502/actual.js @@ -0,0 +1 @@ +function hello() { 'use strict'; ({ 021: 42 }); } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/502/options.json b/packages/babylon/test/fixtures/core/uncategorised/502/options.json new file mode 100644 index 0000000000..a864ada0fe --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/502/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Invalid number (1:36)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/503/actual.js b/packages/babylon/test/fixtures/core/uncategorised/503/actual.js new file mode 100644 index 0000000000..95fe09f25b --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/503/actual.js @@ -0,0 +1 @@ +function hello() { "use strict"; function inner() { "octal directive\1"; } } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/503/options.json b/packages/babylon/test/fixtures/core/uncategorised/503/options.json new file mode 100644 index 0000000000..e689079a79 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/503/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Octal literal in strict mode (1:68)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/504/actual.js b/packages/babylon/test/fixtures/core/uncategorised/504/actual.js new file mode 100644 index 0000000000..3df9ff10be --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/504/actual.js @@ -0,0 +1 @@ +function hello() { "use strict"; var implements; } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/504/options.json b/packages/babylon/test/fixtures/core/uncategorised/504/options.json new file mode 100644 index 0000000000..a130c92268 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/504/options.json @@ -0,0 +1,3 @@ +{ + "throws": "The keyword 'implements' is reserved (1:37)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/505/actual.js b/packages/babylon/test/fixtures/core/uncategorised/505/actual.js new file mode 100644 index 0000000000..faf5c1e8bb --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/505/actual.js @@ -0,0 +1 @@ +function hello() { "use strict"; var interface; } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/505/options.json b/packages/babylon/test/fixtures/core/uncategorised/505/options.json new file mode 100644 index 0000000000..c70c06968d --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/505/options.json @@ -0,0 +1,3 @@ +{ + "throws": "The keyword 'interface' is reserved (1:37)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/506/actual.js b/packages/babylon/test/fixtures/core/uncategorised/506/actual.js new file mode 100644 index 0000000000..aa60af3350 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/506/actual.js @@ -0,0 +1 @@ +function hello() { "use strict"; var package; } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/506/options.json b/packages/babylon/test/fixtures/core/uncategorised/506/options.json new file mode 100644 index 0000000000..ac7ab9bdb7 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/506/options.json @@ -0,0 +1,3 @@ +{ + "throws": "The keyword 'package' is reserved (1:37)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/507/actual.js b/packages/babylon/test/fixtures/core/uncategorised/507/actual.js new file mode 100644 index 0000000000..1cacf74021 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/507/actual.js @@ -0,0 +1 @@ +function hello() { "use strict"; var private; } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/507/options.json b/packages/babylon/test/fixtures/core/uncategorised/507/options.json new file mode 100644 index 0000000000..735d540526 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/507/options.json @@ -0,0 +1,3 @@ +{ + "throws": "The keyword 'private' is reserved (1:37)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/508/actual.js b/packages/babylon/test/fixtures/core/uncategorised/508/actual.js new file mode 100644 index 0000000000..319c7f2258 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/508/actual.js @@ -0,0 +1 @@ +function hello() { "use strict"; var protected; } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/508/options.json b/packages/babylon/test/fixtures/core/uncategorised/508/options.json new file mode 100644 index 0000000000..a8145dcb6a --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/508/options.json @@ -0,0 +1,3 @@ +{ + "throws": "The keyword 'protected' is reserved (1:37)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/509/actual.js b/packages/babylon/test/fixtures/core/uncategorised/509/actual.js new file mode 100644 index 0000000000..f799df4f96 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/509/actual.js @@ -0,0 +1 @@ +function hello() { "use strict"; var public; } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/509/options.json b/packages/babylon/test/fixtures/core/uncategorised/509/options.json new file mode 100644 index 0000000000..232b3cba94 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/509/options.json @@ -0,0 +1,3 @@ +{ + "throws": "The keyword 'public' is reserved (1:37)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/51/actual.js b/packages/babylon/test/fixtures/core/uncategorised/51/actual.js new file mode 100644 index 0000000000..72e3074d9b --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/51/actual.js @@ -0,0 +1 @@ +/*a b*/ 42 \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/51/expected.json b/packages/babylon/test/fixtures/core/uncategorised/51/expected.json new file mode 100644 index 0000000000..49c20f9569 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/51/expected.json @@ -0,0 +1,42 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "Literal", + "value": 42, + "loc": { + "start": { + "line": 2, + "column": 4 + }, + "end": { + "line": 2, + "column": 6 + } + } + }, + "loc": { + "start": { + "line": 2, + "column": 4 + }, + "end": { + "line": 2, + "column": 6 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 2, + "column": 6 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/510/actual.js b/packages/babylon/test/fixtures/core/uncategorised/510/actual.js new file mode 100644 index 0000000000..5c389d874a --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/510/actual.js @@ -0,0 +1 @@ +function hello() { "use strict"; var static; } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/510/options.json b/packages/babylon/test/fixtures/core/uncategorised/510/options.json new file mode 100644 index 0000000000..47fe5aafaf --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/510/options.json @@ -0,0 +1,3 @@ +{ + "throws": "The keyword 'static' is reserved (1:37)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/511/actual.js b/packages/babylon/test/fixtures/core/uncategorised/511/actual.js new file mode 100644 index 0000000000..62445d1434 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/511/actual.js @@ -0,0 +1 @@ +function hello(static) { "use strict"; } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/511/options.json b/packages/babylon/test/fixtures/core/uncategorised/511/options.json new file mode 100644 index 0000000000..07a8c1c0f1 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/511/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Binding static in strict mode (1:15)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/512/actual.js b/packages/babylon/test/fixtures/core/uncategorised/512/actual.js new file mode 100644 index 0000000000..02d8601f79 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/512/actual.js @@ -0,0 +1 @@ +function static() { "use strict"; } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/512/options.json b/packages/babylon/test/fixtures/core/uncategorised/512/options.json new file mode 100644 index 0000000000..f7524a3327 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/512/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Binding static in strict mode (1:9)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/513/actual.js b/packages/babylon/test/fixtures/core/uncategorised/513/actual.js new file mode 100644 index 0000000000..dc3ed02faf --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/513/actual.js @@ -0,0 +1 @@ +"use strict"; function static() { } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/513/options.json b/packages/babylon/test/fixtures/core/uncategorised/513/options.json new file mode 100644 index 0000000000..07d74757d4 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/513/options.json @@ -0,0 +1,3 @@ +{ + "throws": "The keyword 'static' is reserved (1:23)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/514/actual.js b/packages/babylon/test/fixtures/core/uncategorised/514/actual.js new file mode 100644 index 0000000000..c2eebadb49 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/514/actual.js @@ -0,0 +1 @@ +function a(t, t) { "use strict"; } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/514/options.json b/packages/babylon/test/fixtures/core/uncategorised/514/options.json new file mode 100644 index 0000000000..421c28bbd6 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/514/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Argument name clash in strict mode (1:14)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/515/actual.js b/packages/babylon/test/fixtures/core/uncategorised/515/actual.js new file mode 100644 index 0000000000..8a9bf32f16 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/515/actual.js @@ -0,0 +1 @@ +function a(eval) { "use strict"; } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/515/options.json b/packages/babylon/test/fixtures/core/uncategorised/515/options.json new file mode 100644 index 0000000000..301643713f --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/515/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Binding eval in strict mode (1:11)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/516/actual.js b/packages/babylon/test/fixtures/core/uncategorised/516/actual.js new file mode 100644 index 0000000000..494a7853da --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/516/actual.js @@ -0,0 +1 @@ +function a(package) { "use strict"; } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/516/options.json b/packages/babylon/test/fixtures/core/uncategorised/516/options.json new file mode 100644 index 0000000000..31ebd9508d --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/516/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Binding package in strict mode (1:11)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/517/actual.js b/packages/babylon/test/fixtures/core/uncategorised/517/actual.js new file mode 100644 index 0000000000..151296549b --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/517/actual.js @@ -0,0 +1 @@ +function a() { "use strict"; function b(t, t) { }; } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/517/options.json b/packages/babylon/test/fixtures/core/uncategorised/517/options.json new file mode 100644 index 0000000000..9db3dfc50c --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/517/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Argument name clash in strict mode (1:43)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/518/actual.js b/packages/babylon/test/fixtures/core/uncategorised/518/actual.js new file mode 100644 index 0000000000..3b2a586acf --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/518/actual.js @@ -0,0 +1 @@ +(function a(t, t) { "use strict"; }) \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/518/options.json b/packages/babylon/test/fixtures/core/uncategorised/518/options.json new file mode 100644 index 0000000000..13e320a983 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/518/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Argument name clash in strict mode (1:15)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/519/actual.js b/packages/babylon/test/fixtures/core/uncategorised/519/actual.js new file mode 100644 index 0000000000..63bb595918 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/519/actual.js @@ -0,0 +1 @@ +function a() { "use strict"; (function b(t, t) { }); } \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/519/options.json b/packages/babylon/test/fixtures/core/uncategorised/519/options.json new file mode 100644 index 0000000000..0e4f27a823 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/519/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Argument name clash in strict mode (1:44)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/52/actual.js b/packages/babylon/test/fixtures/core/uncategorised/52/actual.js new file mode 100644 index 0000000000..224921a10f --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/52/actual.js @@ -0,0 +1,2 @@ +/*a +b*/ 42 \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/52/expected.json b/packages/babylon/test/fixtures/core/uncategorised/52/expected.json new file mode 100644 index 0000000000..49c20f9569 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/52/expected.json @@ -0,0 +1,42 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "Literal", + "value": 42, + "loc": { + "start": { + "line": 2, + "column": 4 + }, + "end": { + "line": 2, + "column": 6 + } + } + }, + "loc": { + "start": { + "line": 2, + "column": 4 + }, + "end": { + "line": 2, + "column": 6 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 2, + "column": 6 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/520/actual.js b/packages/babylon/test/fixtures/core/uncategorised/520/actual.js new file mode 100644 index 0000000000..c928b6fc97 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/520/actual.js @@ -0,0 +1 @@ +(function a(eval) { "use strict"; }) \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/520/options.json b/packages/babylon/test/fixtures/core/uncategorised/520/options.json new file mode 100644 index 0000000000..c9df15d6ef --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/520/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Binding eval in strict mode (1:12)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/521/actual.js b/packages/babylon/test/fixtures/core/uncategorised/521/actual.js new file mode 100644 index 0000000000..d7ffe8186e --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/521/actual.js @@ -0,0 +1 @@ +(function a(package) { "use strict"; }) \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/521/options.json b/packages/babylon/test/fixtures/core/uncategorised/521/options.json new file mode 100644 index 0000000000..87abf59529 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/521/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Binding package in strict mode (1:12)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/522/actual.js b/packages/babylon/test/fixtures/core/uncategorised/522/actual.js new file mode 100644 index 0000000000..2b0d03a6fc --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/522/actual.js @@ -0,0 +1 @@ +"use strict";function foo(){"use strict";}function bar(){var v = 015} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/522/options.json b/packages/babylon/test/fixtures/core/uncategorised/522/options.json new file mode 100644 index 0000000000..60bb6527f8 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/522/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Invalid number (1:65)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/523/actual.js b/packages/babylon/test/fixtures/core/uncategorised/523/actual.js new file mode 100644 index 0000000000..8850706c9b --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/523/actual.js @@ -0,0 +1 @@ +var this = 10; \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/523/options.json b/packages/babylon/test/fixtures/core/uncategorised/523/options.json new file mode 100644 index 0000000000..9f7910a413 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/523/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unexpected token (1:4)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/524/actual.js b/packages/babylon/test/fixtures/core/uncategorised/524/actual.js new file mode 100644 index 0000000000..3c7f409aa8 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/524/actual.js @@ -0,0 +1,2 @@ +throw +10; \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/524/options.json b/packages/babylon/test/fixtures/core/uncategorised/524/options.json new file mode 100644 index 0000000000..5ba39437b2 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/524/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Illegal newline after throw (1:5)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/525/actual.js b/packages/babylon/test/fixtures/core/uncategorised/525/actual.js new file mode 100644 index 0000000000..4ebc2e540c --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/525/actual.js @@ -0,0 +1 @@ +let x \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/525/expected.json b/packages/babylon/test/fixtures/core/uncategorised/525/expected.json new file mode 100644 index 0000000000..92d600816e --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/525/expected.json @@ -0,0 +1,59 @@ +{ + "type": "Program", + "body": [ + { + "type": "VariableDeclaration", + "declarations": [ + { + "type": "VariableDeclarator", + "id": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "init": null, + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 5 + } + } + } + ], + "kind": "let", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 5 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 5 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/526/actual.js b/packages/babylon/test/fixtures/core/uncategorised/526/actual.js new file mode 100644 index 0000000000..fb288edf07 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/526/actual.js @@ -0,0 +1 @@ +let x, y; \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/526/expected.json b/packages/babylon/test/fixtures/core/uncategorised/526/expected.json new file mode 100644 index 0000000000..23e1036f30 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/526/expected.json @@ -0,0 +1,87 @@ +{ + "type": "Program", + "body": [ + { + "type": "VariableDeclaration", + "declarations": [ + { + "type": "VariableDeclarator", + "id": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "init": null, + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + { + "type": "VariableDeclarator", + "id": { + "type": "Identifier", + "name": "y", + "loc": { + "start": { + "line": 1, + "column": 7 + }, + "end": { + "line": 1, + "column": 8 + } + } + }, + "init": null, + "loc": { + "start": { + "line": 1, + "column": 7 + }, + "end": { + "line": 1, + "column": 8 + } + } + } + ], + "kind": "let", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 9 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/527/actual.js b/packages/babylon/test/fixtures/core/uncategorised/527/actual.js new file mode 100644 index 0000000000..91c93b0951 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/527/actual.js @@ -0,0 +1 @@ +let x = 42 \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/527/expected.json b/packages/babylon/test/fixtures/core/uncategorised/527/expected.json new file mode 100644 index 0000000000..ef0172b830 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/527/expected.json @@ -0,0 +1,72 @@ +{ + "type": "Program", + "body": [ + { + "type": "VariableDeclaration", + "declarations": [ + { + "type": "VariableDeclarator", + "id": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "init": { + "type": "Literal", + "value": 42, + "loc": { + "start": { + "line": 1, + "column": 8 + }, + "end": { + "line": 1, + "column": 10 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 10 + } + } + } + ], + "kind": "let", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 10 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 10 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/528/actual.js b/packages/babylon/test/fixtures/core/uncategorised/528/actual.js new file mode 100644 index 0000000000..b975fd5f6e --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/528/actual.js @@ -0,0 +1 @@ +let eval = 42, arguments = 42 \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/528/expected.json b/packages/babylon/test/fixtures/core/uncategorised/528/expected.json new file mode 100644 index 0000000000..0b1e13d7a6 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/528/expected.json @@ -0,0 +1,113 @@ +{ + "type": "Program", + "body": [ + { + "type": "VariableDeclaration", + "declarations": [ + { + "type": "VariableDeclarator", + "id": { + "type": "Identifier", + "name": "eval", + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 8 + } + } + }, + "init": { + "type": "Literal", + "value": 42, + "loc": { + "start": { + "line": 1, + "column": 11 + }, + "end": { + "line": 1, + "column": 13 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 13 + } + } + }, + { + "type": "VariableDeclarator", + "id": { + "type": "Identifier", + "name": "arguments", + "loc": { + "start": { + "line": 1, + "column": 15 + }, + "end": { + "line": 1, + "column": 24 + } + } + }, + "init": { + "type": "Literal", + "value": 42, + "loc": { + "start": { + "line": 1, + "column": 27 + }, + "end": { + "line": 1, + "column": 29 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 15 + }, + "end": { + "line": 1, + "column": 29 + } + } + } + ], + "kind": "let", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 29 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 29 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/529/actual.js b/packages/babylon/test/fixtures/core/uncategorised/529/actual.js new file mode 100644 index 0000000000..33a4932113 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/529/actual.js @@ -0,0 +1 @@ +let x = 14, y = 3, z = 1977 \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/529/expected.json b/packages/babylon/test/fixtures/core/uncategorised/529/expected.json new file mode 100644 index 0000000000..89542fd62d --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/529/expected.json @@ -0,0 +1,154 @@ +{ + "type": "Program", + "body": [ + { + "type": "VariableDeclaration", + "declarations": [ + { + "type": "VariableDeclarator", + "id": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 5 + } + } + }, + "init": { + "type": "Literal", + "value": 14, + "loc": { + "start": { + "line": 1, + "column": 8 + }, + "end": { + "line": 1, + "column": 10 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 10 + } + } + }, + { + "type": "VariableDeclarator", + "id": { + "type": "Identifier", + "name": "y", + "loc": { + "start": { + "line": 1, + "column": 12 + }, + "end": { + "line": 1, + "column": 13 + } + } + }, + "init": { + "type": "Literal", + "value": 3, + "loc": { + "start": { + "line": 1, + "column": 16 + }, + "end": { + "line": 1, + "column": 17 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 12 + }, + "end": { + "line": 1, + "column": 17 + } + } + }, + { + "type": "VariableDeclarator", + "id": { + "type": "Identifier", + "name": "z", + "loc": { + "start": { + "line": 1, + "column": 19 + }, + "end": { + "line": 1, + "column": 20 + } + } + }, + "init": { + "type": "Literal", + "value": 1977, + "loc": { + "start": { + "line": 1, + "column": 23 + }, + "end": { + "line": 1, + "column": 27 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 19 + }, + "end": { + "line": 1, + "column": 27 + } + } + } + ], + "kind": "let", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 27 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 27 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/53/actual.js b/packages/babylon/test/fixtures/core/uncategorised/53/actual.js new file mode 100644 index 0000000000..fb73f13ec8 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/53/actual.js @@ -0,0 +1,2 @@ +/*a +c*/ 42 \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/53/expected.json b/packages/babylon/test/fixtures/core/uncategorised/53/expected.json new file mode 100644 index 0000000000..49c20f9569 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/53/expected.json @@ -0,0 +1,42 @@ +{ + "type": "Program", + "body": [ + { + "type": "ExpressionStatement", + "expression": { + "type": "Literal", + "value": 42, + "loc": { + "start": { + "line": 2, + "column": 4 + }, + "end": { + "line": 2, + "column": 6 + } + } + }, + "loc": { + "start": { + "line": 2, + "column": 4 + }, + "end": { + "line": 2, + "column": 6 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 2, + "column": 6 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/530/actual.js b/packages/babylon/test/fixtures/core/uncategorised/530/actual.js new file mode 100644 index 0000000000..ee8093a6da --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/530/actual.js @@ -0,0 +1 @@ +for(let x = 0;;); \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/530/expected.json b/packages/babylon/test/fixtures/core/uncategorised/530/expected.json new file mode 100644 index 0000000000..a4ed4afe19 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/530/expected.json @@ -0,0 +1,100 @@ +{ + "type": "Program", + "body": [ + { + "type": "ForStatement", + "init": { + "type": "VariableDeclaration", + "declarations": [ + { + "type": "VariableDeclarator", + "id": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 8 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + "init": { + "type": "Literal", + "value": 0, + "loc": { + "start": { + "line": 1, + "column": 12 + }, + "end": { + "line": 1, + "column": 13 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 8 + }, + "end": { + "line": 1, + "column": 13 + } + } + } + ], + "kind": "let", + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 13 + } + } + }, + "test": null, + "update": null, + "body": { + "type": "EmptyStatement", + "loc": { + "start": { + "line": 1, + "column": 16 + }, + "end": { + "line": 1, + "column": 17 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 17 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 17 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/531/actual.js b/packages/babylon/test/fixtures/core/uncategorised/531/actual.js new file mode 100644 index 0000000000..7e75605a68 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/531/actual.js @@ -0,0 +1 @@ +for(let x = 0, y = 1;;); \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/531/expected.json b/packages/babylon/test/fixtures/core/uncategorised/531/expected.json new file mode 100644 index 0000000000..592295c3a8 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/531/expected.json @@ -0,0 +1,141 @@ +{ + "type": "Program", + "body": [ + { + "type": "ForStatement", + "init": { + "type": "VariableDeclaration", + "declarations": [ + { + "type": "VariableDeclarator", + "id": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 8 + }, + "end": { + "line": 1, + "column": 9 + } + } + }, + "init": { + "type": "Literal", + "value": 0, + "loc": { + "start": { + "line": 1, + "column": 12 + }, + "end": { + "line": 1, + "column": 13 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 8 + }, + "end": { + "line": 1, + "column": 13 + } + } + }, + { + "type": "VariableDeclarator", + "id": { + "type": "Identifier", + "name": "y", + "loc": { + "start": { + "line": 1, + "column": 15 + }, + "end": { + "line": 1, + "column": 16 + } + } + }, + "init": { + "type": "Literal", + "value": 1, + "loc": { + "start": { + "line": 1, + "column": 19 + }, + "end": { + "line": 1, + "column": 20 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 15 + }, + "end": { + "line": 1, + "column": 20 + } + } + } + ], + "kind": "let", + "loc": { + "start": { + "line": 1, + "column": 4 + }, + "end": { + "line": 1, + "column": 20 + } + } + }, + "test": null, + "update": null, + "body": { + "type": "EmptyStatement", + "loc": { + "start": { + "line": 1, + "column": 23 + }, + "end": { + "line": 1, + "column": 24 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 24 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 24 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/532/actual.js b/packages/babylon/test/fixtures/core/uncategorised/532/actual.js new file mode 100644 index 0000000000..8cd8b58b54 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/532/actual.js @@ -0,0 +1 @@ +for (let x in list) process(x); \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/532/expected.json b/packages/babylon/test/fixtures/core/uncategorised/532/expected.json new file mode 100644 index 0000000000..33a700889e --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/532/expected.json @@ -0,0 +1,142 @@ +{ + "type": "Program", + "body": [ + { + "type": "ForInStatement", + "left": { + "type": "VariableDeclaration", + "declarations": [ + { + "type": "VariableDeclarator", + "id": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 9 + }, + "end": { + "line": 1, + "column": 10 + } + } + }, + "init": null, + "loc": { + "start": { + "line": 1, + "column": 9 + }, + "end": { + "line": 1, + "column": 10 + } + } + } + ], + "kind": "let", + "loc": { + "start": { + "line": 1, + "column": 5 + }, + "end": { + "line": 1, + "column": 10 + } + } + }, + "right": { + "type": "Identifier", + "name": "list", + "loc": { + "start": { + "line": 1, + "column": 14 + }, + "end": { + "line": 1, + "column": 18 + } + } + }, + "body": { + "type": "ExpressionStatement", + "expression": { + "type": "CallExpression", + "callee": { + "type": "Identifier", + "name": "process", + "loc": { + "start": { + "line": 1, + "column": 20 + }, + "end": { + "line": 1, + "column": 27 + } + } + }, + "arguments": [ + { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 28 + }, + "end": { + "line": 1, + "column": 29 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 20 + }, + "end": { + "line": 1, + "column": 30 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 20 + }, + "end": { + "line": 1, + "column": 31 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 31 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 31 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/533/actual.js b/packages/babylon/test/fixtures/core/uncategorised/533/actual.js new file mode 100644 index 0000000000..699d3a35bc --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/533/actual.js @@ -0,0 +1 @@ +const x = 42 \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/533/expected.json b/packages/babylon/test/fixtures/core/uncategorised/533/expected.json new file mode 100644 index 0000000000..ea08bc49d3 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/533/expected.json @@ -0,0 +1,72 @@ +{ + "type": "Program", + "body": [ + { + "type": "VariableDeclaration", + "declarations": [ + { + "type": "VariableDeclarator", + "id": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 6 + }, + "end": { + "line": 1, + "column": 7 + } + } + }, + "init": { + "type": "Literal", + "value": 42, + "loc": { + "start": { + "line": 1, + "column": 10 + }, + "end": { + "line": 1, + "column": 12 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 6 + }, + "end": { + "line": 1, + "column": 12 + } + } + } + ], + "kind": "const", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 12 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 12 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/534/actual.js b/packages/babylon/test/fixtures/core/uncategorised/534/actual.js new file mode 100644 index 0000000000..cbe1704cf6 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/534/actual.js @@ -0,0 +1 @@ +const eval = 42, arguments = 42 \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/534/expected.json b/packages/babylon/test/fixtures/core/uncategorised/534/expected.json new file mode 100644 index 0000000000..99349067f8 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/534/expected.json @@ -0,0 +1,113 @@ +{ + "type": "Program", + "body": [ + { + "type": "VariableDeclaration", + "declarations": [ + { + "type": "VariableDeclarator", + "id": { + "type": "Identifier", + "name": "eval", + "loc": { + "start": { + "line": 1, + "column": 6 + }, + "end": { + "line": 1, + "column": 10 + } + } + }, + "init": { + "type": "Literal", + "value": 42, + "loc": { + "start": { + "line": 1, + "column": 13 + }, + "end": { + "line": 1, + "column": 15 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 6 + }, + "end": { + "line": 1, + "column": 15 + } + } + }, + { + "type": "VariableDeclarator", + "id": { + "type": "Identifier", + "name": "arguments", + "loc": { + "start": { + "line": 1, + "column": 17 + }, + "end": { + "line": 1, + "column": 26 + } + } + }, + "init": { + "type": "Literal", + "value": 42, + "loc": { + "start": { + "line": 1, + "column": 29 + }, + "end": { + "line": 1, + "column": 31 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 17 + }, + "end": { + "line": 1, + "column": 31 + } + } + } + ], + "kind": "const", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 31 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 31 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/535/actual.js b/packages/babylon/test/fixtures/core/uncategorised/535/actual.js new file mode 100644 index 0000000000..ad5de9a65f --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/535/actual.js @@ -0,0 +1 @@ +const x = 14, y = 3, z = 1977 \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/535/expected.json b/packages/babylon/test/fixtures/core/uncategorised/535/expected.json new file mode 100644 index 0000000000..b8b28f2765 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/535/expected.json @@ -0,0 +1,154 @@ +{ + "type": "Program", + "body": [ + { + "type": "VariableDeclaration", + "declarations": [ + { + "type": "VariableDeclarator", + "id": { + "type": "Identifier", + "name": "x", + "loc": { + "start": { + "line": 1, + "column": 6 + }, + "end": { + "line": 1, + "column": 7 + } + } + }, + "init": { + "type": "Literal", + "value": 14, + "loc": { + "start": { + "line": 1, + "column": 10 + }, + "end": { + "line": 1, + "column": 12 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 6 + }, + "end": { + "line": 1, + "column": 12 + } + } + }, + { + "type": "VariableDeclarator", + "id": { + "type": "Identifier", + "name": "y", + "loc": { + "start": { + "line": 1, + "column": 14 + }, + "end": { + "line": 1, + "column": 15 + } + } + }, + "init": { + "type": "Literal", + "value": 3, + "loc": { + "start": { + "line": 1, + "column": 18 + }, + "end": { + "line": 1, + "column": 19 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 14 + }, + "end": { + "line": 1, + "column": 19 + } + } + }, + { + "type": "VariableDeclarator", + "id": { + "type": "Identifier", + "name": "z", + "loc": { + "start": { + "line": 1, + "column": 21 + }, + "end": { + "line": 1, + "column": 22 + } + } + }, + "init": { + "type": "Literal", + "value": 1977, + "loc": { + "start": { + "line": 1, + "column": 25 + }, + "end": { + "line": 1, + "column": 29 + } + } + }, + "loc": { + "start": { + "line": 1, + "column": 21 + }, + "end": { + "line": 1, + "column": 29 + } + } + } + ], + "kind": "const", + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 29 + } + } + } + ], + "loc": { + "start": { + "line": 1, + "column": 0 + }, + "end": { + "line": 1, + "column": 29 + } + } +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/536/actual.js b/packages/babylon/test/fixtures/core/uncategorised/536/actual.js new file mode 100644 index 0000000000..fc7d4f30cb --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/536/actual.js @@ -0,0 +1 @@ +const a; \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/536/options.json b/packages/babylon/test/fixtures/core/uncategorised/536/options.json new file mode 100644 index 0000000000..167116741e --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/536/options.json @@ -0,0 +1,3 @@ +{ + "throws": "Unexpected token (1:7)" +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/537/actual.js b/packages/babylon/test/fixtures/core/uncategorised/537/actual.js new file mode 100644 index 0000000000..216f6ebb0e --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/537/actual.js @@ -0,0 +1 @@ +for(const x = 0;;); \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/537/expected.json b/packages/babylon/test/fixtures/core/uncategorised/537/expected.json new file mode 100644 index 0000000000..8355722366 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/537/expected.json @@ -0,0 +1,58 @@ +{ + "type": "Program", + "body": [ + { + "type": "ForStatement", + "init": { + "type": "VariableDeclaration", + "declarations": [ + { + "type": "VariableDeclarator", + "id": { + "type": "Identifier", + "name": "x", + "range": [ + 10, + 11 + ] + }, + "init": { + "type": "Literal", + "value": 0, + "range": [ + 14, + 15 + ] + }, + "range": [ + 10, + 15 + ] + } + ], + "kind": "const", + "range": [ + 4, + 15 + ] + }, + "test": null, + "update": null, + "body": { + "type": "EmptyStatement", + "range": [ + 18, + 19 + ] + }, + "range": [ + 0, + 19 + ] + } + ], + "range": [ + 0, + 19 + ] +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/537/options.json b/packages/babylon/test/fixtures/core/uncategorised/537/options.json new file mode 100644 index 0000000000..de661f2aca --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/537/options.json @@ -0,0 +1,3 @@ +{ + "ranges": true +} \ No newline at end of file diff --git a/packages/babylon/test/fixtures/core/uncategorised/538/actual.js b/packages/babylon/test/fixtures/core/uncategorised/538/actual.js new file mode 100644 index 0000000000..ef75e32b40 --- /dev/null +++ b/packages/babylon/test/fixtures/core/uncategorised/538/actual.js @@ -0,0 +1,2 @@ +10;\n --> nothing", { - type: "Program", - body: [ - { - type: "ExpressionStatement", - expression: { - type: "AssignmentExpression", - operator: "=", - left: { - type: "Identifier", - name: "x" - }, - right: { - type: "BinaryExpression", - left: { - type: "UpdateExpression", - operator: "--", - prefix: false, - argument: { - type: "Identifier", - name: "y" - } - }, - operator: ">", - right: { - type: "Literal", - value: 10 - } - } - } - } - ] -}); - -test("'use strict';\nobject.static();", { - type: "Program", - body: [ - { - type: "ExpressionStatement", - expression: { - type: "Literal", - value: "use strict", - raw: "'use strict'" - } - }, - { - type: "ExpressionStatement", - expression: { - type: "CallExpression", - callee: { - type: "MemberExpression", - object: { - type: "Identifier", - name: "object" - }, - property: { - type: "Identifier", - name: "static" - }, - computed: false - }, - arguments: [] - } - } - ] -}); - -// Failure tests - -testFail("{", - "Unexpected token (1:1)"); - -testFail("}", - "Unexpected token (1:0)"); - -testFail("3ea", - "Invalid number (1:0)"); - -testFail("3in []", - "Identifier directly after number (1:1)"); - -testFail("3e", - "Invalid number (1:0)"); - -testFail("3e+", - "Invalid number (1:0)"); - -testFail("3e-", - "Invalid number (1:0)"); - -testFail("3x", - "Identifier directly after number (1:1)"); - -testFail("3x0", - "Identifier directly after number (1:1)"); - -testFail("0x", - "Expected number in radix 16 (1:2)"); - -testFail("09", - "Invalid number (1:0)"); - -testFail("018", - "Invalid number (1:0)"); - -testFail("01a", - "Identifier directly after number (1:2)"); - -testFail("3in[]", - "Identifier directly after number (1:1)"); - -testFail("0x3in[]", - "Identifier directly after number (1:3)"); - -testFail("\"Hello\nWorld\"", - "Unterminated string constant (1:0)"); - -testFail("x\\", - "Expecting Unicode escape sequence \\uXXXX (1:2)"); - -testFail("x\\u005c", - "Invalid Unicode escape (1:1)"); - -testFail("x\\u002a", - "Invalid Unicode escape (1:1)"); - -testFail("/", - "Unterminated regular expression (1:1)"); - -testFail("/test", - "Unterminated regular expression (1:1)"); - -testFail("var x = /[a-z]/\\ux", - "Bad character escape sequence (1:17)"); - -testFail("3 = 4", - "Assigning to rvalue (1:0)"); - -testFail("func() = 4", - "Assigning to rvalue (1:0)"); - -testFail("(1 + 1) = 10", - "Assigning to rvalue (1:1)"); - -testFail("1++", - "Assigning to rvalue (1:0)"); - -testFail("1--", - "Assigning to rvalue (1:0)"); - -testFail("++1", - "Assigning to rvalue (1:2)"); - -testFail("--1", - "Assigning to rvalue (1:2)"); - -testFail("for((1 + 1) in list) process(x);", - "Assigning to rvalue (1:5)"); - -testFail("[", - "Unexpected token (1:1)"); - -testFail("[,", - "Unexpected token (1:2)"); - -testFail("1 + {", - "Unexpected token (1:5)"); - -testFail("1 + { t:t ", - "Unexpected token (1:10)"); - -testFail("1 + { t:t,", - "Unexpected token (1:10)"); - -testFail("var x = /\n/", - "Unterminated regular expression (1:9)"); - -testFail("var x = \"\n", - "Unterminated string constant (1:8)"); - -testFail("var if = 42", - "Unexpected token (1:4)"); - -testFail("i + 2 = 42", - "Assigning to rvalue (1:0)"); - -testFail("+i = 42", - "Assigning to rvalue (1:0)"); - -testFail("1 + (", - "Unexpected token (1:5)"); - -testFail("\n\n\n{", - "Unexpected token (4:1)"); - -testFail("\n/* Some multiline\ncomment */\n)", - "Unexpected token (4:0)"); - -testFail("{ set 1 }", - "Unexpected token (1:6)"); - -testFail("{ get 2 }", - "Unexpected token (1:6)"); - -testFail("({ set: s(if) { } })", - "Unexpected token (1:10)"); - -testFail("({ set s(.) { } })", - "Unexpected token (1:9)"); - -testFail("({ set: s() { } })", - "Unexpected token (1:12)"); - -testFail("({ set: s(a, b) { } })", - "Unexpected token (1:16)"); - -testFail("({ get: g(d) { } })", - "Unexpected token (1:13)"); - -testFail("function t(...) { }", - "Unexpected token (1:14)"); - -testFail("function t(...rest, b) { }", - "Unexpected token (1:18)"); - -testFail("function t(if) { }", - "Unexpected token (1:11)"); - -testFail("function t(true) { }", - "Unexpected token (1:11)"); - -testFail("function t(false) { }", - "Unexpected token (1:11)"); - -testFail("function t(null) { }", - "Unexpected token (1:11)"); - -testFail("function null() { }", - "Unexpected token (1:9)"); - -testFail("function true() { }", - "Unexpected token (1:9)"); - -testFail("function false() { }", - "Unexpected token (1:9)"); - -testFail("function if() { }", - "Unexpected token (1:9)"); - -testFail("a b;", - "Unexpected token (1:2)"); - -testFail("if.a;", - "Unexpected token (1:2)"); - -testFail("a if;", - "Unexpected token (1:2)"); - -testFail("a class;", - "Unexpected token (1:2)"); - -testFail("break\n", - "Unsyntactic break (1:0)"); - -testFail("break 1;", - "Unexpected token (1:6)"); - -testFail("continue\n", - "Unsyntactic continue (1:0)"); - -testFail("continue 2;", - "Unexpected token (1:9)"); - -testFail("throw", - "Unexpected token (1:5)"); - -testFail("throw;", - "Unexpected token (1:5)"); - -testFail("for (var i, i2 in {});", - "Unexpected token (1:15)"); - -testFail("for ((i in {}));", - "Unexpected token (1:14)"); - -testFail("for (i + 1 in {});", - "Assigning to rvalue (1:5)"); - -testFail("for (+i in {});", - "Assigning to rvalue (1:5)"); - -testFail("if(false)", - "Unexpected token (1:9)"); - -testFail("if(false) doThis(); else", - "Unexpected token (1:24)"); - -testFail("do", - "Unexpected token (1:2)"); - -testFail("while(false)", - "Unexpected token (1:12)"); - -testFail("for(;;)", - "Unexpected token (1:7)"); - -testFail("with(x)", - "Unexpected token (1:7)"); - -testFail("try { }", - "Missing catch or finally clause (1:0)"); - -testFail("‿ = 10", - "Unexpected character '‿' (1:0)"); - -testFail("switch (c) { default: default: }", - "Multiple default clauses (1:22)"); - -testFail("new X().\"s\"", - "Unexpected token (1:8)"); - -testFail("/*", - "Unterminated comment (1:0)"); - -testFail("/*\n\n\n", - "Unterminated comment (1:0)"); - -testFail("/**", - "Unterminated comment (1:0)"); - -testFail("/*\n\n*", - "Unterminated comment (1:0)"); - -testFail("/*hello", - "Unterminated comment (1:0)"); - -testFail("/*hello *", - "Unterminated comment (1:0)"); - -testFail("\n]", - "Unexpected token (2:0)"); - -testFail("\r]", - "Unexpected token (2:0)"); - -testFail("\r\n]", - "Unexpected token (2:0)"); - -testFail("\n\r]", - "Unexpected token (3:0)"); - -testFail("//\r\n]", - "Unexpected token (2:0)"); - -testFail("//\n\r]", - "Unexpected token (3:0)"); - -testFail("/a\\\n/", - "Unterminated regular expression (1:1)"); - -testFail("//\r \n]", - "Unexpected token (3:0)"); - -testFail("/*\r\n*/]", - "Unexpected token (2:2)"); - -testFail("/*\n\r*/]", - "Unexpected token (3:2)"); - -testFail("/*\r \n*/]", - "Unexpected token (3:2)"); - -testFail("\\\\", - "Expecting Unicode escape sequence \\uXXXX (1:1)"); - -testFail("\\u005c", - "Invalid Unicode escape (1:0)"); - -testFail("\\x", - "Expecting Unicode escape sequence \\uXXXX (1:1)"); - -testFail("\\u0000", - "Invalid Unicode escape (1:0)"); - -testFail("‌ = []", - "Unexpected character '‌' (1:0)"); - -testFail("‍ = []", - "Unexpected character '‍' (1:0)"); - -testFail("\"\\", - "Unterminated string constant (1:0)"); - -testFail("\"\\u", - "Bad character escape sequence (1:3)"); - -testFail("return", - "'return' outside of function (1:0)"); - -testFail("break", - "Unsyntactic break (1:0)"); - -testFail("continue", - "Unsyntactic continue (1:0)"); - -testFail("switch (x) { default: continue; }", - "Unsyntactic continue (1:22)"); - -testFail("do { x } *", - "Unexpected token (1:9)"); - -testFail("while (true) { break x; }", - "Unsyntactic break (1:15)"); - -testFail("while (true) { continue x; }", - "Unsyntactic continue (1:15)"); - -testFail("x: while (true) { (function () { break x; }); }", - "Unsyntactic break (1:33)"); - -testFail("x: while (true) { (function () { continue x; }); }", - "Unsyntactic continue (1:33)"); - -testFail("x: while (true) { (function () { break; }); }", - "Unsyntactic break (1:33)"); - -testFail("x: while (true) { (function () { continue; }); }", - "Unsyntactic continue (1:33)"); - -testFail("x: while (true) { x: while (true) { } }", - "Label 'x' is already declared (1:18)"); - -testFail("(function () { 'use strict'; delete i; }())", - "Deleting local variable in strict mode (1:29)"); - -testFail("(function () { 'use strict'; with (i); }())", - "'with' in strict mode (1:29)"); - -testFail("function hello() {'use strict'; var eval = 10; }", - "Binding eval in strict mode (1:36)"); - -testFail("function hello() {'use strict'; var arguments = 10; }", - "Binding arguments in strict mode (1:36)"); - -testFail("function hello() {'use strict'; try { } catch (eval) { } }", - "Binding eval in strict mode (1:47)"); - -testFail("function hello() {'use strict'; try { } catch (arguments) { } }", - "Binding arguments in strict mode (1:47)"); - -testFail("function hello() {'use strict'; eval = 10; }", - "Assigning to eval in strict mode (1:32)"); - -testFail("function hello() {'use strict'; arguments = 10; }", - "Assigning to arguments in strict mode (1:32)"); - -testFail("function hello() {'use strict'; ++eval; }", - "Assigning to eval in strict mode (1:34)"); - -testFail("function hello() {'use strict'; --eval; }", - "Assigning to eval in strict mode (1:34)"); - -testFail("function hello() {'use strict'; ++arguments; }", - "Assigning to arguments in strict mode (1:34)"); - -testFail("function hello() {'use strict'; --arguments; }", - "Assigning to arguments in strict mode (1:34)"); - -testFail("function hello() {'use strict'; eval++; }", - "Assigning to eval in strict mode (1:32)"); - -testFail("function hello() {'use strict'; eval--; }", - "Assigning to eval in strict mode (1:32)"); - -testFail("function hello() {'use strict'; arguments++; }", - "Assigning to arguments in strict mode (1:32)"); - -testFail("function hello() {'use strict'; arguments--; }", - "Assigning to arguments in strict mode (1:32)"); - -testFail("function hello() {'use strict'; function eval() { } }", - "Binding eval in strict mode (1:41)"); - -testFail("function hello() {'use strict'; function arguments() { } }", - "Binding arguments in strict mode (1:41)"); - -testFail("function eval() {'use strict'; }", - "Binding eval in strict mode (1:9)"); - -testFail("function arguments() {'use strict'; }", - "Binding arguments in strict mode (1:9)"); - -testFail("function hello() {'use strict'; (function eval() { }()) }", - "Binding eval in strict mode (1:42)"); - -testFail("function hello() {'use strict'; (function arguments() { }()) }", - "Binding arguments in strict mode (1:42)"); - -testFail("(function eval() {'use strict'; })()", - "Binding eval in strict mode (1:10)"); - -testFail("(function arguments() {'use strict'; })()", - "Binding arguments in strict mode (1:10)"); - -testFail("function hello() {'use strict'; ({ s: function eval() { } }); }", - "Binding eval in strict mode (1:47)"); - -testFail("(function package() {'use strict'; })()", - "Binding package in strict mode (1:10)"); - -testFail("function hello() {'use strict'; ({ i: 10, set s(eval) { } }); }", - "Binding eval in strict mode (1:48)"); - -testFail("function hello() {'use strict'; ({ set s(eval) { } }); }", - "Binding eval in strict mode (1:41)"); - -testFail("function hello() {'use strict'; ({ s: function s(eval) { } }); }", - "Binding eval in strict mode (1:49)"); - -testFail("function hello(eval) {'use strict';}", - "Binding eval in strict mode (1:15)"); - -testFail("function hello(arguments) {'use strict';}", - "Binding arguments in strict mode (1:15)"); - -testFail("function hello() { 'use strict'; function inner(eval) {} }", - "Binding eval in strict mode (1:48)"); - -testFail("function hello() { 'use strict'; function inner(arguments) {} }", - "Binding arguments in strict mode (1:48)"); - -testFail("function hello() { 'use strict'; \"\\1\"; }", - "Octal literal in strict mode (1:34)"); - -testFail("function hello() { 'use strict'; 021; }", - "Invalid number (1:33)"); - -testFail("function hello() { 'use strict'; ({ \"\\1\": 42 }); }", - "Octal literal in strict mode (1:37)"); - -testFail("function hello() { 'use strict'; ({ 021: 42 }); }", - "Invalid number (1:36)"); - -testFail("function hello() { \"use strict\"; function inner() { \"octal directive\\1\"; } }", - "Octal literal in strict mode (1:68)"); - -testFail("function hello() { \"use strict\"; var implements; }", - "The keyword 'implements' is reserved (1:37)"); - -testFail("function hello() { \"use strict\"; var interface; }", - "The keyword 'interface' is reserved (1:37)"); - -testFail("function hello() { \"use strict\"; var package; }", - "The keyword 'package' is reserved (1:37)"); - -testFail("function hello() { \"use strict\"; var private; }", - "The keyword 'private' is reserved (1:37)"); - -testFail("function hello() { \"use strict\"; var protected; }", - "The keyword 'protected' is reserved (1:37)"); - -testFail("function hello() { \"use strict\"; var public; }", - "The keyword 'public' is reserved (1:37)"); - -testFail("function hello() { \"use strict\"; var static; }", - "The keyword 'static' is reserved (1:37)"); - -testFail("function hello(static) { \"use strict\"; }", - "Binding static in strict mode (1:15)"); - -testFail("function static() { \"use strict\"; }", - "Binding static in strict mode (1:9)"); - -testFail("\"use strict\"; function static() { }", - "The keyword 'static' is reserved (1:23)"); - -testFail("function a(t, t) { \"use strict\"; }", - "Argument name clash in strict mode (1:14)"); - -testFail("function a(eval) { \"use strict\"; }", - "Binding eval in strict mode (1:11)"); - -testFail("function a(package) { \"use strict\"; }", - "Binding package in strict mode (1:11)"); - -testFail("function a() { \"use strict\"; function b(t, t) { }; }", - "Argument name clash in strict mode (1:43)"); - -testFail("(function a(t, t) { \"use strict\"; })", - "Argument name clash in strict mode (1:15)"); - -testFail("function a() { \"use strict\"; (function b(t, t) { }); }", - "Argument name clash in strict mode (1:44)"); - -testFail("(function a(eval) { \"use strict\"; })", - "Binding eval in strict mode (1:12)"); - -testFail("(function a(package) { \"use strict\"; })", - "Binding package in strict mode (1:12)"); - -testFail("\"use strict\";function foo(){\"use strict\";}function bar(){var v = 015}", - "Invalid number (1:65)"); - -testFail("var this = 10;", "Unexpected token (1:4)"); - -testFail("throw\n10;", "Illegal newline after throw (1:5)"); - -// ECMA 6 support - -test("let x", { - type: "Program", - body: [ - { - type: "VariableDeclaration", - declarations: [ - { - type: "VariableDeclarator", - id: { - type: "Identifier", - name: "x", - loc: { - start: { - line: 1, - column: 4 - }, - end: { - line: 1, - column: 5 - } - } - }, - init: null, - loc: { - start: { - line: 1, - column: 4 - }, - end: { - line: 1, - column: 5 - } - } - } - ], - kind: "let", - loc: { - start: { - line: 1, - column: 0 - }, - end: { - line: 1, - column: 5 - } - } - } - ], - loc: { - start: { - line: 1, - column: 0 - }, - end: { - line: 1, - column: 5 - } - } -}, {locations: true}); - -test("let x, y;", { - type: "Program", - body: [ - { - type: "VariableDeclaration", - declarations: [ - { - type: "VariableDeclarator", - id: { - type: "Identifier", - name: "x", - loc: { - start: { - line: 1, - column: 4 - }, - end: { - line: 1, - column: 5 - } - } - }, - init: null, - loc: { - start: { - line: 1, - column: 4 - }, - end: { - line: 1, - column: 5 - } - } - }, - { - type: "VariableDeclarator", - id: { - type: "Identifier", - name: "y", - loc: { - start: { - line: 1, - column: 7 - }, - end: { - line: 1, - column: 8 - } - } - }, - init: null, - loc: { - start: { - line: 1, - column: 7 - }, - end: { - line: 1, - column: 8 - } - } - } - ], - kind: "let", - loc: { - start: { - line: 1, - column: 0 - }, - end: { - line: 1, - column: 9 - } - } - } - ], - loc: { - start: { - line: 1, - column: 0 - }, - end: { - line: 1, - column: 9 - } - } -}, {locations: true}); - -test("let x = 42", { - type: "Program", - body: [ - { - type: "VariableDeclaration", - declarations: [ - { - type: "VariableDeclarator", - id: { - type: "Identifier", - name: "x", - loc: { - start: { - line: 1, - column: 4 - }, - end: { - line: 1, - column: 5 - } - } - }, - init: { - type: "Literal", - value: 42, - loc: { - start: { - line: 1, - column: 8 - }, - end: { - line: 1, - column: 10 - } - } - }, - loc: { - start: { - line: 1, - column: 4 - }, - end: { - line: 1, - column: 10 - } - } - } - ], - kind: "let", - loc: { - start: { - line: 1, - column: 0 - }, - end: { - line: 1, - column: 10 - } - } - } - ], - loc: { - start: { - line: 1, - column: 0 - }, - end: { - line: 1, - column: 10 - } - } -}, {locations: true}); - -test("let eval = 42, arguments = 42", { - type: "Program", - body: [ - { - type: "VariableDeclaration", - declarations: [ - { - type: "VariableDeclarator", - id: { - type: "Identifier", - name: "eval", - loc: { - start: { - line: 1, - column: 4 - }, - end: { - line: 1, - column: 8 - } - } - }, - init: { - type: "Literal", - value: 42, - loc: { - start: { - line: 1, - column: 11 - }, - end: { - line: 1, - column: 13 - } - } - }, - loc: { - start: { - line: 1, - column: 4 - }, - end: { - line: 1, - column: 13 - } - } - }, - { - type: "VariableDeclarator", - id: { - type: "Identifier", - name: "arguments", - loc: { - start: { - line: 1, - column: 15 - }, - end: { - line: 1, - column: 24 - } - } - }, - init: { - type: "Literal", - value: 42, - loc: { - start: { - line: 1, - column: 27 - }, - end: { - line: 1, - column: 29 - } - } - }, - loc: { - start: { - line: 1, - column: 15 - }, - end: { - line: 1, - column: 29 - } - } - } - ], - kind: "let", - loc: { - start: { - line: 1, - column: 0 - }, - end: { - line: 1, - column: 29 - } - } - } - ], - loc: { - start: { - line: 1, - column: 0 - }, - end: { - line: 1, - column: 29 - } - } -}, {locations: true}); - -test("let x = 14, y = 3, z = 1977", { - type: "Program", - body: [ - { - type: "VariableDeclaration", - declarations: [ - { - type: "VariableDeclarator", - id: { - type: "Identifier", - name: "x", - loc: { - start: { - line: 1, - column: 4 - }, - end: { - line: 1, - column: 5 - } - } - }, - init: { - type: "Literal", - value: 14, - loc: { - start: { - line: 1, - column: 8 - }, - end: { - line: 1, - column: 10 - } - } - }, - loc: { - start: { - line: 1, - column: 4 - }, - end: { - line: 1, - column: 10 - } - } - }, - { - type: "VariableDeclarator", - id: { - type: "Identifier", - name: "y", - loc: { - start: { - line: 1, - column: 12 - }, - end: { - line: 1, - column: 13 - } - } - }, - init: { - type: "Literal", - value: 3, - loc: { - start: { - line: 1, - column: 16 - }, - end: { - line: 1, - column: 17 - } - } - }, - loc: { - start: { - line: 1, - column: 12 - }, - end: { - line: 1, - column: 17 - } - } - }, - { - type: "VariableDeclarator", - id: { - type: "Identifier", - name: "z", - loc: { - start: { - line: 1, - column: 19 - }, - end: { - line: 1, - column: 20 - } - } - }, - init: { - type: "Literal", - value: 1977, - loc: { - start: { - line: 1, - column: 23 - }, - end: { - line: 1, - column: 27 - } - } - }, - loc: { - start: { - line: 1, - column: 19 - }, - end: { - line: 1, - column: 27 - } - } - } - ], - kind: "let", - loc: { - start: { - line: 1, - column: 0 - }, - end: { - line: 1, - column: 27 - } - } - } - ], - loc: { - start: { - line: 1, - column: 0 - }, - end: { - line: 1, - column: 27 - } - } -}, {locations: true}); - -test("for(let x = 0;;);", { - type: "Program", - body: [ - { - type: "ForStatement", - init: { - type: "VariableDeclaration", - declarations: [ - { - type: "VariableDeclarator", - id: { - type: "Identifier", - name: "x", - loc: { - start: { - line: 1, - column: 8 - }, - end: { - line: 1, - column: 9 - } - } - }, - init: { - type: "Literal", - value: 0, - loc: { - start: { - line: 1, - column: 12 - }, - end: { - line: 1, - column: 13 - } - } - }, - loc: { - start: { - line: 1, - column: 8 - }, - end: { - line: 1, - column: 13 - } - } - } - ], - kind: "let", - loc: { - start: { - line: 1, - column: 4 - }, - end: { - line: 1, - column: 13 - } - } - }, - test: null, - update: null, - body: { - type: "EmptyStatement", - loc: { - start: { - line: 1, - column: 16 - }, - end: { - line: 1, - column: 17 - } - } - }, - loc: { - start: { - line: 1, - column: 0 - }, - end: { - line: 1, - column: 17 - } - } - } - ], - loc: { - start: { - line: 1, - column: 0 - }, - end: { - line: 1, - column: 17 - } - } -}, {locations: true}); - -test("for(let x = 0, y = 1;;);", { - type: "Program", - body: [ - { - type: "ForStatement", - init: { - type: "VariableDeclaration", - declarations: [ - { - type: "VariableDeclarator", - id: { - type: "Identifier", - name: "x", - loc: { - start: { - line: 1, - column: 8 - }, - end: { - line: 1, - column: 9 - } - } - }, - init: { - type: "Literal", - value: 0, - loc: { - start: { - line: 1, - column: 12 - }, - end: { - line: 1, - column: 13 - } - } - }, - loc: { - start: { - line: 1, - column: 8 - }, - end: { - line: 1, - column: 13 - } - } - }, - { - type: "VariableDeclarator", - id: { - type: "Identifier", - name: "y", - loc: { - start: { - line: 1, - column: 15 - }, - end: { - line: 1, - column: 16 - } - } - }, - init: { - type: "Literal", - value: 1, - loc: { - start: { - line: 1, - column: 19 - }, - end: { - line: 1, - column: 20 - } - } - }, - loc: { - start: { - line: 1, - column: 15 - }, - end: { - line: 1, - column: 20 - } - } - } - ], - kind: "let", - loc: { - start: { - line: 1, - column: 4 - }, - end: { - line: 1, - column: 20 - } - } - }, - test: null, - update: null, - body: { - type: "EmptyStatement", - loc: { - start: { - line: 1, - column: 23 - }, - end: { - line: 1, - column: 24 - } - } - }, - loc: { - start: { - line: 1, - column: 0 - }, - end: { - line: 1, - column: 24 - } - } - } - ], - loc: { - start: { - line: 1, - column: 0 - }, - end: { - line: 1, - column: 24 - } - } -}, {locations: true}); - -test("for (let x in list) process(x);", { - type: "Program", - body: [ - { - type: "ForInStatement", - left: { - type: "VariableDeclaration", - declarations: [ - { - type: "VariableDeclarator", - id: { - type: "Identifier", - name: "x", - loc: { - start: { - line: 1, - column: 9 - }, - end: { - line: 1, - column: 10 - } - } - }, - init: null, - loc: { - start: { - line: 1, - column: 9 - }, - end: { - line: 1, - column: 10 - } - } - } - ], - kind: "let", - loc: { - start: { - line: 1, - column: 5 - }, - end: { - line: 1, - column: 10 - } - } - }, - right: { - type: "Identifier", - name: "list", - loc: { - start: { - line: 1, - column: 14 - }, - end: { - line: 1, - column: 18 - } - } - }, - body: { - type: "ExpressionStatement", - expression: { - type: "CallExpression", - callee: { - type: "Identifier", - name: "process", - loc: { - start: { - line: 1, - column: 20 - }, - end: { - line: 1, - column: 27 - } - } - }, - arguments: [ - { - type: "Identifier", - name: "x", - loc: { - start: { - line: 1, - column: 28 - }, - end: { - line: 1, - column: 29 - } - } - } - ], - loc: { - start: { - line: 1, - column: 20 - }, - end: { - line: 1, - column: 30 - } - } - }, - loc: { - start: { - line: 1, - column: 20 - }, - end: { - line: 1, - column: 31 - } - } - }, - loc: { - start: { - line: 1, - column: 0 - }, - end: { - line: 1, - column: 31 - } - } - } - ], - loc: { - start: { - line: 1, - column: 0 - }, - end: { - line: 1, - column: 31 - } - } -}, {locations: true}); - -test("const x = 42", { - type: "Program", - body: [ - { - type: "VariableDeclaration", - declarations: [ - { - type: "VariableDeclarator", - id: { - type: "Identifier", - name: "x", - loc: { - start: { - line: 1, - column: 6 - }, - end: { - line: 1, - column: 7 - } - } - }, - init: { - type: "Literal", - value: 42, - loc: { - start: { - line: 1, - column: 10 - }, - end: { - line: 1, - column: 12 - } - } - }, - loc: { - start: { - line: 1, - column: 6 - }, - end: { - line: 1, - column: 12 - } - } - } - ], - kind: "const", - loc: { - start: { - line: 1, - column: 0 - }, - end: { - line: 1, - column: 12 - } - } - } - ], - loc: { - start: { - line: 1, - column: 0 - }, - end: { - line: 1, - column: 12 - } - } -}, {locations: true}); - -test("const eval = 42, arguments = 42", { - type: "Program", - body: [ - { - type: "VariableDeclaration", - declarations: [ - { - type: "VariableDeclarator", - id: { - type: "Identifier", - name: "eval", - loc: { - start: { - line: 1, - column: 6 - }, - end: { - line: 1, - column: 10 - } - } - }, - init: { - type: "Literal", - value: 42, - loc: { - start: { - line: 1, - column: 13 - }, - end: { - line: 1, - column: 15 - } - } - }, - loc: { - start: { - line: 1, - column: 6 - }, - end: { - line: 1, - column: 15 - } - } - }, - { - type: "VariableDeclarator", - id: { - type: "Identifier", - name: "arguments", - loc: { - start: { - line: 1, - column: 17 - }, - end: { - line: 1, - column: 26 - } - } - }, - init: { - type: "Literal", - value: 42, - loc: { - start: { - line: 1, - column: 29 - }, - end: { - line: 1, - column: 31 - } - } - }, - loc: { - start: { - line: 1, - column: 17 - }, - end: { - line: 1, - column: 31 - } - } - } - ], - kind: "const", - loc: { - start: { - line: 1, - column: 0 - }, - end: { - line: 1, - column: 31 - } - } - } - ], - loc: { - start: { - line: 1, - column: 0 - }, - end: { - line: 1, - column: 31 - } - } -}, {locations: true}); - -test("const x = 14, y = 3, z = 1977", { - type: "Program", - body: [ - { - type: "VariableDeclaration", - declarations: [ - { - type: "VariableDeclarator", - id: { - type: "Identifier", - name: "x", - loc: { - start: { - line: 1, - column: 6 - }, - end: { - line: 1, - column: 7 - } - } - }, - init: { - type: "Literal", - value: 14, - loc: { - start: { - line: 1, - column: 10 - }, - end: { - line: 1, - column: 12 - } - } - }, - loc: { - start: { - line: 1, - column: 6 - }, - end: { - line: 1, - column: 12 - } - } - }, - { - type: "VariableDeclarator", - id: { - type: "Identifier", - name: "y", - loc: { - start: { - line: 1, - column: 14 - }, - end: { - line: 1, - column: 15 - } - } - }, - init: { - type: "Literal", - value: 3, - loc: { - start: { - line: 1, - column: 18 - }, - end: { - line: 1, - column: 19 - } - } - }, - loc: { - start: { - line: 1, - column: 14 - }, - end: { - line: 1, - column: 19 - } - } - }, - { - type: "VariableDeclarator", - id: { - type: "Identifier", - name: "z", - loc: { - start: { - line: 1, - column: 21 - }, - end: { - line: 1, - column: 22 - } - } - }, - init: { - type: "Literal", - value: 1977, - loc: { - start: { - line: 1, - column: 25 - }, - end: { - line: 1, - column: 29 - } - } - }, - loc: { - start: { - line: 1, - column: 21 - }, - end: { - line: 1, - column: 29 - } - } - } - ], - kind: "const", - loc: { - start: { - line: 1, - column: 0 - }, - end: { - line: 1, - column: 29 - } - } - } - ], - loc: { - start: { - line: 1, - column: 0 - }, - end: { - line: 1, - column: 29 - } - } -}, {locations: true}); - -testFail("const a;", "Unexpected token (1:7)"); - -test("for(const x = 0;;);", { - type: "Program", - body: [{ - type: "ForStatement", - init: { - type: "VariableDeclaration", - declarations: [{ - type: "VariableDeclarator", - id: { - type: "Identifier", - name: "x", - range: [10, 11] - }, - init: { - type: "Literal", - value: 0, - range: [14, 15] - }, - range: [10, 15] - }], - kind: "const", - range: [4, 15] - }, - test: null, - update: null, - body: { - type: "EmptyStatement", - range: [18, 19] - }, - range: [0, 19] - }], - range: [0, 19] -}, {ranges: true}); - -// Assertion Tests - -test("