File tree Expand file tree Collapse file tree 2 files changed +8
-0
lines changed Expand file tree Collapse file tree 2 files changed +8
-0
lines changed Original file line number Diff line number Diff line change @@ -5887,6 +5887,7 @@ Init
58875887 }
58885888 }
58895889 else if (node.type == "Declaration") {
5890+ if (node.children && node.children.length) createLetDecs(node.children, scopes)
58905891 node.names.forEach((name) => currentScope.add(name))
58915892 }
58925893 else {
Original file line number Diff line number Diff line change @@ -31,6 +31,7 @@ describe "auto let", ->
3131 """
3232
3333describe "auto let with function", ->
34+ // TODO: We should fix the return let here, this is invalid.
3435 testCase """
3536 auto let with function
3637 ---
@@ -41,13 +42,19 @@ describe "auto let with function", ->
4142 var b = 2
4243 }
4344 a = 2
45+ let c = (b) => {
46+ c = 1
47+ }
4448 ---
4549 let b = 1
4650 function b(a) {
4751 a = 1
4852 var b = 2
4953 }
5054 let a = 2
55+ let c = (b) => {
56+ return let c = 1
57+ }
5158 """
5259
5360describe "auto let with multiple declaration", ->
You can’t perform that action at this time.
0 commit comments