Re: scope of variables

new topic     » goto parent     » topic index » view thread      » older message » newer message
useless said...
jaygade said...

I think that it should be changed. The current behavior is inconsistent with other languages and unintuitive. One would expect a block started by a loop or an decision block to work the same as a block defined by a procedure or function.


I disagree. If i need a variable, i declare it at the top of the procedure.

I do too. I thought that everyone did. I thought that it was required by the language.

Now if your vote is to remove the feature of declaring variables in blocks other than procedures and functions, then that's valid. I never thought that it was much of a feature anyway.

useless said...

Gosh, you can declare junk[1..5000] and prolly not run out of nested "decision block" junk[x], and you have the feature that all the junk is available outside that level too.

useless

I don't know what you mean.

new topic     » goto parent     » topic index » view thread      » older message » newer message

Search



Quick Links

User menu

Not signed in.

Misc Menu