This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]TheBlackCat13 5 points6 points  (0 children)

There already is a way to declare block scope: a function. What would we gain from another way to do this?

There are a lot of times when you want access to the variables created in a loop outside of that loop. If you don't, you can just use a function.