Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Name of variables: an issue
#8
I must add that the discussion above always applies in global scope. Within subprograms one has to be careful with using "global" variables, ie. those defined as "DIM SHARED" near the top of the source code, or declared as "SHARED" within the subprogram. Those could suddenly throw up an "Duplicate definition" or "Name already in use" (geez I despise this last one) when it has to do with global variables to be used inside subprograms. Otherwise "DIM x AS INTEGER", "DIM x AS _MEM" etc. could be freely implemented in subprograms kept separate from one another, and especially those found in "$INCLUDE'd" files.

Once there is a "DIM SHARED x AS LONG" before any subprogram cannot "re-type" "x" to anything else unless it's "x$" or other type which is not UDT (and in this example only, except "x&").
Reply


Messages In This Thread
Name of variables: an issue - by TempodiBasic - 08-30-2022, 06:12 AM
RE: Name of variables: an issue - by SMcNeill - 08-30-2022, 06:18 AM
RE: Name of variables: an issue - by TempodiBasic - 08-30-2022, 03:01 PM
RE: Name of variables: an issue - by SMcNeill - 08-30-2022, 03:32 PM
RE: Name of variables: an issue - by TempodiBasic - 08-31-2022, 11:47 PM
RE: Name of variables: an issue - by TDarcos - 09-09-2022, 01:25 PM
RE: Name of variables: an issue - by mnrvovrfc - 09-09-2022, 04:19 PM
RE: Name of variables: an issue - by mnrvovrfc - 09-09-2022, 04:33 PM
RE: Name of variables: an issue - by TDarcos - 09-26-2022, 12:52 AM
RE: Name of variables: an issue - by mnrvovrfc - 09-26-2022, 05:13 AM
RE: Name of variables: an issue - by Pete - 09-26-2022, 08:18 PM
RE: Name of variables: an issue - by Petr - 10-01-2022, 07:21 PM



Users browsing this thread: 3 Guest(s)