Skip to content

Commit a89de35

Browse files
committed
closes #2498
1 parent bf66ad6 commit a89de35

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

1-js/02-first-steps/13-while-for/article.md

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -363,12 +363,14 @@ Labels do not allow us to jump into an arbitrary place in the code.
363363
364364
For example, it is impossible to do this:
365365
```js
366-
break label; // doesn't jumps to the label below
366+
break label; // jump to the label below (doesn't work)
367367
368368
label: for (...)
369369
```
370370
371-
A call to `break/continue` is only possible from inside a loop and the label must be somewhere above the directive.
371+
A call to `continue` is only possible from inside the loop.
372+
373+
The `break` directive may be placed before code blocks too, as `label: { ... }`, but it's almost never used like that. And it also works only inside-out.
372374
````
373375

374376
## Summary

0 commit comments

Comments
 (0)