MEMVAR
Declares private and public variables and arrays.
Syntax
MEMVAR <xVar>
Arguments
<xVar> Memory variable Name
Description
This command tells the compiler to resolve any reference to a memory variable designated within this list s if it possessed an explicit memory variable alias with either the M-> or MEMVAR-> prefix.Only those memory variables that do not contain any such explicit are affected by this command. Those memory variabls within macro expansions are not affected by this command.
The MEMVAR declaration must apear before any executable commands;it is similat to the LOCAL, STATIC, FIELD, PARAMETERS, FUNCTION, and PROCEDURE commands statements.
Examples
MEMVAR y AS NUMERIC PROCEDURE Main() LOCAL n, lVar n := iif( lVar, "A", 3 ) n := 2 n := "a" n := seconds() + 2 n := int( seconds() + 2 ) y := n ? y RETURN
Tests
See tests/testwarn.prg for more examples
Compliance
Clipper
Platforms
All
Files
None.
Seealso
LOCAL, STATIC, FIELD, PRIVATE, PUBLIC
Pingback: Harbour Statements | Viva Clipper !
Pingback: Harbour Commands | Viva Clipper !
Pingback: Harbour RG Summary | Viva Clipper !