Contents | Prev | Next | Index
Name | Argument Type | result type | Function |
ABS(x) | numeric type | type of x | absolute value |
ASH(x,n) | x,n : integer type | LONGINT | arithmetic shift (x*2n) |
CAP(x) | CHAR | CHAR | corresponding capital letter |
CHR(x) | integer type | CHAR | character with ordinal number x |
ENTIER(x) | real type | LONGINT | largest integer not greater than x |
LEN(v,n) | v : array n : integer constant |
LONGINT | length of v in dimension n (first dimension = 0) |
LONG(x) | SHORTINT INTEGER REAL |
INTEGER LONGINT LONGREAL |
identity identity identity |
MAX(T) | T=basic type T=SET |
T INTEGER |
maximum value of type T maximum element of a set |
MIN(T) | T=basic type T=SET |
T INTEGER |
minimum value of type T 0 |
ODD(r) | integer type | BOOLEAN | x MOD 2 = 1 |
ORD(x) | CHAR | INTEGER | ordinal number of x |
SHORT(x) | LONGINT INTEGER LONGREAL |
INTEGER SHORTINT REAL |
identity identity identity (truncation possible) |
SIZE(T) | non-structured type | integer type | number of bytes required by T |
Note: Unlike other Oberon-2 implementations, this compiler does not accept structured types for the standard SIZE function. It is because structured types are mapped to Java classes or Java arrays, and they as well as all of their structured components are allocated accross uncontiguous different memory allocation blocks from the Java heap, with internal references pointing to them. Java Virtual Machines may also implement different alignment schemes. Hence, simply adding up the total size of the component types for a structured type wouldn't always yield a meaningful result.
Contents | Prev | Next | Index
Canterbury Oberon-2 for Java (Last documentation update
Feb 8, 2000)
Copyright © 1998 Mill Hill &
Canterbury Corporation, Ltd. All rights reserved
Please send any comments or corrections to
mhc@webcom.com