Fix invalid codegen for number member expr
This commit is contained in:
@@ -16,6 +16,11 @@ suite("generation", function () {
|
||||
assert.ok(t.VISITOR_KEYS[type], type + " should not exist");
|
||||
});
|
||||
});
|
||||
|
||||
test("valid code", function() {
|
||||
// Should not generate `0.foo`
|
||||
new Function(generate.default(t.memberExpression(t.numericLiteral(60702), t.identifier("foo"))).code);
|
||||
});
|
||||
});
|
||||
|
||||
var suites = require("babel-helper-fixtures").default(__dirname + "/fixtures");
|
||||
|
||||
Reference in New Issue
Block a user