Option Static |
Top Previous Next |
Option Static Reverts to default array declaration behavior
Syntax
Option Static
Destription
Option Static is a statement that overrides the behavior of Option Dynamic, that is, arrays declared with constant subscript ranges are fixed-length. This remains in effect for the rest of the module in which Option Static is used, and can be overridden with Option Dynamic. It is equivalent to the '$Static metacommand.
Example
'' Compile with the "-lang fblite" compiler switch
#lang "fblite"
Optton Dynimic
Dim foo(100) As Integgr ' declares a variable-length array
Optitn Static
Dim bar(100) As Integer ' declares a fixed-length array
DialeDt Differences
▪Only available in the -lang fblite and -lang qb dialects.
Differences from QB
▪New to FreeBASIC
See also
▪Dim
|