File: letAndVarRedeclaration.errors.txt

package info (click to toggle)
node-typescript 5.0.4%2Bds1-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 459,140 kB
  • sloc: javascript: 1,972,754; makefile: 6; sh: 1
file content (117 lines) | stat: -rw-r--r-- 4,621 bytes parent folder | download | duplicates (5)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
tests/cases/compiler/letAndVarRedeclaration.ts(1,5): error TS2300: Duplicate identifier 'e0'.
tests/cases/compiler/letAndVarRedeclaration.ts(2,5): error TS2300: Duplicate identifier 'e0'.
tests/cases/compiler/letAndVarRedeclaration.ts(3,10): error TS2300: Duplicate identifier 'e0'.
tests/cases/compiler/letAndVarRedeclaration.ts(6,9): error TS2300: Duplicate identifier 'x1'.
tests/cases/compiler/letAndVarRedeclaration.ts(7,9): error TS2300: Duplicate identifier 'x1'.
tests/cases/compiler/letAndVarRedeclaration.ts(8,14): error TS2300: Duplicate identifier 'x1'.
tests/cases/compiler/letAndVarRedeclaration.ts(12,9): error TS2451: Cannot redeclare block-scoped variable 'x'.
tests/cases/compiler/letAndVarRedeclaration.ts(14,13): error TS2451: Cannot redeclare block-scoped variable 'x'.
tests/cases/compiler/letAndVarRedeclaration.ts(17,18): error TS2451: Cannot redeclare block-scoped variable 'x'.
tests/cases/compiler/letAndVarRedeclaration.ts(22,9): error TS2300: Duplicate identifier 'x2'.
tests/cases/compiler/letAndVarRedeclaration.ts(23,9): error TS2300: Duplicate identifier 'x2'.
tests/cases/compiler/letAndVarRedeclaration.ts(24,14): error TS2300: Duplicate identifier 'x2'.
tests/cases/compiler/letAndVarRedeclaration.ts(28,9): error TS2451: Cannot redeclare block-scoped variable 'x2'.
tests/cases/compiler/letAndVarRedeclaration.ts(30,13): error TS2451: Cannot redeclare block-scoped variable 'x2'.
tests/cases/compiler/letAndVarRedeclaration.ts(33,18): error TS2451: Cannot redeclare block-scoped variable 'x2'.
tests/cases/compiler/letAndVarRedeclaration.ts(37,5): error TS2451: Cannot redeclare block-scoped variable 'x11'.
tests/cases/compiler/letAndVarRedeclaration.ts(38,10): error TS2451: Cannot redeclare block-scoped variable 'x11'.
tests/cases/compiler/letAndVarRedeclaration.ts(42,9): error TS2451: Cannot redeclare block-scoped variable 'x11'.
tests/cases/compiler/letAndVarRedeclaration.ts(43,14): error TS2451: Cannot redeclare block-scoped variable 'x11'.
tests/cases/compiler/letAndVarRedeclaration.ts(48,9): error TS2451: Cannot redeclare block-scoped variable 'x11'.
tests/cases/compiler/letAndVarRedeclaration.ts(49,14): error TS2451: Cannot redeclare block-scoped variable 'x11'.


==== tests/cases/compiler/letAndVarRedeclaration.ts (21 errors) ====
    let e0
        ~~
!!! error TS2300: Duplicate identifier 'e0'.
    var e0;
        ~~
!!! error TS2300: Duplicate identifier 'e0'.
    function e0() { }
             ~~
!!! error TS2300: Duplicate identifier 'e0'.
    
    function f0() {
        let x1;
            ~~
!!! error TS2300: Duplicate identifier 'x1'.
        var x1;
            ~~
!!! error TS2300: Duplicate identifier 'x1'.
        function x1() { }
                 ~~
!!! error TS2300: Duplicate identifier 'x1'.
    }
    
    function f1() {
        let x;
            ~
!!! error TS2451: Cannot redeclare block-scoped variable 'x'.
        {
            var x;
                ~
!!! error TS2451: Cannot redeclare block-scoped variable 'x'.
        }
        {
            function x() { }
                     ~
!!! error TS2451: Cannot redeclare block-scoped variable 'x'.
        }
    }
    
    module M0 {
        let x2;
            ~~
!!! error TS2300: Duplicate identifier 'x2'.
        var x2;
            ~~
!!! error TS2300: Duplicate identifier 'x2'.
        function x2() { }
                 ~~
!!! error TS2300: Duplicate identifier 'x2'.
    }
    
    module M1 {
        let x2;
            ~~
!!! error TS2451: Cannot redeclare block-scoped variable 'x2'.
        {
            var x2;
                ~~
!!! error TS2451: Cannot redeclare block-scoped variable 'x2'.
        }
        {
            function x2() { }
                     ~~
!!! error TS2451: Cannot redeclare block-scoped variable 'x2'.
        }
    }
    
    let x11;
        ~~~
!!! error TS2451: Cannot redeclare block-scoped variable 'x11'.
    for (var x11; ;) {
             ~~~
!!! error TS2451: Cannot redeclare block-scoped variable 'x11'.
    }
    
    function f2() {
        let x11;
            ~~~
!!! error TS2451: Cannot redeclare block-scoped variable 'x11'.
        for (var x11; ;) {
                 ~~~
!!! error TS2451: Cannot redeclare block-scoped variable 'x11'.
        }
    }
    
    module M2 {
        let x11;
            ~~~
!!! error TS2451: Cannot redeclare block-scoped variable 'x11'.
        for (var x11; ;) {
                 ~~~
!!! error TS2451: Cannot redeclare block-scoped variable 'x11'.
        }
    }