in reply to Re^2: Variables and Scope: The battle begins
in thread Variables and Scope: The battle begins

All my subs are called with arguments, so the ()'s are always there

Actually, no they aren't ;). Your code includes &getinput; and &status calls without arguments at least. Just goes to show how easy it is for code not to be the way you think it is!

If you haven't resolved the issue yet you should try to strip out code until you find the problem or you have a sample script with a minimum of irrelevant code and still demonstrating the issue. You may find I know what I mean. Why don't you? helps focus your effort.

True laziness is hard work

Replies are listed 'Best First'.
Re^4: Variables and Scope: The battle begins
by Shadow-Master (Initiate) on Dec 12, 2013 at 20:14 UTC
    You are right, neither of those have arguments. status neither takes any nor returns any, it just prints the status of several variables. getinput returns an argument (the input). Neither affect global variables.
    However, you are right in that code can often be misleading. I have stripped all the &'s from my code and confirmed that it still functions like I expected it to. I have yet to try again with global vars, so we will see how that goes.