On 22 Nov 2002 at 21:46, Waldek Hebisch wrote:
Frank Heckenbach wrote (about foo() syntax):
[...]
I think the rational reason is overloading: if one wants methods and atributes to share a name, then the syntax must distingush between variables and parameterless functions. Few days ago I was thinking about C++ compatibility -- to call methods of C++ objects one needs to have compatible overloading and inheritance model, and that includes distinction between variables and functions (alternatively one have to do massive renaming). I do not know how far Delphi moved in such direction,
Not very far. Delphi has things like function and method overloading, commenting with "//", and things like "foo()". Delphi has "variants" (compatible with virtually any type), and things like "Array of Const" parameters. But I am not sure whether these were borrowed from C++ or not.
but at the moment the main reason that dominat languages stay popular are libraries and legacy code. So, the ability to use C++ libraries may be (is?) big plus for Delphi.
Delphi cannot (yet) use C++ libraries - but C++ Builder can use Delphi (i.e., Pascal) units.
Personally, I think that GPC should try to be superset of Delphi, however debatable features should be switchable (between on, warning and off) independently -- so that even in Delphi mode one should be able to exclude them.
That would be nice. But I think we are probably a long way from realising that. I think that GPC is very thinly spread. We are a "broad church" and comprise so many interests. Not all those interests are necessarily always compatible with each other. This slows things down (compared to a single church (e.g., just 7185 or 10206 or BP)) but is inevitable if we are to keep our broad church - and I think that we must keep it. Eventually we will get there - as more of us become more proficient in C, and/or acquire increased knowledge of the compiler.
Best regards, The Chief -------- Prof. Abimbola A. Olowofoyeku (The African Chief) web: http://www.bigfoot.com/~african_chief/