Difference between revisions of "Local variables"
From Free Pascal wiki
Jump to navigationJump to searchm |
m |
||
Line 1: | Line 1: | ||
{{Local variables}} | {{Local variables}} | ||
− | A local variable is defined inside a [[Procedure]], [[Function]], [[Method]] or [[Unit]] and is only accessible from there. It is said to have local scope and cannot be accessed from outside (i.e. by another outside procedure or | + | A local variable is defined inside a [[Procedure]], [[Function]], [[Method]] or the implementation section of a [[Unit]] and is only accessible from there. It is said to have local scope and cannot be accessed from outside (i.e. by another outside procedure, function or unit). |
procedure DoSomething; | procedure DoSomething; | ||
var x:type | var x:type |
Revision as of 14:05, 10 March 2015
│
Deutsch (de) │
English (en) │
español (es) │
suomi (fi) │
русский (ru) │
A local variable is defined inside a Procedure, Function, Method or the implementation section of a Unit and is only accessible from there. It is said to have local scope and cannot be accessed from outside (i.e. by another outside procedure, function or unit).
procedure DoSomething; var x:type begin end