I've submitted a pull request to fix the bug in the goto example code:
jucasan:
btw, why most of the examples in the reference pages are so bad?
I don't know, but it's easy enough to fix. You can submit fixes or bug reports to the reference-en repository, which contains all the Arduino Language Reference content. The Arduino team is pretty good about merging pull requests to that repo in a timely manner. For more information, see:
If you don't have a GitHub account, or want to discuss potential changes first here on the forum, then please do create a thread here.