Josef Urban wrote:
On Fri, 22 Oct 2004, Frank Heckenbach wrote:
Probably for this reasone, EP forbids function results in `with' statements at all (6.9.3.10: withÂelement = variableÂaccess | constantÂaccess.). I don't know about other dialects (BP has no records as result types, so the issue doesn't arise. What about Delphi etc.?).
But pointers to records or objects are result types quite often. It seems to me that st. like
with foo(x)^ do ...
is useful in Delphi (or BP or FPC). As I understand it, the EP specification would forbid that too?
No, it allows it. That's not problematic since the pointer points to a more persistent object (record) which can meaningfully be modified etc. Whereas a function result just "disappears" after its use, so if that use is just an assignment, it's effectively meaningless. Frank -- Frank Heckenbach, frank@g-n-u.de, http://fjf.gnu.de/, 7977168E GPC To-Do list, latest features, fixed bugs: http://www.gnu-pascal.de/todo.html NEW! GPC download signing key: ACB3 79B2 7EB2 B7A7 EFDE D101 CD02 4C9D 0FE0 E5E8