We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 5172d8f commit 94d7e30Copy full SHA for 94d7e30
src/compiler/checker.ts
@@ -1420,7 +1420,6 @@ namespace ts {
1420
}
1421
break;
1422
case SyntaxKind.MethodDeclaration:
1423
- case SyntaxKind.MethodSignature:
1424
case SyntaxKind.Constructor:
1425
case SyntaxKind.GetAccessor:
1426
case SyntaxKind.SetAccessor:
tests/baselines/reference/arguments.errors.txt
@@ -0,0 +1,29 @@
1
+tests/cases/compiler/arguments.ts(6,25): error TS2304: Cannot find name 'arguments'.
2
+tests/cases/compiler/arguments.ts(7,23): error TS2304: Cannot find name 'arguments'.
3
+tests/cases/compiler/arguments.ts(8,19): error TS2304: Cannot find name 'arguments'.
4
+tests/cases/compiler/arguments.ts(9,23): error TS2304: Cannot find name 'arguments'.
5
+tests/cases/compiler/arguments.ts(10,34): error TS2304: Cannot find name 'arguments'.
6
+
7
8
+==== tests/cases/compiler/arguments.ts (5 errors) ====
9
+ function f() {
10
+ var x=arguments[12];
11
+ }
12
13
+ interface I {
14
+ method(args: typeof arguments): void;
15
+ ~~~~~~~~~
16
+!!! error TS2304: Cannot find name 'arguments'.
17
+ fn: (args: typeof arguments) => void;
18
19
20
+ (args: typeof arguments): void;
21
22
23
+ new (args: typeof arguments): void;
24
25
26
+ construct: new (args: typeof arguments) => void;
27
28
29
tests/baselines/reference/arguments.js
@@ -1,6 +1,14 @@
//// [arguments.ts]
function f() {
var x=arguments[12];
+}
+interface I {
//// [arguments.js]
tests/baselines/reference/arguments.symbols
@@ -6,3 +6,25 @@ function f() {
>x : Symbol(x, Decl(arguments.ts, 1, 7))
>arguments : Symbol(arguments)
+>I : Symbol(I, Decl(arguments.ts, 2, 1))
+>method : Symbol(I.method, Decl(arguments.ts, 4, 13))
+>args : Symbol(args, Decl(arguments.ts, 5, 11))
+>fn : Symbol(I.fn, Decl(arguments.ts, 5, 41))
+>args : Symbol(args, Decl(arguments.ts, 6, 9))
+>args : Symbol(args, Decl(arguments.ts, 7, 5))
+>args : Symbol(args, Decl(arguments.ts, 8, 9))
+>construct : Symbol(I.construct, Decl(arguments.ts, 8, 39))
+>args : Symbol(args, Decl(arguments.ts, 9, 20))
30
tests/baselines/reference/arguments.types
@@ -8,3 +8,28 @@ function f() {
>arguments : IArguments
>12 : 12
+>method : (args: any) => void
+>args : any
+>arguments : any
+>fn : (args: any) => void
31
32
+>construct : new (args: any) => void
33
34
35
tests/cases/compiler/arguments.ts
@@ -1,3 +1,11 @@
0 commit comments