Topic: binding of names to objects
Topic: data type as a set of values
Group: data value
Topic: parameter passing by reference
Topic: pointers to data
Topic: replacement as moving information
Topic: replacement as setting a reference to a value
Topic: variable as reference to storage
Topic: variable as function that accesses an object's value
| |
Summary
Variables reference a value (or an object representing a value). Such variables are the abstractions of parameters and arguments. When accessed ("dereferenced") only a copy of the value is made available; the object representing the value is not itself moved. The value's location is not fixed. For instance, the reference 'A(i)' may refer to any one of several values in different locations. Declaring a variable's type limits the values it can reference, but allows modification within a value set. (cbb 5/80)
Subtopic: variable as operand
Quote: a variable is an abstraction of an operand [»cbb_1973, OK]
| Quote: all uses of the variable 'x' can be transformed into qualification, classes, functions, or combinators; e.g., singular description [»quinWV2_1947]
| Subtopic: variable as reference to value
Quote: what is the meaning of a name in a program? In Bliss, it is a location. In Algol 68, it is a location that is automatically converted to a value. In C, it is a value. [»ritcDM_1996]
| Quote: a designator is an expression that denotes a variable or a variable's value; either readonly or writable
| Quote: assigning a name to a value is the same as assigning a title to a person [»hehnEC_1977a]
| Quote: a variable is a character string that stands for some value in some type domain
| Quote: a constant is a permanent name for a value; a variable is a temporary name [»hehnEC7_1975]
| Quote: a reference to a structure is a constant, its value; a reference to a reference is a variable, resolved to a constant [»edwaJ10_2005]
| QuoteRef: hehnEC7_1975 ;;58 "a variable stands for a value"
| QuoteRef: hehnEC7_1975 ;;16 variable is literal [another literal, j: 2*i+1] with type value e.g., name: var in sectorlist
| Subtopic: variable as address of value
Quote: Turing and Newman explained to Williams and Kilburn how numbers live in houses with addresses [»copeBJ_1999]
| Quote: the value of an expression can be a variable that holds the value; dereferencing obtains the value [»hansDR5_1978]
| Quote: a variable denotes a fixed address whose content is its value [»straC3_1973]
| Quote: treat a name in a program as a value that points or refers to another value [»vanwA_1969]
| QuoteRef: liskBH2_1976 ;;10 A CLU variable is a program local reference to an object i.e. "execution of x := 3 results in variable x denoting the object 3",
| Subtopic: reference as synonym for variable
Quote: a C++ reference to a type is a synonym for the variable it is initialized to; used for overloaded operators, functions, and both sides of assignments [»stroB_1991]
| Quote: a reference type is an explicitly typed object allocated from the heap; unique identity and type handle
| Quote: any value type instance can be boxed and turned into a reference type instance; inherits from ValueType or Enum; no subtyping [»hamiJ2_2003]
| Subtopic: pointer and value semantics
Quote: a data type is semantically transparent if primitive operations create new values instead of altering existing ones; makes value and pointer semantics the same [»cleaJC_1986]
| Quote: use pointer semantics and semantically transparent types to implement value semantics; e.g., SETL
| Quote: with pointer semantics, a variable is a pointer to a storage location with a value; assignment copies pointers; e.g., SNOBOL and C for arrays [»cleaJC_1986]
|
Related Topics
Topic: binding of names to objects (19 items)
Topic: data type as a set of values (20 items)
Group: data value (19 topics, 433 quotes)
Topic: parameter passing by reference (11 items)
Topic: pointers to data (55 items)
Topic: replacement as moving information (4 items)
Topic: replacement as setting a reference to a value (10 items)
Topic: variable as reference to storage (12 items)
Topic: variable as function that accesses an object's value (21 items)
|