Peter Gerwinski wrote:
Hi, GPC folks,
Orlando Llanes wrote:
[Qualified identifiers ...]
I think it can be added without much effort. One possibility is to set
the root node to the unit or program name, then create a seperate symbol table for each. When it's necessary to create jump targets/etc, just combine the unit name with the identifier. [...]
Exactly.
BTW, that's about the same way how methods of objects are implemented. Currently, a method "Foo" of a method "Bar" is named "Bar_Foo". (In contrast, if you define your own "procedure Bar_Foo" it becomes "Bar_foo", internally.)
When doing this correctly, we must make sure that there are no name clashes - between units and objects, and in no other way. Thus, at the same time, the OOP naming scheme should be rewritten.
Since objects type names should also be qualified then, this should not clash...
Frank