Skip to content

Commit b26bc37

Browse files
authored
Merge pull request ruanyf#811 from CosSalt/patch-5
函数内部重新声明参数
2 parents 29abe06 + b72d92a commit b26bc37

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

docs/let.md

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -201,14 +201,16 @@ function func() {
201201

202202
```javascript
203203
function func(arg) {
204-
let arg; // 报错
204+
let arg;
205205
}
206+
func() // 报错
206207

207208
function func(arg) {
208209
{
209-
let arg; // 不报错
210+
let arg;
210211
}
211212
}
213+
func() // 不报错
212214
```
213215

214216
## 块级作用域

0 commit comments

Comments
 (0)