From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: * X-Spam-Status: No, score=1.8 required=5.0 tests=BAYES_20,FROM_STARTS_WITH_NUMS, INVALID_DATE autolearn=no autolearn_force=no version=3.4.4 Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Path: utzoo!mnetor!uunet!husc6!mit-eddie!ll-xn!ames!aurora!labrea!jade!ucbvax!NAVPGS.BITNET!4526P From: 4526P@NAVPGS.BITNET ("LT Scott A. Norton, USN") Newsgroups: comp.lang.ada Subject: Re: using 'address for callback Message-ID: <8709162054.AA24871@ucbvax.Berkeley.EDU> Date: Wed, 16-Sep-87 14:55:00 EDT Article-I.D.: ucbvax.8709162054.AA24871 Posted: Wed Sep 16 14:55:00 1987 Date-Received: Sat, 19-Sep-87 11:45:25 EDT Sender: daemon@ucbvax.BERKELEY.EDU Organization: The ARPA Internet List-Id: ( Please excuse me if I have a Pascal accent; I still can't write Ada without the book open in my lap. ) The disscussion on X-windows, particularly callbacks, has reawakend my interest in one of the design decisions from Steelman. The particular feature of Ada that caught my eye, when I first was learning the language, was that a procedure could not have a function or another procedure as a formal parameter. I don't think that "integrate( f, a, b )" is poor software engineering, but you can't do that directly in Ada. The Ada solution I saw in one text for integrating a function involved generics, but that seem kludgy to me. So, I'm asking: 1. Why does Ada not permit functions as formal parameters? 2. Is there some other clean way to model functionals ( functions of functions ) besides instantionating a generic for each pair of functional and its argument function? I realize that sometimes, a programming model that works well in one context produces serious inconsistancies in another. And so, we don't see Algol-60 call by name anymore. LT Scott A. Norton, USN Naval Postgraduate School Monterey, CA 93943-5018 4526P@NavPGS.BITNET