Merge remote-tracking branch 'origin/master' into emitImportsInDts
This commit is contained in:
commit
b033693947
|
@ -13,7 +13,7 @@ Issues that ask questions answered in the FAQ will be closed without elaboration
|
|||
## 3. Do you have a question?
|
||||
|
||||
The issue tracker is for **issues**, in other words, bugs and suggestions.
|
||||
If you have a *question*, please use [http://stackoverflow.com/questions/tagged/typescript](Stack Overflow), [https://gitter.im/Microsoft/TypeScript](Gitter), your favorite search engine, or other resources.
|
||||
If you have a *question*, please use [Stack Overflow](http://stackoverflow.com/questions/tagged/typescript), [Gitter](https://gitter.im/Microsoft/TypeScript), your favorite search engine, or other resources.
|
||||
Due to increased traffic, we can no longer answer questions in the issue tracker.
|
||||
|
||||
## 4. Did you find a bug?
|
||||
|
|
|
@ -1,7 +1,9 @@
|
|||
# Read This!
|
||||
|
||||
This directory contains miscellaneous documentation such as the TypeScript language specification and logo.
|
||||
If you are looking for more introductory material, you might want to take a look at the [TypeScript Handbook](https://github.com/Microsoft/TypeScript-Handbook).
|
||||
|
||||
# Spec Contributions
|
||||
|
||||
The specification is first authored as a Microsoft Word (docx) file and then generated into Markdown and PDF formats.
|
||||
Due to the binary format of docx files, and the merging difficulties that may come with it, it is preferred that any suggestions or problems found in the spec should be [filed as issues](https://github.com/Microsoft/TypeScript/issues/new) rather than sent as pull requests.
|
||||
Due to the binary format of docx files, and the merging difficulties that may come with it, it is preferred that **any suggestions or problems found in the spec should be [filed as issues](https://github.com/Microsoft/TypeScript/issues/new)** rather than sent as pull requests.
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
# Read this!
|
||||
# Read This!
|
||||
|
||||
These files are not meant to be edited by hand.
|
||||
If you need to make modifications, the respective files should be changed within the repository's top-level `src` directory. Running `jake LKG` will then appropriately update the files in this directory.
|
||||
**These files are not meant to be edited by hand.**
|
||||
If you need to make modifications, the respective files should be changed within the repository's top-level `src` directory.
|
||||
Running `jake LKG` will then appropriately update the files in this directory.
|
||||
|
|
|
@ -16214,7 +16214,7 @@ namespace ts {
|
|||
return grammarErrorOnNode(modifier, Diagnostics._0_modifier_must_precede_1_modifier, text, "async");
|
||||
}
|
||||
else if (node.parent.kind === SyntaxKind.ModuleBlock || node.parent.kind === SyntaxKind.SourceFile) {
|
||||
return grammarErrorOnNode(modifier, Diagnostics._0_modifier_cannot_appear_on_a_module_element, text);
|
||||
return grammarErrorOnNode(modifier, Diagnostics._0_modifier_cannot_appear_on_a_module_or_namespace_element, text);
|
||||
}
|
||||
else if (flags & NodeFlags.Abstract) {
|
||||
if (modifier.kind === SyntaxKind.PrivateKeyword) {
|
||||
|
@ -16238,7 +16238,7 @@ namespace ts {
|
|||
return grammarErrorOnNode(modifier, Diagnostics._0_modifier_must_precede_1_modifier, "static", "async");
|
||||
}
|
||||
else if (node.parent.kind === SyntaxKind.ModuleBlock || node.parent.kind === SyntaxKind.SourceFile) {
|
||||
return grammarErrorOnNode(modifier, Diagnostics._0_modifier_cannot_appear_on_a_module_element, "static");
|
||||
return grammarErrorOnNode(modifier, Diagnostics._0_modifier_cannot_appear_on_a_module_or_namespace_element, "static");
|
||||
}
|
||||
else if (node.kind === SyntaxKind.Parameter) {
|
||||
return grammarErrorOnNode(modifier, Diagnostics._0_modifier_cannot_appear_on_a_parameter, "static");
|
||||
|
|
|
@ -123,7 +123,7 @@
|
|||
"category": "Error",
|
||||
"code": 1043
|
||||
},
|
||||
"'{0}' modifier cannot appear on a module element.": {
|
||||
"'{0}' modifier cannot appear on a module or namespace element.": {
|
||||
"category": "Error",
|
||||
"code": 1044
|
||||
},
|
||||
|
@ -1279,10 +1279,6 @@
|
|||
"category": "Error",
|
||||
"code": 2417
|
||||
},
|
||||
"Type name '{0}' in extends clause does not reference constructor function for '{0}'.": {
|
||||
"category": "Error",
|
||||
"code": 2419
|
||||
},
|
||||
"Class '{0}' incorrectly implements interface '{1}'.": {
|
||||
"category": "Error",
|
||||
"code": 2420
|
||||
|
|
|
@ -2450,10 +2450,27 @@ namespace ts {
|
|||
if (token === SyntaxKind.LessThanToken) {
|
||||
return true;
|
||||
}
|
||||
|
||||
return token === SyntaxKind.OpenParenToken && lookAhead(isUnambiguouslyStartOfFunctionType);
|
||||
}
|
||||
|
||||
function skipParameterStart(): boolean {
|
||||
if (isModifierKind(token)) {
|
||||
// Skip modifiers
|
||||
parseModifiers();
|
||||
}
|
||||
if (isIdentifier()) {
|
||||
nextToken();
|
||||
return true;
|
||||
}
|
||||
if (token === SyntaxKind.OpenBracketToken || token === SyntaxKind.OpenBraceToken) {
|
||||
// Return true if we can parse an array or object binding pattern with no errors
|
||||
const previousErrorCount = parseDiagnostics.length;
|
||||
parseIdentifierOrPattern();
|
||||
return previousErrorCount === parseDiagnostics.length;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
function isUnambiguouslyStartOfFunctionType() {
|
||||
nextToken();
|
||||
if (token === SyntaxKind.CloseParenToken || token === SyntaxKind.DotDotDotToken) {
|
||||
|
@ -2461,22 +2478,21 @@ namespace ts {
|
|||
// ( ...
|
||||
return true;
|
||||
}
|
||||
if (isIdentifier() || isModifierKind(token)) {
|
||||
nextToken();
|
||||
if (skipParameterStart()) {
|
||||
// We successfully skipped modifiers (if any) and an identifier or binding pattern,
|
||||
// now see if we have something that indicates a parameter declaration
|
||||
if (token === SyntaxKind.ColonToken || token === SyntaxKind.CommaToken ||
|
||||
token === SyntaxKind.QuestionToken || token === SyntaxKind.EqualsToken ||
|
||||
isIdentifier() || isModifierKind(token)) {
|
||||
// ( id :
|
||||
// ( id ,
|
||||
// ( id ?
|
||||
// ( id =
|
||||
// ( modifier id
|
||||
token === SyntaxKind.QuestionToken || token === SyntaxKind.EqualsToken) {
|
||||
// ( xxx :
|
||||
// ( xxx ,
|
||||
// ( xxx ?
|
||||
// ( xxx =
|
||||
return true;
|
||||
}
|
||||
if (token === SyntaxKind.CloseParenToken) {
|
||||
nextToken();
|
||||
if (token === SyntaxKind.EqualsGreaterThanToken) {
|
||||
// ( id ) =>
|
||||
// ( xxx ) =>
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -16,6 +16,14 @@ namespace ts {
|
|||
}
|
||||
|
||||
let nullSourceMapWriter: SourceMapWriter;
|
||||
// Used for initialize lastEncodedSourceMapSpan and reset lastEncodedSourceMapSpan when updateLastEncodedAndRecordedSpans
|
||||
const defaultLastEncodedSourceMapSpan: SourceMapSpan = {
|
||||
emittedLine: 1,
|
||||
emittedColumn: 1,
|
||||
sourceLine: 1,
|
||||
sourceColumn: 1,
|
||||
sourceIndex: 0
|
||||
};
|
||||
|
||||
export function getNullSourceMapWriter(): SourceMapWriter {
|
||||
if (nullSourceMapWriter === undefined) {
|
||||
|
@ -79,13 +87,7 @@ namespace ts {
|
|||
|
||||
// Last recorded and encoded spans
|
||||
lastRecordedSourceMapSpan = undefined;
|
||||
lastEncodedSourceMapSpan = {
|
||||
emittedLine: 1,
|
||||
emittedColumn: 1,
|
||||
sourceLine: 1,
|
||||
sourceColumn: 1,
|
||||
sourceIndex: 0
|
||||
};
|
||||
lastEncodedSourceMapSpan = defaultLastEncodedSourceMapSpan;
|
||||
lastEncodedNameIndex = 0;
|
||||
|
||||
// Initialize source map data
|
||||
|
@ -159,10 +161,12 @@ namespace ts {
|
|||
// Pop sourceMapDecodedMappings to remove last entry
|
||||
sourceMapData.sourceMapDecodedMappings.pop();
|
||||
|
||||
// Change the last encoded source map
|
||||
// Point the lastEncodedSourceMapSpace to the previous encoded sourceMapSpan
|
||||
// If the list is empty which indicates that we are at the beginning of the file,
|
||||
// we have to reset it to default value (same value when we first initialize sourceMapWriter)
|
||||
lastEncodedSourceMapSpan = sourceMapData.sourceMapDecodedMappings.length ?
|
||||
sourceMapData.sourceMapDecodedMappings[sourceMapData.sourceMapDecodedMappings.length - 1] :
|
||||
undefined;
|
||||
defaultLastEncodedSourceMapSpan;
|
||||
|
||||
// TODO: Update lastEncodedNameIndex
|
||||
// Since we dont support this any more, lets not worry about it right now.
|
||||
|
|
|
@ -1,8 +1,8 @@
|
|||
tests/cases/conformance/parser/ecmascript5/Protected/Protected1.ts(1,1): error TS1044: 'protected' modifier cannot appear on a module element.
|
||||
tests/cases/conformance/parser/ecmascript5/Protected/Protected1.ts(1,1): error TS1044: 'protected' modifier cannot appear on a module or namespace element.
|
||||
|
||||
|
||||
==== tests/cases/conformance/parser/ecmascript5/Protected/Protected1.ts (1 errors) ====
|
||||
protected class C {
|
||||
~~~~~~~~~
|
||||
!!! error TS1044: 'protected' modifier cannot appear on a module element.
|
||||
!!! error TS1044: 'protected' modifier cannot appear on a module or namespace element.
|
||||
}
|
|
@ -1,8 +1,8 @@
|
|||
tests/cases/conformance/parser/ecmascript5/Protected/Protected2.ts(1,1): error TS1044: 'protected' modifier cannot appear on a module element.
|
||||
tests/cases/conformance/parser/ecmascript5/Protected/Protected2.ts(1,1): error TS1044: 'protected' modifier cannot appear on a module or namespace element.
|
||||
|
||||
|
||||
==== tests/cases/conformance/parser/ecmascript5/Protected/Protected2.ts (1 errors) ====
|
||||
protected module M {
|
||||
~~~~~~~~~
|
||||
!!! error TS1044: 'protected' modifier cannot appear on a module element.
|
||||
!!! error TS1044: 'protected' modifier cannot appear on a module or namespace element.
|
||||
}
|
61
tests/baselines/reference/destructuringInFunctionType.js
Normal file
61
tests/baselines/reference/destructuringInFunctionType.js
Normal file
|
@ -0,0 +1,61 @@
|
|||
//// [destructuringInFunctionType.ts]
|
||||
|
||||
interface a { a }
|
||||
interface b { b }
|
||||
interface c { c }
|
||||
|
||||
type T1 = ([a, b, c]);
|
||||
type F1 = ([a, b, c]) => void;
|
||||
|
||||
type T2 = ({ a });
|
||||
type F2 = ({ a }) => void;
|
||||
|
||||
type T3 = ([{ a: b }, { b: a }]);
|
||||
type F3 = ([{ a: b }, { b: a }]) => void;
|
||||
|
||||
type T4 = ([{ a: [b, c] }]);
|
||||
type F4 = ([{ a: [b, c] }]) => void;
|
||||
|
||||
type C1 = new ([{ a: [b, c] }]) => void;
|
||||
|
||||
var v1 = ([a, b, c]) => "hello";
|
||||
var v2: ([a, b, c]) => string;
|
||||
|
||||
|
||||
//// [destructuringInFunctionType.js]
|
||||
var v1 = function (_a) {
|
||||
var a = _a[0], b = _a[1], c = _a[2];
|
||||
return "hello";
|
||||
};
|
||||
var v2;
|
||||
|
||||
|
||||
//// [destructuringInFunctionType.d.ts]
|
||||
interface a {
|
||||
a: any;
|
||||
}
|
||||
interface b {
|
||||
b: any;
|
||||
}
|
||||
interface c {
|
||||
c: any;
|
||||
}
|
||||
declare type T1 = ([a, b, c]);
|
||||
declare type F1 = ([a, b, c]) => void;
|
||||
declare type T2 = ({
|
||||
a;
|
||||
});
|
||||
declare type F2 = ({a}) => void;
|
||||
declare type T3 = ([{
|
||||
a: b;
|
||||
}, {
|
||||
b: a;
|
||||
}]);
|
||||
declare type F3 = ([{a: b}, {b: a}]) => void;
|
||||
declare type T4 = ([{
|
||||
a: [b, c];
|
||||
}]);
|
||||
declare type F4 = ([{a: [b, c]}]) => void;
|
||||
declare type C1 = new ([{a: [b, c]}]) => void;
|
||||
declare var v1: ([a, b, c]: [any, any, any]) => string;
|
||||
declare var v2: ([a, b, c]) => string;
|
|
@ -0,0 +1,78 @@
|
|||
=== tests/cases/conformance/es6/destructuring/destructuringInFunctionType.ts ===
|
||||
|
||||
interface a { a }
|
||||
>a : Symbol(a, Decl(destructuringInFunctionType.ts, 0, 0))
|
||||
>a : Symbol(a, Decl(destructuringInFunctionType.ts, 1, 13))
|
||||
|
||||
interface b { b }
|
||||
>b : Symbol(b, Decl(destructuringInFunctionType.ts, 1, 17))
|
||||
>b : Symbol(b, Decl(destructuringInFunctionType.ts, 2, 13))
|
||||
|
||||
interface c { c }
|
||||
>c : Symbol(c, Decl(destructuringInFunctionType.ts, 2, 17))
|
||||
>c : Symbol(c, Decl(destructuringInFunctionType.ts, 3, 13))
|
||||
|
||||
type T1 = ([a, b, c]);
|
||||
>T1 : Symbol(T1, Decl(destructuringInFunctionType.ts, 3, 17))
|
||||
>a : Symbol(a, Decl(destructuringInFunctionType.ts, 0, 0))
|
||||
>b : Symbol(b, Decl(destructuringInFunctionType.ts, 1, 17))
|
||||
>c : Symbol(c, Decl(destructuringInFunctionType.ts, 2, 17))
|
||||
|
||||
type F1 = ([a, b, c]) => void;
|
||||
>F1 : Symbol(F1, Decl(destructuringInFunctionType.ts, 5, 22))
|
||||
>a : Symbol(a, Decl(destructuringInFunctionType.ts, 6, 12))
|
||||
>b : Symbol(b, Decl(destructuringInFunctionType.ts, 6, 14))
|
||||
>c : Symbol(c, Decl(destructuringInFunctionType.ts, 6, 17))
|
||||
|
||||
type T2 = ({ a });
|
||||
>T2 : Symbol(T2, Decl(destructuringInFunctionType.ts, 6, 30))
|
||||
>a : Symbol(a, Decl(destructuringInFunctionType.ts, 8, 12))
|
||||
|
||||
type F2 = ({ a }) => void;
|
||||
>F2 : Symbol(F2, Decl(destructuringInFunctionType.ts, 8, 18))
|
||||
>a : Symbol(a, Decl(destructuringInFunctionType.ts, 9, 12))
|
||||
|
||||
type T3 = ([{ a: b }, { b: a }]);
|
||||
>T3 : Symbol(T3, Decl(destructuringInFunctionType.ts, 9, 26))
|
||||
>a : Symbol(a, Decl(destructuringInFunctionType.ts, 11, 13))
|
||||
>b : Symbol(b, Decl(destructuringInFunctionType.ts, 1, 17))
|
||||
>b : Symbol(b, Decl(destructuringInFunctionType.ts, 11, 23))
|
||||
>a : Symbol(a, Decl(destructuringInFunctionType.ts, 0, 0))
|
||||
|
||||
type F3 = ([{ a: b }, { b: a }]) => void;
|
||||
>F3 : Symbol(F3, Decl(destructuringInFunctionType.ts, 11, 33))
|
||||
>a : Symbol(a)
|
||||
>b : Symbol(b, Decl(destructuringInFunctionType.ts, 12, 13))
|
||||
>b : Symbol(b)
|
||||
>a : Symbol(a, Decl(destructuringInFunctionType.ts, 12, 23))
|
||||
|
||||
type T4 = ([{ a: [b, c] }]);
|
||||
>T4 : Symbol(T4, Decl(destructuringInFunctionType.ts, 12, 41))
|
||||
>a : Symbol(a, Decl(destructuringInFunctionType.ts, 14, 13))
|
||||
>b : Symbol(b, Decl(destructuringInFunctionType.ts, 1, 17))
|
||||
>c : Symbol(c, Decl(destructuringInFunctionType.ts, 2, 17))
|
||||
|
||||
type F4 = ([{ a: [b, c] }]) => void;
|
||||
>F4 : Symbol(F4, Decl(destructuringInFunctionType.ts, 14, 28))
|
||||
>a : Symbol(a)
|
||||
>b : Symbol(b, Decl(destructuringInFunctionType.ts, 15, 18))
|
||||
>c : Symbol(c, Decl(destructuringInFunctionType.ts, 15, 20))
|
||||
|
||||
type C1 = new ([{ a: [b, c] }]) => void;
|
||||
>C1 : Symbol(C1, Decl(destructuringInFunctionType.ts, 15, 36))
|
||||
>a : Symbol(a)
|
||||
>b : Symbol(b, Decl(destructuringInFunctionType.ts, 17, 22))
|
||||
>c : Symbol(c, Decl(destructuringInFunctionType.ts, 17, 24))
|
||||
|
||||
var v1 = ([a, b, c]) => "hello";
|
||||
>v1 : Symbol(v1, Decl(destructuringInFunctionType.ts, 19, 3))
|
||||
>a : Symbol(a, Decl(destructuringInFunctionType.ts, 19, 11))
|
||||
>b : Symbol(b, Decl(destructuringInFunctionType.ts, 19, 13))
|
||||
>c : Symbol(c, Decl(destructuringInFunctionType.ts, 19, 16))
|
||||
|
||||
var v2: ([a, b, c]) => string;
|
||||
>v2 : Symbol(v2, Decl(destructuringInFunctionType.ts, 20, 3))
|
||||
>a : Symbol(a, Decl(destructuringInFunctionType.ts, 20, 10))
|
||||
>b : Symbol(b, Decl(destructuringInFunctionType.ts, 20, 12))
|
||||
>c : Symbol(c, Decl(destructuringInFunctionType.ts, 20, 15))
|
||||
|
80
tests/baselines/reference/destructuringInFunctionType.types
Normal file
80
tests/baselines/reference/destructuringInFunctionType.types
Normal file
|
@ -0,0 +1,80 @@
|
|||
=== tests/cases/conformance/es6/destructuring/destructuringInFunctionType.ts ===
|
||||
|
||||
interface a { a }
|
||||
>a : a
|
||||
>a : any
|
||||
|
||||
interface b { b }
|
||||
>b : b
|
||||
>b : any
|
||||
|
||||
interface c { c }
|
||||
>c : c
|
||||
>c : any
|
||||
|
||||
type T1 = ([a, b, c]);
|
||||
>T1 : [a, b, c]
|
||||
>a : a
|
||||
>b : b
|
||||
>c : c
|
||||
|
||||
type F1 = ([a, b, c]) => void;
|
||||
>F1 : ([a, b, c]: [any, any, any]) => void
|
||||
>a : any
|
||||
>b : any
|
||||
>c : any
|
||||
|
||||
type T2 = ({ a });
|
||||
>T2 : { a: any; }
|
||||
>a : any
|
||||
|
||||
type F2 = ({ a }) => void;
|
||||
>F2 : ({ a }: { a: any; }) => void
|
||||
>a : any
|
||||
|
||||
type T3 = ([{ a: b }, { b: a }]);
|
||||
>T3 : [{ a: b; }, { b: a; }]
|
||||
>a : b
|
||||
>b : b
|
||||
>b : a
|
||||
>a : a
|
||||
|
||||
type F3 = ([{ a: b }, { b: a }]) => void;
|
||||
>F3 : ([{ a: b }, { b: a }]: [{ a: any; }, { b: any; }]) => void
|
||||
>a : any
|
||||
>b : any
|
||||
>b : any
|
||||
>a : any
|
||||
|
||||
type T4 = ([{ a: [b, c] }]);
|
||||
>T4 : [{ a: [b, c]; }]
|
||||
>a : [b, c]
|
||||
>b : b
|
||||
>c : c
|
||||
|
||||
type F4 = ([{ a: [b, c] }]) => void;
|
||||
>F4 : ([{ a: [b, c] }]: [{ a: [any, any]; }]) => void
|
||||
>a : any
|
||||
>b : any
|
||||
>c : any
|
||||
|
||||
type C1 = new ([{ a: [b, c] }]) => void;
|
||||
>C1 : new ([{ a: [b, c] }]: [{ a: [any, any]; }]) => void
|
||||
>a : any
|
||||
>b : any
|
||||
>c : any
|
||||
|
||||
var v1 = ([a, b, c]) => "hello";
|
||||
>v1 : ([a, b, c]: [any, any, any]) => string
|
||||
>([a, b, c]) => "hello" : ([a, b, c]: [any, any, any]) => string
|
||||
>a : any
|
||||
>b : any
|
||||
>c : any
|
||||
>"hello" : string
|
||||
|
||||
var v2: ([a, b, c]) => string;
|
||||
>v2 : ([a, b, c]: [any, any, any]) => string
|
||||
>a : any
|
||||
>b : any
|
||||
>c : any
|
||||
|
|
@ -1,8 +1,8 @@
|
|||
tests/cases/compiler/importDeclWithClassModifiers.ts(5,8): error TS1044: 'public' modifier cannot appear on a module element.
|
||||
tests/cases/compiler/importDeclWithClassModifiers.ts(5,8): error TS1044: 'public' modifier cannot appear on a module or namespace element.
|
||||
tests/cases/compiler/importDeclWithClassModifiers.ts(5,28): error TS2305: Module 'x' has no exported member 'c'.
|
||||
tests/cases/compiler/importDeclWithClassModifiers.ts(6,8): error TS1044: 'private' modifier cannot appear on a module element.
|
||||
tests/cases/compiler/importDeclWithClassModifiers.ts(6,8): error TS1044: 'private' modifier cannot appear on a module or namespace element.
|
||||
tests/cases/compiler/importDeclWithClassModifiers.ts(6,29): error TS2305: Module 'x' has no exported member 'c'.
|
||||
tests/cases/compiler/importDeclWithClassModifiers.ts(7,8): error TS1044: 'static' modifier cannot appear on a module element.
|
||||
tests/cases/compiler/importDeclWithClassModifiers.ts(7,8): error TS1044: 'static' modifier cannot appear on a module or namespace element.
|
||||
tests/cases/compiler/importDeclWithClassModifiers.ts(7,28): error TS2305: Module 'x' has no exported member 'c'.
|
||||
|
||||
|
||||
|
@ -13,17 +13,17 @@ tests/cases/compiler/importDeclWithClassModifiers.ts(7,28): error TS2305: Module
|
|||
}
|
||||
export public import a = x.c;
|
||||
~~~~~~
|
||||
!!! error TS1044: 'public' modifier cannot appear on a module element.
|
||||
!!! error TS1044: 'public' modifier cannot appear on a module or namespace element.
|
||||
~
|
||||
!!! error TS2305: Module 'x' has no exported member 'c'.
|
||||
export private import b = x.c;
|
||||
~~~~~~~
|
||||
!!! error TS1044: 'private' modifier cannot appear on a module element.
|
||||
!!! error TS1044: 'private' modifier cannot appear on a module or namespace element.
|
||||
~
|
||||
!!! error TS2305: Module 'x' has no exported member 'c'.
|
||||
export static import c = x.c;
|
||||
~~~~~~
|
||||
!!! error TS1044: 'static' modifier cannot appear on a module element.
|
||||
!!! error TS1044: 'static' modifier cannot appear on a module or namespace element.
|
||||
~
|
||||
!!! error TS2305: Module 'x' has no exported member 'c'.
|
||||
var b: a;
|
||||
|
|
|
@ -1,24 +1,24 @@
|
|||
tests/cases/conformance/internalModules/moduleBody/invalidModuleWithStatementsOfEveryKind.ts(4,5): error TS1044: 'public' modifier cannot appear on a module element.
|
||||
tests/cases/conformance/internalModules/moduleBody/invalidModuleWithStatementsOfEveryKind.ts(6,5): error TS1044: 'public' modifier cannot appear on a module element.
|
||||
tests/cases/conformance/internalModules/moduleBody/invalidModuleWithStatementsOfEveryKind.ts(12,5): error TS1044: 'public' modifier cannot appear on a module element.
|
||||
tests/cases/conformance/internalModules/moduleBody/invalidModuleWithStatementsOfEveryKind.ts(13,5): error TS1044: 'public' modifier cannot appear on a module element.
|
||||
tests/cases/conformance/internalModules/moduleBody/invalidModuleWithStatementsOfEveryKind.ts(15,5): error TS1044: 'public' modifier cannot appear on a module element.
|
||||
tests/cases/conformance/internalModules/moduleBody/invalidModuleWithStatementsOfEveryKind.ts(19,5): error TS1044: 'public' modifier cannot appear on a module element.
|
||||
tests/cases/conformance/internalModules/moduleBody/invalidModuleWithStatementsOfEveryKind.ts(25,5): error TS1044: 'public' modifier cannot appear on a module element.
|
||||
tests/cases/conformance/internalModules/moduleBody/invalidModuleWithStatementsOfEveryKind.ts(29,5): error TS1044: 'private' modifier cannot appear on a module element.
|
||||
tests/cases/conformance/internalModules/moduleBody/invalidModuleWithStatementsOfEveryKind.ts(31,5): error TS1044: 'private' modifier cannot appear on a module element.
|
||||
tests/cases/conformance/internalModules/moduleBody/invalidModuleWithStatementsOfEveryKind.ts(37,5): error TS1044: 'private' modifier cannot appear on a module element.
|
||||
tests/cases/conformance/internalModules/moduleBody/invalidModuleWithStatementsOfEveryKind.ts(38,5): error TS1044: 'private' modifier cannot appear on a module element.
|
||||
tests/cases/conformance/internalModules/moduleBody/invalidModuleWithStatementsOfEveryKind.ts(40,5): error TS1044: 'private' modifier cannot appear on a module element.
|
||||
tests/cases/conformance/internalModules/moduleBody/invalidModuleWithStatementsOfEveryKind.ts(44,5): error TS1044: 'private' modifier cannot appear on a module element.
|
||||
tests/cases/conformance/internalModules/moduleBody/invalidModuleWithStatementsOfEveryKind.ts(50,5): error TS1044: 'private' modifier cannot appear on a module element.
|
||||
tests/cases/conformance/internalModules/moduleBody/invalidModuleWithStatementsOfEveryKind.ts(55,5): error TS1044: 'static' modifier cannot appear on a module element.
|
||||
tests/cases/conformance/internalModules/moduleBody/invalidModuleWithStatementsOfEveryKind.ts(57,5): error TS1044: 'static' modifier cannot appear on a module element.
|
||||
tests/cases/conformance/internalModules/moduleBody/invalidModuleWithStatementsOfEveryKind.ts(63,5): error TS1044: 'static' modifier cannot appear on a module element.
|
||||
tests/cases/conformance/internalModules/moduleBody/invalidModuleWithStatementsOfEveryKind.ts(64,5): error TS1044: 'static' modifier cannot appear on a module element.
|
||||
tests/cases/conformance/internalModules/moduleBody/invalidModuleWithStatementsOfEveryKind.ts(66,5): error TS1044: 'static' modifier cannot appear on a module element.
|
||||
tests/cases/conformance/internalModules/moduleBody/invalidModuleWithStatementsOfEveryKind.ts(70,5): error TS1044: 'static' modifier cannot appear on a module element.
|
||||
tests/cases/conformance/internalModules/moduleBody/invalidModuleWithStatementsOfEveryKind.ts(76,5): error TS1044: 'static' modifier cannot appear on a module element.
|
||||
tests/cases/conformance/internalModules/moduleBody/invalidModuleWithStatementsOfEveryKind.ts(4,5): error TS1044: 'public' modifier cannot appear on a module or namespace element.
|
||||
tests/cases/conformance/internalModules/moduleBody/invalidModuleWithStatementsOfEveryKind.ts(6,5): error TS1044: 'public' modifier cannot appear on a module or namespace element.
|
||||
tests/cases/conformance/internalModules/moduleBody/invalidModuleWithStatementsOfEveryKind.ts(12,5): error TS1044: 'public' modifier cannot appear on a module or namespace element.
|
||||
tests/cases/conformance/internalModules/moduleBody/invalidModuleWithStatementsOfEveryKind.ts(13,5): error TS1044: 'public' modifier cannot appear on a module or namespace element.
|
||||
tests/cases/conformance/internalModules/moduleBody/invalidModuleWithStatementsOfEveryKind.ts(15,5): error TS1044: 'public' modifier cannot appear on a module or namespace element.
|
||||
tests/cases/conformance/internalModules/moduleBody/invalidModuleWithStatementsOfEveryKind.ts(19,5): error TS1044: 'public' modifier cannot appear on a module or namespace element.
|
||||
tests/cases/conformance/internalModules/moduleBody/invalidModuleWithStatementsOfEveryKind.ts(25,5): error TS1044: 'public' modifier cannot appear on a module or namespace element.
|
||||
tests/cases/conformance/internalModules/moduleBody/invalidModuleWithStatementsOfEveryKind.ts(29,5): error TS1044: 'private' modifier cannot appear on a module or namespace element.
|
||||
tests/cases/conformance/internalModules/moduleBody/invalidModuleWithStatementsOfEveryKind.ts(31,5): error TS1044: 'private' modifier cannot appear on a module or namespace element.
|
||||
tests/cases/conformance/internalModules/moduleBody/invalidModuleWithStatementsOfEveryKind.ts(37,5): error TS1044: 'private' modifier cannot appear on a module or namespace element.
|
||||
tests/cases/conformance/internalModules/moduleBody/invalidModuleWithStatementsOfEveryKind.ts(38,5): error TS1044: 'private' modifier cannot appear on a module or namespace element.
|
||||
tests/cases/conformance/internalModules/moduleBody/invalidModuleWithStatementsOfEveryKind.ts(40,5): error TS1044: 'private' modifier cannot appear on a module or namespace element.
|
||||
tests/cases/conformance/internalModules/moduleBody/invalidModuleWithStatementsOfEveryKind.ts(44,5): error TS1044: 'private' modifier cannot appear on a module or namespace element.
|
||||
tests/cases/conformance/internalModules/moduleBody/invalidModuleWithStatementsOfEveryKind.ts(50,5): error TS1044: 'private' modifier cannot appear on a module or namespace element.
|
||||
tests/cases/conformance/internalModules/moduleBody/invalidModuleWithStatementsOfEveryKind.ts(55,5): error TS1044: 'static' modifier cannot appear on a module or namespace element.
|
||||
tests/cases/conformance/internalModules/moduleBody/invalidModuleWithStatementsOfEveryKind.ts(57,5): error TS1044: 'static' modifier cannot appear on a module or namespace element.
|
||||
tests/cases/conformance/internalModules/moduleBody/invalidModuleWithStatementsOfEveryKind.ts(63,5): error TS1044: 'static' modifier cannot appear on a module or namespace element.
|
||||
tests/cases/conformance/internalModules/moduleBody/invalidModuleWithStatementsOfEveryKind.ts(64,5): error TS1044: 'static' modifier cannot appear on a module or namespace element.
|
||||
tests/cases/conformance/internalModules/moduleBody/invalidModuleWithStatementsOfEveryKind.ts(66,5): error TS1044: 'static' modifier cannot appear on a module or namespace element.
|
||||
tests/cases/conformance/internalModules/moduleBody/invalidModuleWithStatementsOfEveryKind.ts(70,5): error TS1044: 'static' modifier cannot appear on a module or namespace element.
|
||||
tests/cases/conformance/internalModules/moduleBody/invalidModuleWithStatementsOfEveryKind.ts(76,5): error TS1044: 'static' modifier cannot appear on a module or namespace element.
|
||||
|
||||
|
||||
==== tests/cases/conformance/internalModules/moduleBody/invalidModuleWithStatementsOfEveryKind.ts (21 errors) ====
|
||||
|
@ -27,11 +27,11 @@ tests/cases/conformance/internalModules/moduleBody/invalidModuleWithStatementsOf
|
|||
module Y {
|
||||
public class A { s: string }
|
||||
~~~~~~
|
||||
!!! error TS1044: 'public' modifier cannot appear on a module element.
|
||||
!!! error TS1044: 'public' modifier cannot appear on a module or namespace element.
|
||||
|
||||
public class BB<T> extends A {
|
||||
~~~~~~
|
||||
!!! error TS1044: 'public' modifier cannot appear on a module element.
|
||||
!!! error TS1044: 'public' modifier cannot appear on a module or namespace element.
|
||||
id: number;
|
||||
}
|
||||
}
|
||||
|
@ -39,20 +39,20 @@ tests/cases/conformance/internalModules/moduleBody/invalidModuleWithStatementsOf
|
|||
module Y2 {
|
||||
public class AA<T> { s: T }
|
||||
~~~~~~
|
||||
!!! error TS1044: 'public' modifier cannot appear on a module element.
|
||||
!!! error TS1044: 'public' modifier cannot appear on a module or namespace element.
|
||||
public interface I { id: number }
|
||||
~~~~~~
|
||||
!!! error TS1044: 'public' modifier cannot appear on a module element.
|
||||
!!! error TS1044: 'public' modifier cannot appear on a module or namespace element.
|
||||
|
||||
public class B extends AA<string> implements I { id: number }
|
||||
~~~~~~
|
||||
!!! error TS1044: 'public' modifier cannot appear on a module element.
|
||||
!!! error TS1044: 'public' modifier cannot appear on a module or namespace element.
|
||||
}
|
||||
|
||||
module Y3 {
|
||||
public module Module {
|
||||
~~~~~~
|
||||
!!! error TS1044: 'public' modifier cannot appear on a module element.
|
||||
!!! error TS1044: 'public' modifier cannot appear on a module or namespace element.
|
||||
class A { s: string }
|
||||
}
|
||||
}
|
||||
|
@ -60,17 +60,17 @@ tests/cases/conformance/internalModules/moduleBody/invalidModuleWithStatementsOf
|
|||
module Y4 {
|
||||
public enum Color { Blue, Red }
|
||||
~~~~~~
|
||||
!!! error TS1044: 'public' modifier cannot appear on a module element.
|
||||
!!! error TS1044: 'public' modifier cannot appear on a module or namespace element.
|
||||
}
|
||||
|
||||
module YY {
|
||||
private class A { s: string }
|
||||
~~~~~~~
|
||||
!!! error TS1044: 'private' modifier cannot appear on a module element.
|
||||
!!! error TS1044: 'private' modifier cannot appear on a module or namespace element.
|
||||
|
||||
private class BB<T> extends A {
|
||||
~~~~~~~
|
||||
!!! error TS1044: 'private' modifier cannot appear on a module element.
|
||||
!!! error TS1044: 'private' modifier cannot appear on a module or namespace element.
|
||||
id: number;
|
||||
}
|
||||
}
|
||||
|
@ -78,20 +78,20 @@ tests/cases/conformance/internalModules/moduleBody/invalidModuleWithStatementsOf
|
|||
module YY2 {
|
||||
private class AA<T> { s: T }
|
||||
~~~~~~~
|
||||
!!! error TS1044: 'private' modifier cannot appear on a module element.
|
||||
!!! error TS1044: 'private' modifier cannot appear on a module or namespace element.
|
||||
private interface I { id: number }
|
||||
~~~~~~~
|
||||
!!! error TS1044: 'private' modifier cannot appear on a module element.
|
||||
!!! error TS1044: 'private' modifier cannot appear on a module or namespace element.
|
||||
|
||||
private class B extends AA<string> implements I { id: number }
|
||||
~~~~~~~
|
||||
!!! error TS1044: 'private' modifier cannot appear on a module element.
|
||||
!!! error TS1044: 'private' modifier cannot appear on a module or namespace element.
|
||||
}
|
||||
|
||||
module YY3 {
|
||||
private module Module {
|
||||
~~~~~~~
|
||||
!!! error TS1044: 'private' modifier cannot appear on a module element.
|
||||
!!! error TS1044: 'private' modifier cannot appear on a module or namespace element.
|
||||
class A { s: string }
|
||||
}
|
||||
}
|
||||
|
@ -99,18 +99,18 @@ tests/cases/conformance/internalModules/moduleBody/invalidModuleWithStatementsOf
|
|||
module YY4 {
|
||||
private enum Color { Blue, Red }
|
||||
~~~~~~~
|
||||
!!! error TS1044: 'private' modifier cannot appear on a module element.
|
||||
!!! error TS1044: 'private' modifier cannot appear on a module or namespace element.
|
||||
}
|
||||
|
||||
|
||||
module YYY {
|
||||
static class A { s: string }
|
||||
~~~~~~
|
||||
!!! error TS1044: 'static' modifier cannot appear on a module element.
|
||||
!!! error TS1044: 'static' modifier cannot appear on a module or namespace element.
|
||||
|
||||
static class BB<T> extends A {
|
||||
~~~~~~
|
||||
!!! error TS1044: 'static' modifier cannot appear on a module element.
|
||||
!!! error TS1044: 'static' modifier cannot appear on a module or namespace element.
|
||||
id: number;
|
||||
}
|
||||
}
|
||||
|
@ -118,20 +118,20 @@ tests/cases/conformance/internalModules/moduleBody/invalidModuleWithStatementsOf
|
|||
module YYY2 {
|
||||
static class AA<T> { s: T }
|
||||
~~~~~~
|
||||
!!! error TS1044: 'static' modifier cannot appear on a module element.
|
||||
!!! error TS1044: 'static' modifier cannot appear on a module or namespace element.
|
||||
static interface I { id: number }
|
||||
~~~~~~
|
||||
!!! error TS1044: 'static' modifier cannot appear on a module element.
|
||||
!!! error TS1044: 'static' modifier cannot appear on a module or namespace element.
|
||||
|
||||
static class B extends AA<string> implements I { id: number }
|
||||
~~~~~~
|
||||
!!! error TS1044: 'static' modifier cannot appear on a module element.
|
||||
!!! error TS1044: 'static' modifier cannot appear on a module or namespace element.
|
||||
}
|
||||
|
||||
module YYY3 {
|
||||
static module Module {
|
||||
~~~~~~
|
||||
!!! error TS1044: 'static' modifier cannot appear on a module element.
|
||||
!!! error TS1044: 'static' modifier cannot appear on a module or namespace element.
|
||||
class A { s: string }
|
||||
}
|
||||
}
|
||||
|
@ -139,6 +139,6 @@ tests/cases/conformance/internalModules/moduleBody/invalidModuleWithStatementsOf
|
|||
module YYY4 {
|
||||
static enum Color { Blue, Red }
|
||||
~~~~~~
|
||||
!!! error TS1044: 'static' modifier cannot appear on a module element.
|
||||
!!! error TS1044: 'static' modifier cannot appear on a module or namespace element.
|
||||
}
|
||||
|
|
@ -1,9 +1,9 @@
|
|||
tests/cases/conformance/internalModules/moduleBody/invalidModuleWithVarStatements.ts(4,5): error TS1044: 'public' modifier cannot appear on a module element.
|
||||
tests/cases/conformance/internalModules/moduleBody/invalidModuleWithVarStatements.ts(8,5): error TS1044: 'public' modifier cannot appear on a module element.
|
||||
tests/cases/conformance/internalModules/moduleBody/invalidModuleWithVarStatements.ts(12,5): error TS1044: 'static' modifier cannot appear on a module element.
|
||||
tests/cases/conformance/internalModules/moduleBody/invalidModuleWithVarStatements.ts(16,5): error TS1044: 'static' modifier cannot appear on a module element.
|
||||
tests/cases/conformance/internalModules/moduleBody/invalidModuleWithVarStatements.ts(20,5): error TS1044: 'private' modifier cannot appear on a module element.
|
||||
tests/cases/conformance/internalModules/moduleBody/invalidModuleWithVarStatements.ts(25,5): error TS1044: 'private' modifier cannot appear on a module element.
|
||||
tests/cases/conformance/internalModules/moduleBody/invalidModuleWithVarStatements.ts(4,5): error TS1044: 'public' modifier cannot appear on a module or namespace element.
|
||||
tests/cases/conformance/internalModules/moduleBody/invalidModuleWithVarStatements.ts(8,5): error TS1044: 'public' modifier cannot appear on a module or namespace element.
|
||||
tests/cases/conformance/internalModules/moduleBody/invalidModuleWithVarStatements.ts(12,5): error TS1044: 'static' modifier cannot appear on a module or namespace element.
|
||||
tests/cases/conformance/internalModules/moduleBody/invalidModuleWithVarStatements.ts(16,5): error TS1044: 'static' modifier cannot appear on a module or namespace element.
|
||||
tests/cases/conformance/internalModules/moduleBody/invalidModuleWithVarStatements.ts(20,5): error TS1044: 'private' modifier cannot appear on a module or namespace element.
|
||||
tests/cases/conformance/internalModules/moduleBody/invalidModuleWithVarStatements.ts(25,5): error TS1044: 'private' modifier cannot appear on a module or namespace element.
|
||||
|
||||
|
||||
==== tests/cases/conformance/internalModules/moduleBody/invalidModuleWithVarStatements.ts (6 errors) ====
|
||||
|
@ -12,37 +12,37 @@ tests/cases/conformance/internalModules/moduleBody/invalidModuleWithVarStatement
|
|||
module Y {
|
||||
public var x: number = 0;
|
||||
~~~~~~
|
||||
!!! error TS1044: 'public' modifier cannot appear on a module element.
|
||||
!!! error TS1044: 'public' modifier cannot appear on a module or namespace element.
|
||||
}
|
||||
|
||||
module Y2 {
|
||||
public function fn(x: string) { }
|
||||
~~~~~~
|
||||
!!! error TS1044: 'public' modifier cannot appear on a module element.
|
||||
!!! error TS1044: 'public' modifier cannot appear on a module or namespace element.
|
||||
}
|
||||
|
||||
module Y4 {
|
||||
static var x: number = 0;
|
||||
~~~~~~
|
||||
!!! error TS1044: 'static' modifier cannot appear on a module element.
|
||||
!!! error TS1044: 'static' modifier cannot appear on a module or namespace element.
|
||||
}
|
||||
|
||||
module YY {
|
||||
static function fn(x: string) { }
|
||||
~~~~~~
|
||||
!!! error TS1044: 'static' modifier cannot appear on a module element.
|
||||
!!! error TS1044: 'static' modifier cannot appear on a module or namespace element.
|
||||
}
|
||||
|
||||
module YY2 {
|
||||
private var x: number = 0;
|
||||
~~~~~~~
|
||||
!!! error TS1044: 'private' modifier cannot appear on a module element.
|
||||
!!! error TS1044: 'private' modifier cannot appear on a module or namespace element.
|
||||
}
|
||||
|
||||
|
||||
module YY3 {
|
||||
private function fn(x: string) { }
|
||||
~~~~~~~
|
||||
!!! error TS1044: 'private' modifier cannot appear on a module element.
|
||||
!!! error TS1044: 'private' modifier cannot appear on a module or namespace element.
|
||||
}
|
||||
|
|
@ -1,8 +1,8 @@
|
|||
tests/cases/conformance/parser/ecmascript5/InterfaceDeclarations/parserInterfaceDeclaration3.ts(1,1): error TS1044: 'public' modifier cannot appear on a module element.
|
||||
tests/cases/conformance/parser/ecmascript5/InterfaceDeclarations/parserInterfaceDeclaration3.ts(1,1): error TS1044: 'public' modifier cannot appear on a module or namespace element.
|
||||
|
||||
|
||||
==== tests/cases/conformance/parser/ecmascript5/InterfaceDeclarations/parserInterfaceDeclaration3.ts (1 errors) ====
|
||||
public interface I {
|
||||
~~~~~~
|
||||
!!! error TS1044: 'public' modifier cannot appear on a module element.
|
||||
!!! error TS1044: 'public' modifier cannot appear on a module or namespace element.
|
||||
}
|
|
@ -1,8 +1,8 @@
|
|||
tests/cases/conformance/parser/ecmascript5/InterfaceDeclarations/parserInterfaceDeclaration4.ts(1,1): error TS1044: 'static' modifier cannot appear on a module element.
|
||||
tests/cases/conformance/parser/ecmascript5/InterfaceDeclarations/parserInterfaceDeclaration4.ts(1,1): error TS1044: 'static' modifier cannot appear on a module or namespace element.
|
||||
|
||||
|
||||
==== tests/cases/conformance/parser/ecmascript5/InterfaceDeclarations/parserInterfaceDeclaration4.ts (1 errors) ====
|
||||
static interface I {
|
||||
~~~~~~
|
||||
!!! error TS1044: 'static' modifier cannot appear on a module element.
|
||||
!!! error TS1044: 'static' modifier cannot appear on a module or namespace element.
|
||||
}
|
|
@ -0,0 +1,7 @@
|
|||
//// [sourceMapValidationDestructuringVariableStatementArrayBindingPattern4.ts]
|
||||
|
||||
var [x] = [1, 2];
|
||||
|
||||
//// [sourceMapValidationDestructuringVariableStatementArrayBindingPattern4.js]
|
||||
var x = [1, 2][0];
|
||||
//# sourceMappingURL=sourceMapValidationDestructuringVariableStatementArrayBindingPattern4.js.map
|
|
@ -0,0 +1,2 @@
|
|||
//// [sourceMapValidationDestructuringVariableStatementArrayBindingPattern4.js.map]
|
||||
{"version":3,"file":"sourceMapValidationDestructuringVariableStatementArrayBindingPattern4.js","sourceRoot":"","sources":["sourceMapValidationDestructuringVariableStatementArrayBindingPattern4.ts"],"names":[],"mappings":"AACK,iBAAC,CAAW"}
|
|
@ -0,0 +1,24 @@
|
|||
===================================================================
|
||||
JsFile: sourceMapValidationDestructuringVariableStatementArrayBindingPattern4.js
|
||||
mapUrl: sourceMapValidationDestructuringVariableStatementArrayBindingPattern4.js.map
|
||||
sourceRoot:
|
||||
sources: sourceMapValidationDestructuringVariableStatementArrayBindingPattern4.ts
|
||||
===================================================================
|
||||
-------------------------------------------------------------------
|
||||
emittedFile:tests/cases/compiler/sourceMapValidationDestructuringVariableStatementArrayBindingPattern4.js
|
||||
sourceFile:sourceMapValidationDestructuringVariableStatementArrayBindingPattern4.ts
|
||||
-------------------------------------------------------------------
|
||||
>>>var x = [1, 2][0];
|
||||
1 >
|
||||
2 >^^^^^^^^^^^^^^^^^
|
||||
3 > ^
|
||||
4 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^->
|
||||
1 >
|
||||
>var [
|
||||
2 >x
|
||||
3 > ] = [1, 2];
|
||||
1 >Emitted(1, 1) Source(2, 6) + SourceIndex(0)
|
||||
2 >Emitted(1, 18) Source(2, 7) + SourceIndex(0)
|
||||
3 >Emitted(1, 19) Source(2, 18) + SourceIndex(0)
|
||||
---
|
||||
>>>//# sourceMappingURL=sourceMapValidationDestructuringVariableStatementArrayBindingPattern4.js.map
|
|
@ -0,0 +1,5 @@
|
|||
=== tests/cases/compiler/sourceMapValidationDestructuringVariableStatementArrayBindingPattern4.ts ===
|
||||
|
||||
var [x] = [1, 2];
|
||||
>x : Symbol(x, Decl(sourceMapValidationDestructuringVariableStatementArrayBindingPattern4.ts, 1, 5))
|
||||
|
|
@ -0,0 +1,8 @@
|
|||
=== tests/cases/compiler/sourceMapValidationDestructuringVariableStatementArrayBindingPattern4.ts ===
|
||||
|
||||
var [x] = [1, 2];
|
||||
>x : number
|
||||
>[1, 2] : [number, number]
|
||||
>1 : number
|
||||
>2 : number
|
||||
|
|
@ -0,0 +1,9 @@
|
|||
//// [sourceMapValidationDestructuringVariableStatementArrayBindingPattern5.ts]
|
||||
|
||||
var [x] = [1, 2];
|
||||
var [y, z] = [1, 2];
|
||||
|
||||
//// [sourceMapValidationDestructuringVariableStatementArrayBindingPattern5.js]
|
||||
var x = [1, 2][0];
|
||||
var _a = [1, 2], y = _a[0], z = _a[1];
|
||||
//# sourceMappingURL=sourceMapValidationDestructuringVariableStatementArrayBindingPattern5.js.map
|
|
@ -0,0 +1,2 @@
|
|||
//// [sourceMapValidationDestructuringVariableStatementArrayBindingPattern5.js.map]
|
||||
{"version":3,"file":"sourceMapValidationDestructuringVariableStatementArrayBindingPattern5.js","sourceRoot":"","sources":["sourceMapValidationDestructuringVariableStatementArrayBindingPattern5.ts"],"names":[],"mappings":"AACK,iBAAC,CAAW;AACjB,IAAA,WAAmB,EAAd,SAAC,EAAE,SAAC,CAAW"}
|
|
@ -0,0 +1,52 @@
|
|||
===================================================================
|
||||
JsFile: sourceMapValidationDestructuringVariableStatementArrayBindingPattern5.js
|
||||
mapUrl: sourceMapValidationDestructuringVariableStatementArrayBindingPattern5.js.map
|
||||
sourceRoot:
|
||||
sources: sourceMapValidationDestructuringVariableStatementArrayBindingPattern5.ts
|
||||
===================================================================
|
||||
-------------------------------------------------------------------
|
||||
emittedFile:tests/cases/compiler/sourceMapValidationDestructuringVariableStatementArrayBindingPattern5.js
|
||||
sourceFile:sourceMapValidationDestructuringVariableStatementArrayBindingPattern5.ts
|
||||
-------------------------------------------------------------------
|
||||
>>>var x = [1, 2][0];
|
||||
1 >
|
||||
2 >^^^^^^^^^^^^^^^^^
|
||||
3 > ^
|
||||
4 > ^^^^^^^^^^^^^^^^^^^^^->
|
||||
1 >
|
||||
>var [
|
||||
2 >x
|
||||
3 > ] = [1, 2];
|
||||
1 >Emitted(1, 1) Source(2, 6) + SourceIndex(0)
|
||||
2 >Emitted(1, 18) Source(2, 7) + SourceIndex(0)
|
||||
3 >Emitted(1, 19) Source(2, 18) + SourceIndex(0)
|
||||
---
|
||||
>>>var _a = [1, 2], y = _a[0], z = _a[1];
|
||||
1->
|
||||
2 >^^^^
|
||||
3 > ^^^^^^^^^^^
|
||||
4 > ^^
|
||||
5 > ^^^^^^^^^
|
||||
6 > ^^
|
||||
7 > ^^^^^^^^^
|
||||
8 > ^
|
||||
9 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^->
|
||||
1->
|
||||
>
|
||||
2 >
|
||||
3 > var [y, z] = [1, 2]
|
||||
4 >
|
||||
5 > y
|
||||
6 > ,
|
||||
7 > z
|
||||
8 > ] = [1, 2];
|
||||
1->Emitted(2, 1) Source(3, 1) + SourceIndex(0)
|
||||
2 >Emitted(2, 5) Source(3, 1) + SourceIndex(0)
|
||||
3 >Emitted(2, 16) Source(3, 20) + SourceIndex(0)
|
||||
4 >Emitted(2, 18) Source(3, 6) + SourceIndex(0)
|
||||
5 >Emitted(2, 27) Source(3, 7) + SourceIndex(0)
|
||||
6 >Emitted(2, 29) Source(3, 9) + SourceIndex(0)
|
||||
7 >Emitted(2, 38) Source(3, 10) + SourceIndex(0)
|
||||
8 >Emitted(2, 39) Source(3, 21) + SourceIndex(0)
|
||||
---
|
||||
>>>//# sourceMappingURL=sourceMapValidationDestructuringVariableStatementArrayBindingPattern5.js.map
|
|
@ -0,0 +1,9 @@
|
|||
=== tests/cases/compiler/sourceMapValidationDestructuringVariableStatementArrayBindingPattern5.ts ===
|
||||
|
||||
var [x] = [1, 2];
|
||||
>x : Symbol(x, Decl(sourceMapValidationDestructuringVariableStatementArrayBindingPattern5.ts, 1, 5))
|
||||
|
||||
var [y, z] = [1, 2];
|
||||
>y : Symbol(y, Decl(sourceMapValidationDestructuringVariableStatementArrayBindingPattern5.ts, 2, 5))
|
||||
>z : Symbol(z, Decl(sourceMapValidationDestructuringVariableStatementArrayBindingPattern5.ts, 2, 7))
|
||||
|
|
@ -0,0 +1,15 @@
|
|||
=== tests/cases/compiler/sourceMapValidationDestructuringVariableStatementArrayBindingPattern5.ts ===
|
||||
|
||||
var [x] = [1, 2];
|
||||
>x : number
|
||||
>[1, 2] : [number, number]
|
||||
>1 : number
|
||||
>2 : number
|
||||
|
||||
var [y, z] = [1, 2];
|
||||
>y : number
|
||||
>z : number
|
||||
>[1, 2] : [number, number]
|
||||
>1 : number
|
||||
>2 : number
|
||||
|
|
@ -0,0 +1,7 @@
|
|||
//// [sourceMapValidationDestructuringVariableStatementArrayBindingPattern6.ts]
|
||||
|
||||
var [x = 20] = [1, 2];
|
||||
|
||||
//// [sourceMapValidationDestructuringVariableStatementArrayBindingPattern6.js]
|
||||
var _a = [1, 2][0], x = _a === void 0 ? 20 : _a;
|
||||
//# sourceMappingURL=sourceMapValidationDestructuringVariableStatementArrayBindingPattern6.js.map
|
|
@ -0,0 +1,2 @@
|
|||
//// [sourceMapValidationDestructuringVariableStatementArrayBindingPattern6.js.map]
|
||||
{"version":3,"file":"sourceMapValidationDestructuringVariableStatementArrayBindingPattern6.js","sourceRoot":"","sources":["sourceMapValidationDestructuringVariableStatementArrayBindingPattern6.ts"],"names":[],"mappings":"AACK,kBAAM,EAAN,2BAAM,CAAW"}
|
|
@ -0,0 +1,30 @@
|
|||
===================================================================
|
||||
JsFile: sourceMapValidationDestructuringVariableStatementArrayBindingPattern6.js
|
||||
mapUrl: sourceMapValidationDestructuringVariableStatementArrayBindingPattern6.js.map
|
||||
sourceRoot:
|
||||
sources: sourceMapValidationDestructuringVariableStatementArrayBindingPattern6.ts
|
||||
===================================================================
|
||||
-------------------------------------------------------------------
|
||||
emittedFile:tests/cases/compiler/sourceMapValidationDestructuringVariableStatementArrayBindingPattern6.js
|
||||
sourceFile:sourceMapValidationDestructuringVariableStatementArrayBindingPattern6.ts
|
||||
-------------------------------------------------------------------
|
||||
>>>var _a = [1, 2][0], x = _a === void 0 ? 20 : _a;
|
||||
1 >
|
||||
2 >^^^^^^^^^^^^^^^^^^
|
||||
3 > ^^
|
||||
4 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
5 > ^
|
||||
6 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^->
|
||||
1 >
|
||||
>var [
|
||||
2 >x = 20
|
||||
3 >
|
||||
4 > x = 20
|
||||
5 > ] = [1, 2];
|
||||
1 >Emitted(1, 1) Source(2, 6) + SourceIndex(0)
|
||||
2 >Emitted(1, 19) Source(2, 12) + SourceIndex(0)
|
||||
3 >Emitted(1, 21) Source(2, 6) + SourceIndex(0)
|
||||
4 >Emitted(1, 48) Source(2, 12) + SourceIndex(0)
|
||||
5 >Emitted(1, 49) Source(2, 23) + SourceIndex(0)
|
||||
---
|
||||
>>>//# sourceMappingURL=sourceMapValidationDestructuringVariableStatementArrayBindingPattern6.js.map
|
|
@ -0,0 +1,5 @@
|
|||
=== tests/cases/compiler/sourceMapValidationDestructuringVariableStatementArrayBindingPattern6.ts ===
|
||||
|
||||
var [x = 20] = [1, 2];
|
||||
>x : Symbol(x, Decl(sourceMapValidationDestructuringVariableStatementArrayBindingPattern6.ts, 1, 5))
|
||||
|
|
@ -0,0 +1,9 @@
|
|||
=== tests/cases/compiler/sourceMapValidationDestructuringVariableStatementArrayBindingPattern6.ts ===
|
||||
|
||||
var [x = 20] = [1, 2];
|
||||
>x : number
|
||||
>20 : number
|
||||
>[1, 2] : [number, number]
|
||||
>1 : number
|
||||
>2 : number
|
||||
|
|
@ -0,0 +1,7 @@
|
|||
//// [sourceMapValidationDestructuringVariableStatementArrayBindingPattern7.ts]
|
||||
|
||||
var [x = 20, j] = [1, 2];
|
||||
|
||||
//// [sourceMapValidationDestructuringVariableStatementArrayBindingPattern7.js]
|
||||
var _a = [1, 2], _b = _a[0], x = _b === void 0 ? 20 : _b, j = _a[1];
|
||||
//# sourceMappingURL=sourceMapValidationDestructuringVariableStatementArrayBindingPattern7.js.map
|
|
@ -0,0 +1,2 @@
|
|||
//// [sourceMapValidationDestructuringVariableStatementArrayBindingPattern7.js.map]
|
||||
{"version":3,"file":"sourceMapValidationDestructuringVariableStatementArrayBindingPattern7.js","sourceRoot":"","sources":["sourceMapValidationDestructuringVariableStatementArrayBindingPattern7.ts"],"names":[],"mappings":"AACA,IAAA,WAAwB,EAAnB,UAAM,EAAN,2BAAM,EAAE,SAAC,CAAW"}
|
|
@ -0,0 +1,45 @@
|
|||
===================================================================
|
||||
JsFile: sourceMapValidationDestructuringVariableStatementArrayBindingPattern7.js
|
||||
mapUrl: sourceMapValidationDestructuringVariableStatementArrayBindingPattern7.js.map
|
||||
sourceRoot:
|
||||
sources: sourceMapValidationDestructuringVariableStatementArrayBindingPattern7.ts
|
||||
===================================================================
|
||||
-------------------------------------------------------------------
|
||||
emittedFile:tests/cases/compiler/sourceMapValidationDestructuringVariableStatementArrayBindingPattern7.js
|
||||
sourceFile:sourceMapValidationDestructuringVariableStatementArrayBindingPattern7.ts
|
||||
-------------------------------------------------------------------
|
||||
>>>var _a = [1, 2], _b = _a[0], x = _b === void 0 ? 20 : _b, j = _a[1];
|
||||
1 >
|
||||
2 >^^^^
|
||||
3 > ^^^^^^^^^^^
|
||||
4 > ^^
|
||||
5 > ^^^^^^^^^^
|
||||
6 > ^^
|
||||
7 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
8 > ^^
|
||||
9 > ^^^^^^^^^
|
||||
10> ^
|
||||
11> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^->
|
||||
1 >
|
||||
>
|
||||
2 >
|
||||
3 > var [x = 20, j] = [1, 2]
|
||||
4 >
|
||||
5 > x = 20
|
||||
6 >
|
||||
7 > x = 20
|
||||
8 > ,
|
||||
9 > j
|
||||
10> ] = [1, 2];
|
||||
1 >Emitted(1, 1) Source(2, 1) + SourceIndex(0)
|
||||
2 >Emitted(1, 5) Source(2, 1) + SourceIndex(0)
|
||||
3 >Emitted(1, 16) Source(2, 25) + SourceIndex(0)
|
||||
4 >Emitted(1, 18) Source(2, 6) + SourceIndex(0)
|
||||
5 >Emitted(1, 28) Source(2, 12) + SourceIndex(0)
|
||||
6 >Emitted(1, 30) Source(2, 6) + SourceIndex(0)
|
||||
7 >Emitted(1, 57) Source(2, 12) + SourceIndex(0)
|
||||
8 >Emitted(1, 59) Source(2, 14) + SourceIndex(0)
|
||||
9 >Emitted(1, 68) Source(2, 15) + SourceIndex(0)
|
||||
10>Emitted(1, 69) Source(2, 26) + SourceIndex(0)
|
||||
---
|
||||
>>>//# sourceMappingURL=sourceMapValidationDestructuringVariableStatementArrayBindingPattern7.js.map
|
|
@ -0,0 +1,6 @@
|
|||
=== tests/cases/compiler/sourceMapValidationDestructuringVariableStatementArrayBindingPattern7.ts ===
|
||||
|
||||
var [x = 20, j] = [1, 2];
|
||||
>x : Symbol(x, Decl(sourceMapValidationDestructuringVariableStatementArrayBindingPattern7.ts, 1, 5))
|
||||
>j : Symbol(j, Decl(sourceMapValidationDestructuringVariableStatementArrayBindingPattern7.ts, 1, 12))
|
||||
|
|
@ -0,0 +1,10 @@
|
|||
=== tests/cases/compiler/sourceMapValidationDestructuringVariableStatementArrayBindingPattern7.ts ===
|
||||
|
||||
var [x = 20, j] = [1, 2];
|
||||
>x : number
|
||||
>20 : number
|
||||
>j : number
|
||||
>[1, 2] : [number, number]
|
||||
>1 : number
|
||||
>2 : number
|
||||
|
|
@ -0,0 +1,7 @@
|
|||
//// [sourceMapValidationDestructuringVariableStatementObjectBindingPattern1.ts]
|
||||
|
||||
var {x} = { x: 20 };
|
||||
|
||||
//// [sourceMapValidationDestructuringVariableStatementObjectBindingPattern1.js]
|
||||
var x = { x: 20 }.x;
|
||||
//# sourceMappingURL=sourceMapValidationDestructuringVariableStatementObjectBindingPattern1.js.map
|
|
@ -0,0 +1,2 @@
|
|||
//// [sourceMapValidationDestructuringVariableStatementObjectBindingPattern1.js.map]
|
||||
{"version":3,"file":"sourceMapValidationDestructuringVariableStatementObjectBindingPattern1.js","sourceRoot":"","sources":["sourceMapValidationDestructuringVariableStatementObjectBindingPattern1.ts"],"names":[],"mappings":"AACK,mBAAC,CAAc"}
|
|
@ -0,0 +1,24 @@
|
|||
===================================================================
|
||||
JsFile: sourceMapValidationDestructuringVariableStatementObjectBindingPattern1.js
|
||||
mapUrl: sourceMapValidationDestructuringVariableStatementObjectBindingPattern1.js.map
|
||||
sourceRoot:
|
||||
sources: sourceMapValidationDestructuringVariableStatementObjectBindingPattern1.ts
|
||||
===================================================================
|
||||
-------------------------------------------------------------------
|
||||
emittedFile:tests/cases/compiler/sourceMapValidationDestructuringVariableStatementObjectBindingPattern1.js
|
||||
sourceFile:sourceMapValidationDestructuringVariableStatementObjectBindingPattern1.ts
|
||||
-------------------------------------------------------------------
|
||||
>>>var x = { x: 20 }.x;
|
||||
1 >
|
||||
2 >^^^^^^^^^^^^^^^^^^^
|
||||
3 > ^
|
||||
4 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^->
|
||||
1 >
|
||||
>var {
|
||||
2 >x
|
||||
3 > } = { x: 20 };
|
||||
1 >Emitted(1, 1) Source(2, 6) + SourceIndex(0)
|
||||
2 >Emitted(1, 20) Source(2, 7) + SourceIndex(0)
|
||||
3 >Emitted(1, 21) Source(2, 21) + SourceIndex(0)
|
||||
---
|
||||
>>>//# sourceMappingURL=sourceMapValidationDestructuringVariableStatementObjectBindingPattern1.js.map
|
|
@ -0,0 +1,6 @@
|
|||
=== tests/cases/compiler/sourceMapValidationDestructuringVariableStatementObjectBindingPattern1.ts ===
|
||||
|
||||
var {x} = { x: 20 };
|
||||
>x : Symbol(x, Decl(sourceMapValidationDestructuringVariableStatementObjectBindingPattern1.ts, 1, 5))
|
||||
>x : Symbol(x, Decl(sourceMapValidationDestructuringVariableStatementObjectBindingPattern1.ts, 1, 11))
|
||||
|
|
@ -0,0 +1,8 @@
|
|||
=== tests/cases/compiler/sourceMapValidationDestructuringVariableStatementObjectBindingPattern1.ts ===
|
||||
|
||||
var {x} = { x: 20 };
|
||||
>x : number
|
||||
>{ x: 20 } : { x: number; }
|
||||
>x : number
|
||||
>20 : number
|
||||
|
|
@ -0,0 +1,9 @@
|
|||
//// [sourceMapValidationDestructuringVariableStatementObjectBindingPattern2.ts]
|
||||
|
||||
var {x} = { x: 20 };
|
||||
var { a, b } = { a: 30, b: 40 };
|
||||
|
||||
//// [sourceMapValidationDestructuringVariableStatementObjectBindingPattern2.js]
|
||||
var x = { x: 20 }.x;
|
||||
var _a = { a: 30, b: 40 }, a = _a.a, b = _a.b;
|
||||
//# sourceMappingURL=sourceMapValidationDestructuringVariableStatementObjectBindingPattern2.js.map
|
|
@ -0,0 +1,2 @@
|
|||
//// [sourceMapValidationDestructuringVariableStatementObjectBindingPattern2.js.map]
|
||||
{"version":3,"file":"sourceMapValidationDestructuringVariableStatementObjectBindingPattern2.js","sourceRoot":"","sources":["sourceMapValidationDestructuringVariableStatementObjectBindingPattern2.ts"],"names":[],"mappings":"AACK,mBAAC,CAAc;AACpB,IAAA,qBAA+B,EAAzB,QAAC,EAAE,QAAC,CAAsB"}
|
|
@ -0,0 +1,52 @@
|
|||
===================================================================
|
||||
JsFile: sourceMapValidationDestructuringVariableStatementObjectBindingPattern2.js
|
||||
mapUrl: sourceMapValidationDestructuringVariableStatementObjectBindingPattern2.js.map
|
||||
sourceRoot:
|
||||
sources: sourceMapValidationDestructuringVariableStatementObjectBindingPattern2.ts
|
||||
===================================================================
|
||||
-------------------------------------------------------------------
|
||||
emittedFile:tests/cases/compiler/sourceMapValidationDestructuringVariableStatementObjectBindingPattern2.js
|
||||
sourceFile:sourceMapValidationDestructuringVariableStatementObjectBindingPattern2.ts
|
||||
-------------------------------------------------------------------
|
||||
>>>var x = { x: 20 }.x;
|
||||
1 >
|
||||
2 >^^^^^^^^^^^^^^^^^^^
|
||||
3 > ^
|
||||
4 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^->
|
||||
1 >
|
||||
>var {
|
||||
2 >x
|
||||
3 > } = { x: 20 };
|
||||
1 >Emitted(1, 1) Source(2, 6) + SourceIndex(0)
|
||||
2 >Emitted(1, 20) Source(2, 7) + SourceIndex(0)
|
||||
3 >Emitted(1, 21) Source(2, 21) + SourceIndex(0)
|
||||
---
|
||||
>>>var _a = { a: 30, b: 40 }, a = _a.a, b = _a.b;
|
||||
1->
|
||||
2 >^^^^
|
||||
3 > ^^^^^^^^^^^^^^^^^^^^^
|
||||
4 > ^^
|
||||
5 > ^^^^^^^^
|
||||
6 > ^^
|
||||
7 > ^^^^^^^^
|
||||
8 > ^
|
||||
9 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^->
|
||||
1->
|
||||
>
|
||||
2 >
|
||||
3 > var { a, b } = { a: 30, b: 40 }
|
||||
4 >
|
||||
5 > a
|
||||
6 > ,
|
||||
7 > b
|
||||
8 > } = { a: 30, b: 40 };
|
||||
1->Emitted(2, 1) Source(3, 1) + SourceIndex(0)
|
||||
2 >Emitted(2, 5) Source(3, 1) + SourceIndex(0)
|
||||
3 >Emitted(2, 26) Source(3, 32) + SourceIndex(0)
|
||||
4 >Emitted(2, 28) Source(3, 7) + SourceIndex(0)
|
||||
5 >Emitted(2, 36) Source(3, 8) + SourceIndex(0)
|
||||
6 >Emitted(2, 38) Source(3, 10) + SourceIndex(0)
|
||||
7 >Emitted(2, 46) Source(3, 11) + SourceIndex(0)
|
||||
8 >Emitted(2, 47) Source(3, 33) + SourceIndex(0)
|
||||
---
|
||||
>>>//# sourceMappingURL=sourceMapValidationDestructuringVariableStatementObjectBindingPattern2.js.map
|
|
@ -0,0 +1,12 @@
|
|||
=== tests/cases/compiler/sourceMapValidationDestructuringVariableStatementObjectBindingPattern2.ts ===
|
||||
|
||||
var {x} = { x: 20 };
|
||||
>x : Symbol(x, Decl(sourceMapValidationDestructuringVariableStatementObjectBindingPattern2.ts, 1, 5))
|
||||
>x : Symbol(x, Decl(sourceMapValidationDestructuringVariableStatementObjectBindingPattern2.ts, 1, 11))
|
||||
|
||||
var { a, b } = { a: 30, b: 40 };
|
||||
>a : Symbol(a, Decl(sourceMapValidationDestructuringVariableStatementObjectBindingPattern2.ts, 2, 5))
|
||||
>b : Symbol(b, Decl(sourceMapValidationDestructuringVariableStatementObjectBindingPattern2.ts, 2, 8))
|
||||
>a : Symbol(a, Decl(sourceMapValidationDestructuringVariableStatementObjectBindingPattern2.ts, 2, 16))
|
||||
>b : Symbol(b, Decl(sourceMapValidationDestructuringVariableStatementObjectBindingPattern2.ts, 2, 23))
|
||||
|
|
@ -0,0 +1,17 @@
|
|||
=== tests/cases/compiler/sourceMapValidationDestructuringVariableStatementObjectBindingPattern2.ts ===
|
||||
|
||||
var {x} = { x: 20 };
|
||||
>x : number
|
||||
>{ x: 20 } : { x: number; }
|
||||
>x : number
|
||||
>20 : number
|
||||
|
||||
var { a, b } = { a: 30, b: 40 };
|
||||
>a : number
|
||||
>b : number
|
||||
>{ a: 30, b: 40 } : { a: number; b: number; }
|
||||
>a : number
|
||||
>30 : number
|
||||
>b : number
|
||||
>40 : number
|
||||
|
|
@ -0,0 +1,7 @@
|
|||
//// [sourceMapValidationDestructuringVariableStatementObjectBindingPattern3.ts]
|
||||
|
||||
var {x = 500} = { x: 20 };
|
||||
|
||||
//// [sourceMapValidationDestructuringVariableStatementObjectBindingPattern3.js]
|
||||
var _a = { x: 20 }.x, x = _a === void 0 ? 500 : _a;
|
||||
//# sourceMappingURL=sourceMapValidationDestructuringVariableStatementObjectBindingPattern3.js.map
|
|
@ -0,0 +1,2 @@
|
|||
//// [sourceMapValidationDestructuringVariableStatementObjectBindingPattern3.js.map]
|
||||
{"version":3,"file":"sourceMapValidationDestructuringVariableStatementObjectBindingPattern3.js","sourceRoot":"","sources":["sourceMapValidationDestructuringVariableStatementObjectBindingPattern3.ts"],"names":[],"mappings":"AACK,oBAAO,EAAP,4BAAO,CAAc"}
|
|
@ -0,0 +1,30 @@
|
|||
===================================================================
|
||||
JsFile: sourceMapValidationDestructuringVariableStatementObjectBindingPattern3.js
|
||||
mapUrl: sourceMapValidationDestructuringVariableStatementObjectBindingPattern3.js.map
|
||||
sourceRoot:
|
||||
sources: sourceMapValidationDestructuringVariableStatementObjectBindingPattern3.ts
|
||||
===================================================================
|
||||
-------------------------------------------------------------------
|
||||
emittedFile:tests/cases/compiler/sourceMapValidationDestructuringVariableStatementObjectBindingPattern3.js
|
||||
sourceFile:sourceMapValidationDestructuringVariableStatementObjectBindingPattern3.ts
|
||||
-------------------------------------------------------------------
|
||||
>>>var _a = { x: 20 }.x, x = _a === void 0 ? 500 : _a;
|
||||
1 >
|
||||
2 >^^^^^^^^^^^^^^^^^^^^
|
||||
3 > ^^
|
||||
4 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
5 > ^
|
||||
6 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^->
|
||||
1 >
|
||||
>var {
|
||||
2 >x = 500
|
||||
3 >
|
||||
4 > x = 500
|
||||
5 > } = { x: 20 };
|
||||
1 >Emitted(1, 1) Source(2, 6) + SourceIndex(0)
|
||||
2 >Emitted(1, 21) Source(2, 13) + SourceIndex(0)
|
||||
3 >Emitted(1, 23) Source(2, 6) + SourceIndex(0)
|
||||
4 >Emitted(1, 51) Source(2, 13) + SourceIndex(0)
|
||||
5 >Emitted(1, 52) Source(2, 27) + SourceIndex(0)
|
||||
---
|
||||
>>>//# sourceMappingURL=sourceMapValidationDestructuringVariableStatementObjectBindingPattern3.js.map
|
|
@ -0,0 +1,6 @@
|
|||
=== tests/cases/compiler/sourceMapValidationDestructuringVariableStatementObjectBindingPattern3.ts ===
|
||||
|
||||
var {x = 500} = { x: 20 };
|
||||
>x : Symbol(x, Decl(sourceMapValidationDestructuringVariableStatementObjectBindingPattern3.ts, 1, 5))
|
||||
>x : Symbol(x, Decl(sourceMapValidationDestructuringVariableStatementObjectBindingPattern3.ts, 1, 17))
|
||||
|
|
@ -0,0 +1,9 @@
|
|||
=== tests/cases/compiler/sourceMapValidationDestructuringVariableStatementObjectBindingPattern3.ts ===
|
||||
|
||||
var {x = 500} = { x: 20 };
|
||||
>x : number
|
||||
>500 : number
|
||||
>{ x: 20 } : { x?: number; }
|
||||
>x : number
|
||||
>20 : number
|
||||
|
|
@ -0,0 +1,8 @@
|
|||
//// [sourceMapValidationDestructuringVariableStatementObjectBindingPattern4.ts]
|
||||
|
||||
var {x = 500,
|
||||
y} = { x: 20, y: "hi" };
|
||||
|
||||
//// [sourceMapValidationDestructuringVariableStatementObjectBindingPattern4.js]
|
||||
var _a = { x: 20, y: "hi" }, _b = _a.x, x = _b === void 0 ? 500 : _b, y = _a.y;
|
||||
//# sourceMappingURL=sourceMapValidationDestructuringVariableStatementObjectBindingPattern4.js.map
|
|
@ -0,0 +1,2 @@
|
|||
//// [sourceMapValidationDestructuringVariableStatementObjectBindingPattern4.js.map]
|
||||
{"version":3,"file":"sourceMapValidationDestructuringVariableStatementObjectBindingPattern4.js","sourceRoot":"","sources":["sourceMapValidationDestructuringVariableStatementObjectBindingPattern4.ts"],"names":[],"mappings":"AACA,IAAA,uBAC4B,EADvB,SAAO,EAAP,4BAAO,EACP,QAAC,CAAuB"}
|
|
@ -0,0 +1,47 @@
|
|||
===================================================================
|
||||
JsFile: sourceMapValidationDestructuringVariableStatementObjectBindingPattern4.js
|
||||
mapUrl: sourceMapValidationDestructuringVariableStatementObjectBindingPattern4.js.map
|
||||
sourceRoot:
|
||||
sources: sourceMapValidationDestructuringVariableStatementObjectBindingPattern4.ts
|
||||
===================================================================
|
||||
-------------------------------------------------------------------
|
||||
emittedFile:tests/cases/compiler/sourceMapValidationDestructuringVariableStatementObjectBindingPattern4.js
|
||||
sourceFile:sourceMapValidationDestructuringVariableStatementObjectBindingPattern4.ts
|
||||
-------------------------------------------------------------------
|
||||
>>>var _a = { x: 20, y: "hi" }, _b = _a.x, x = _b === void 0 ? 500 : _b, y = _a.y;
|
||||
1 >
|
||||
2 >^^^^
|
||||
3 > ^^^^^^^^^^^^^^^^^^^^^^^
|
||||
4 > ^^
|
||||
5 > ^^^^^^^^^
|
||||
6 > ^^
|
||||
7 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
8 > ^^
|
||||
9 > ^^^^^^^^
|
||||
10> ^
|
||||
11> ^^^^^^^^^^^^^^^^^^->
|
||||
1 >
|
||||
>
|
||||
2 >
|
||||
3 > var {x = 500,
|
||||
> y} = { x: 20, y: "hi" }
|
||||
4 >
|
||||
5 > x = 500
|
||||
6 >
|
||||
7 > x = 500
|
||||
8 > ,
|
||||
>
|
||||
9 > y
|
||||
10> } = { x: 20, y: "hi" };
|
||||
1 >Emitted(1, 1) Source(2, 1) + SourceIndex(0)
|
||||
2 >Emitted(1, 5) Source(2, 1) + SourceIndex(0)
|
||||
3 >Emitted(1, 28) Source(3, 29) + SourceIndex(0)
|
||||
4 >Emitted(1, 30) Source(2, 6) + SourceIndex(0)
|
||||
5 >Emitted(1, 39) Source(2, 13) + SourceIndex(0)
|
||||
6 >Emitted(1, 41) Source(2, 6) + SourceIndex(0)
|
||||
7 >Emitted(1, 69) Source(2, 13) + SourceIndex(0)
|
||||
8 >Emitted(1, 71) Source(3, 6) + SourceIndex(0)
|
||||
9 >Emitted(1, 79) Source(3, 7) + SourceIndex(0)
|
||||
10>Emitted(1, 80) Source(3, 30) + SourceIndex(0)
|
||||
---
|
||||
>>>//# sourceMappingURL=sourceMapValidationDestructuringVariableStatementObjectBindingPattern4.js.map
|
|
@ -0,0 +1,10 @@
|
|||
=== tests/cases/compiler/sourceMapValidationDestructuringVariableStatementObjectBindingPattern4.ts ===
|
||||
|
||||
var {x = 500,
|
||||
>x : Symbol(x, Decl(sourceMapValidationDestructuringVariableStatementObjectBindingPattern4.ts, 1, 5))
|
||||
|
||||
y} = { x: 20, y: "hi" };
|
||||
>y : Symbol(y, Decl(sourceMapValidationDestructuringVariableStatementObjectBindingPattern4.ts, 1, 13))
|
||||
>x : Symbol(x, Decl(sourceMapValidationDestructuringVariableStatementObjectBindingPattern4.ts, 2, 11))
|
||||
>y : Symbol(y, Decl(sourceMapValidationDestructuringVariableStatementObjectBindingPattern4.ts, 2, 18))
|
||||
|
|
@ -0,0 +1,14 @@
|
|||
=== tests/cases/compiler/sourceMapValidationDestructuringVariableStatementObjectBindingPattern4.ts ===
|
||||
|
||||
var {x = 500,
|
||||
>x : number
|
||||
>500 : number
|
||||
|
||||
y} = { x: 20, y: "hi" };
|
||||
>y : string
|
||||
>{ x: 20, y: "hi" } : { x?: number; y: string; }
|
||||
>x : number
|
||||
>20 : number
|
||||
>y : string
|
||||
>"hi" : string
|
||||
|
|
@ -0,0 +1,3 @@
|
|||
// @sourcemap: true
|
||||
|
||||
var [x] = [1, 2];
|
|
@ -0,0 +1,4 @@
|
|||
// @sourcemap: true
|
||||
|
||||
var [x] = [1, 2];
|
||||
var [y, z] = [1, 2];
|
|
@ -0,0 +1,3 @@
|
|||
// @sourcemap: true
|
||||
|
||||
var [x = 20] = [1, 2];
|
|
@ -0,0 +1,3 @@
|
|||
// @sourcemap: true
|
||||
|
||||
var [x = 20, j] = [1, 2];
|
|
@ -0,0 +1,3 @@
|
|||
// @sourcemap: true
|
||||
|
||||
var {x} = { x: 20 };
|
|
@ -0,0 +1,4 @@
|
|||
// @sourcemap: true
|
||||
|
||||
var {x} = { x: 20 };
|
||||
var { a, b } = { a: 30, b: 40 };
|
|
@ -0,0 +1,3 @@
|
|||
// @sourcemap: true
|
||||
|
||||
var {x = 500} = { x: 20 };
|
|
@ -0,0 +1,4 @@
|
|||
// @sourcemap: true
|
||||
|
||||
var {x = 500,
|
||||
y} = { x: 20, y: "hi" };
|
|
@ -0,0 +1,22 @@
|
|||
// @declaration: true
|
||||
|
||||
interface a { a }
|
||||
interface b { b }
|
||||
interface c { c }
|
||||
|
||||
type T1 = ([a, b, c]);
|
||||
type F1 = ([a, b, c]) => void;
|
||||
|
||||
type T2 = ({ a });
|
||||
type F2 = ({ a }) => void;
|
||||
|
||||
type T3 = ([{ a: b }, { b: a }]);
|
||||
type F3 = ([{ a: b }, { b: a }]) => void;
|
||||
|
||||
type T4 = ([{ a: [b, c] }]);
|
||||
type F4 = ([{ a: [b, c] }]) => void;
|
||||
|
||||
type C1 = new ([{ a: [b, c] }]) => void;
|
||||
|
||||
var v1 = ([a, b, c]) => "hello";
|
||||
var v2: ([a, b, c]) => string;
|
Loading…
Reference in a new issue