mirror of
https://github.com/microsoft/TypeScript.git
synced 2026-02-15 20:25:23 -06:00
Add failing test for #8738
This commit is contained in:
parent
3f9efa039a
commit
81ee9687e7
@ -0,0 +1,20 @@
|
||||
//// [server.ts]
|
||||
|
||||
var foo = 2;
|
||||
foo = 3;
|
||||
|
||||
var baz = 3;
|
||||
baz = 4;
|
||||
|
||||
export { foo, baz, baz as quux };
|
||||
|
||||
|
||||
//// [server.js]
|
||||
"use strict";
|
||||
var foo = 2;
|
||||
exports.foo = foo;
|
||||
exports.foo = foo = 3;
|
||||
var baz = 3;
|
||||
exports.baz = baz;
|
||||
exports.quux = baz;
|
||||
exports.quux = exports.baz = baz = 4;
|
||||
@ -0,0 +1,20 @@
|
||||
=== tests/cases/compiler/server.ts ===
|
||||
|
||||
var foo = 2;
|
||||
>foo : Symbol(foo, Decl(server.ts, 1, 3))
|
||||
|
||||
foo = 3;
|
||||
>foo : Symbol(foo, Decl(server.ts, 1, 3))
|
||||
|
||||
var baz = 3;
|
||||
>baz : Symbol(baz, Decl(server.ts, 4, 3))
|
||||
|
||||
baz = 4;
|
||||
>baz : Symbol(baz, Decl(server.ts, 4, 3))
|
||||
|
||||
export { foo, baz, baz as quux };
|
||||
>foo : Symbol(foo, Decl(server.ts, 7, 8))
|
||||
>baz : Symbol(baz, Decl(server.ts, 7, 13))
|
||||
>baz : Symbol(quux, Decl(server.ts, 7, 18))
|
||||
>quux : Symbol(quux, Decl(server.ts, 7, 18))
|
||||
|
||||
@ -0,0 +1,26 @@
|
||||
=== tests/cases/compiler/server.ts ===
|
||||
|
||||
var foo = 2;
|
||||
>foo : number
|
||||
>2 : number
|
||||
|
||||
foo = 3;
|
||||
>foo = 3 : number
|
||||
>foo : number
|
||||
>3 : number
|
||||
|
||||
var baz = 3;
|
||||
>baz : number
|
||||
>3 : number
|
||||
|
||||
baz = 4;
|
||||
>baz = 4 : number
|
||||
>baz : number
|
||||
>4 : number
|
||||
|
||||
export { foo, baz, baz as quux };
|
||||
>foo : number
|
||||
>baz : number
|
||||
>baz : number
|
||||
>quux : number
|
||||
|
||||
11
tests/cases/compiler/es6ExportClauseWithAssignmentInEs5.ts
Normal file
11
tests/cases/compiler/es6ExportClauseWithAssignmentInEs5.ts
Normal file
@ -0,0 +1,11 @@
|
||||
// @target: es5
|
||||
// @module: commonjs
|
||||
|
||||
// @filename: server.ts
|
||||
var foo = 2;
|
||||
foo = 3;
|
||||
|
||||
var baz = 3;
|
||||
baz = 4;
|
||||
|
||||
export { foo, baz, baz as quux };
|
||||
Loading…
x
Reference in New Issue
Block a user