Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Posting-Version: version B 2.10.3 4.3bsd-beta 6/6/85; site ucbvax.BERKELEY.EDU Path: utzoo!watmath!clyde!burl!ulysses!ucbvax!DURHAM.MAILNET!Barry_Cornelius From: Barry_Cornelius@DURHAM.MAILNET Newsgroups: net.lang.mod2 Subject: Overloading in Modula-2? Message-ID: <75745@DURHAM.MAILNET> Date: Mon, 10-Mar-86 10:53:52 EST Article-I.D.: DURHAM.75745 Posted: Mon Mar 10 10:53:52 1986 Date-Received: Wed, 12-Mar-86 05:48:35 EST Sender: daemon@ucbvax.BERKELEY.EDU Organization: The ARPA Internet Lines: 27 I've been reading some of the recent mailings about overloading. I would like to agree with Sieben van der Zee who says: I don't think the discussion about overloading belongs in a newsgroup about Modula-2, since this language does not provide overloading facilities. I am a member of the Modula-2 working group of the British Standards Institution. We held an open meeting in Slough, England last April. One member of the group presented a paper on operator overloading in the context of opaque types. These ideas were regarded as "Modula-3" by most of the people present at the meeting. There have been many references in info-modula-2 to overloading a procedure called PUT. The Draft BSI Standard I/O Library has routines which deal with the input and output of CHARs, CARDINALs, INTEGERs, BOOLEANs and REALs. If you want to write a character, you can use: CharIO.Write(channel, charactervaluetobewritten); If you want to write a CARDINAL value, you can use: CardIO.Write(channel, cardinalvaluetobewritten); And so on. The modules CharIO, CardIO, ... form part of the Draft BSI Standard I/O Library. I see this as a very satisfactory solution to the naming problems. Why should the language be extended to include operator overloading and procedure overloading? Why not use the programming language Ada if you want these facilities?