Path: utzoo!attcan!utgpu!jarvis.csri.toronto.edu!mailrus!iuvax!cica!tut.cis.ohio-state.edu!pt.cs.cmu.edu!sei!firth From: firth@sei.cmu.edu (Robert Firth) Newsgroups: comp.lang.modula2 Subject: Re: Overloading Operators: Extension to Language Message-ID: <4337@bd.sei.cmu.edu> Date: 5 Oct 89 13:21:38 GMT References: Reply-To: firth@sei.cmu.edu (Robert Firth) Organization: Software Engineering Institute, Pittsburgh, PA Lines: 12 In article Modula2 List writes: >I really don't see what the arguement is. If you wan't to return an >array or record why not just return the pointer? Visually it is still >obvious in the code what you are doing and is fast also. If you want >to return a new record or array, then there is NEW or ALLOCATE. Leaving aside the efficiency considerations of using dynamic storage needlessly, you still cannot do it this way. The syntax of Modula-2 does not allow the result of a function call to be dereferenced. Yet another mindlessly stupid restriction whose sole purpose seems to be to enforce one person's view of programming style on the world.