![]() |
Section 6.8:
|
![]() |
The abstract form of expression syntax is quite different from the concrete syntax expressions defined above and in the other pages of this section of the specification.
The detail given in the following is expanded on other expression pages as necessary using invariants and well-formedness functions.An expression which returns a handle to some storage location may provide this in one of three ways :-
This type models an uninterpretable token provided to a program from its external environment.
This type models a location which is on the computer system which created the location.
This type models a location which is not on the computer system which created the location.
An Address models a computer location which may be derived by an implementation as the result of using programming expressions. It refers to a location which is defined by the Sather language. The actual location (or indeed address token) indicated during any program execution is implementation dependent.
A value expression yields a value of some program type the semantics of which are defined by the defining class. The way in which such values may be manipulated is not defined by the Sather language.
The bit pattern is the fundamental way of expressing values of any kind. Any semantics attributed to it are defined by the appropriate class definition. The length of the sequence for any given class is implementation defined.
The Sather language definition requires that numeric and textual values may be expressed when writing programs. The form in which such values appear is necessarily implementation defined.
NOTE | It is important to note that the language specifies no operations on such values unless they are converted into a required library (or other) numeric or text class which defines those pre-defined operations such as add, minus, times, etc. |
Sather defines two general forms of user-specifiable literal values - numbers and text (including individual characters). This type models both the token value and the kind of literal it represents.
Sather defines a small number of literal values which are modelled by the following small group of types.
Those values which need to be evaluated from some form of expression are treated as routines - either predefined or programmer written.
This model type describes routines which have been written in the language and which return a value. They thus form a strict subset of Feature_Applications (for which a return value is optional).
The Predefined Call expression consists of those individual concrete syntax statements such as exception, self, is_void, etc. They are thus a strict subset of Predefined Applications, having a mandatory return value.
![]() |
Specification Index | ![]() |
Language Index | ![]() |
Section 6 Index |
Comments
or enquiries should be made to Keith Hopper. Page last modified: Tuesday, 23 May 2000. |
![]() |