Ver Fonte

Sync with wiki pages

Vladislav Folts há 4 anos atrás
pai
commit
3a6f606f92

+ 2 - 2
doc/wiki/eberon-operator-NEW.md

@@ -16,8 +16,8 @@ Operator NEW in [[Eberon|eberon]] returns a pointer to created record. So code a
 
 Also operator NEW can be used to initialize a pointer variable to base record (while creating derived record):
 
-    IF condtition1 THEN
-        base := NEW Dervied1();
+    IF condition1 THEN
+        base := NEW Derived1();
     ELSE
         base := NEW Derived2();
     END;

+ 1 - 1
doc/wiki/eberon-record-constructor.md

@@ -97,7 +97,7 @@ Fields of non-record types also can be referenced in initialization list. In thi
     END;
 
 Fields must be referenced in the initialization list in the same order as they declared in record. For example above "f2(TRUE), f1(123)" will cause compiler error.
-Only record's own fields can be referenced (not fields from base record). Fields of non-record types may be missed in the list - in this case they will be initialized using default values. Record fields having constructor without parameters will be initialized automatically and must be not referenced in initialzation list. All fields are initialized strictly in the same order as they declared in record - no matter if they referenced in the initialization list or initialized automatically. It is possible to use *SELF* in initialization list but be aware of the initialization order - do not use *SELF* to access not initialized field (the compiler does not diagnose that).
+Only record's own fields can be referenced (not fields from base record). Fields of non-record types may be missed in the list - in this case they will be initialized using default values. Record fields having constructor without parameters will be initialized automatically and must be not referenced in initialization list. All fields are initialized strictly in the same order as they declared in record - no matter if they referenced in the initialization list or initialized automatically. It is possible to use *SELF* in initialization list but be aware of the initialization order - do not use *SELF* to access not initialized field (the compiler does not diagnose that).
 
 The order of execution in constructor: 
 * call base constructor (if present), using *SUPER* (with parameters) or automatically (no parameters)

+ 1 - 1
doc/wiki/eberon.md

@@ -1,4 +1,4 @@
-**Eberon** is Experimental oBERON. It is my attempt to make a programming language in the right way (in my humble opinion of cause) taking Wirth's Oberon as a start point.
+**Eberon** is Experimental oBERON. It is my attempt to make a programming language in the right way (in my humble opinion of course) taking Wirth's Oberon as a start point.
 
 Eberon basically extends original Oberon (excluding additional [restrictions](#restrictions) below) so any valid oberon program is also a valid eberon program. A new syntax was introduced for extensions but I tried to maintain the original syntax flavor (e.g. CAPS).