Oberon Community Platform Forum

Development => Oberon & Active Oberon => Topic started by: BohdanT on November 08, 2010, 02:36:49 PM



Title: ActiveOberon language report & Untraced
Post by: BohdanT on November 08, 2010, 02:36:49 PM
Quote from: Active Oberon Language Report
Untraced Pointers

Untraced pointers are pointers that are not traversed by the garbage collector. A structure or object referenced only through an untraced pointer may be collected at any time.

Untraced pointers are defined using the UNTRACED modifier.

TYPE  Untraced = POINTER {UNTRACED} TO T;

but if you try to compile:
Code:
MODULE Untraced;

TYPE
T = RECORD
 a,b:LONGINT;
END;
Untraced = POINTER{UNTRACED} TO T;

END Untraced.

We get the error message

PC.Compile Untraced.Mod~
Quote
Untraced.Mod compiling Untraced ... not done
   Untraced.Mod@72   error 28:   TO missing
   Untraced.Mod@72   error 40:   identifier expected
   Untraced.Mod@72   error 52:   identifier does not denote a type
   Untraced.Mod@72   error 57:   pointer not bound to record or array type
   Untraced.Mod@72   error 41:   ";" missing
   Untraced.Mod@72   error 43:   END missing
   Untraced.Mod@72   error 43:   END missing
   Untraced.Mod@72   error 40: Untraced  identifier expected
Compiler.Compile Untraced.Mod~
Quote
   Untraced.Mod@73   error 264: illegaly marked identifier
   Untraced.Mod   A2.Untraced could not be compiled (checker errors).