Re: My Lobbying
- Posted by Al Getz <xaxo at AOL.COM> Sep 06, 2000
- 456 views
Irv, Thanks for your input. Have you posted YourLobbying to the list site? I'd like to see some more of your ideas too. >>> Irv wrote: First of all, you can already declare a variable within a routine with the same name as a global variable. There are no error messages. The local is the one that gets referenced. <<< Yes, but local file declarations would be the goal here: ------------------------------------ in file.exw: global atom FirstAtom FirstAtom=1.1 --global ------------------------------------- in file.ew: local atom FirstAtom FirstAtom=2.2 --local procedure PrintAllAtoms() atom FirstAtom FirstAtom=3.3 -- or declared in procedure declaration -- and passed. --C++ style access: printf(1,"%f\n",::FirstAtom) --prints global atom "1.1" printf(1,"%f\n", :FirstAtom) --prints file local atom "2.2" printf(1,"%f\n", FirstAtom) --prints proc private atom "3.3" --Irv's style access: printf(1,"%f\n",global FirstAtom) --prints global atom printf(1,"%f\n",local FirstAtom) --prints file local atom printf(1,"%f\n", FirstAtom) --prints proc private atom end procedure --------------------------------------- Of course almost any style access would be fine, as long as the three types of variables can be accessed. >>> Irv wrote: Wouldn't help, even If we knew the structure, since we can't find it. <<< If Euphoria can find it, we can find it. >>> on if defined, if not defined Irv also wrote: But why? <<< if defined, if not defined: One obvious use here is when declaring constants: you have a program written declaring constants and some constants generate errors because they are already declared in someone elses program (like Win32Lib). I think a better way around this one though is to create a single file to declare all windows constants. Users of Win32Lib could simply declare this, or declare it in Win32Lib. Win32Lib wrappers could be spared the task of including constants in their works. Any other ideas? Thanks, --Al