Polymorphism: Difference between revisions
Content added Content deleted
Line 2,292: | Line 2,292: | ||
A Class: label direct interpreter to not include any after in the returned group, a float group, which return a Class function. |
A Class: label direct interpreter to not include any after in the returned group, a float group, which return a Class function. |
||
A class function is global by default, except in a class definition which is a member of group. |
A class function is global by default, except in a class definition which is a member of group. |
||
In following examples there is a block for temporary objects. We make a MM as a group, and at the exit of the block, group erased, so next time we make a new one. |
|||
Syntax: |
|||
<lang M2000 Interpreter> |
|||
\\ block For This {}, or For object [, object2] { }, where object is a group, or a pointer to group, or an item from an array contains a group |
|||
\\ This is "this context". |
|||
For This { |
|||
\\ any new definition here has a temporary use |
|||
\\ can be nested, but if we use object then we can use dots to access members of it. If we use a second one then we have to use double dots (..x for second object, for access to x member) |
|||
} |
|||
</lang> |
|||