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.9 required=5.0 tests=BAYES_00 autolearn=ham autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,34872f3f22b5b140 X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2002-11-11 07:31:57 PST Newsgroups: comp.lang.ada Path: archiver1.google.com!news1.google.com!newsfeed.stanford.edu!logbridge.uoregon.edu!uunet!sea.uu.net!sac.uu.net!ash.uu.net!world!news From: Robert A Duff Subject: Re: Suggestion for gnatstub User-Agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.2 Sender: news@world.std.com (Mr Usenet Himself) Message-ID: Date: Mon, 11 Nov 2002 15:31:10 GMT Content-Type: text/plain; charset=us-ascii References: <3dcb9e51$0$303$bed64819@news.gradwell.net> <3DCBC4C9.AD436CD9@earthlink.net> NNTP-Posting-Host: shell01.theworld.com Mime-Version: 1.0 Organization: The World Public Access UNIX, Brookline, MA Xref: archiver1.google.com comp.lang.ada:30730 Date: 2002-11-11T15:31:10+00:00 List-Id: "Marin David Condic" writes: > Robert A Duff wrote in message > news:wcc65v5maiv.fsf@shell01.TheWorld.com... > > > > To me, "null;" means "this procedure does nothing". You're suggesting > > to overload it to also mean "I haven't gotten around to writing this > > procedure yet". > > > I can't think of too many other reasons to write a null procedure. If it was > going to stay null forever, then why have it at all. Seems like the > mechanism is there so you can have a procedure waiting for the programmer to > find the elusive Round Tuit. :-) I can't think of "too many", either, but I can think of some. Just the other day I wrote a generic procedure to walk a tree. The generic takes two generic formal procedures, Pre_Action and Post_Action, which are called during the tree at the points you would guess. They have defaults, "is Do_Nothing", so you can specify one or the other. Guess what procedure Do_Nothing looks like. ;-) > Well, everybody has different styles and sometimes its a matter of what is > appropriate for the application at hand. Sometimes writing a bunch of test > drivers is the way to go. Sometimes maybe one should just fill in all the > code and get staarted testing the thing in one big gigantic thrust. But I > think you can see that lots of things get built in iterative builds where > some portion of the system remains as stubs to be filled in at a later time. Just to be clear on what I was saying about my style (which I agree is not everybody's style): I often test and debug one procedure in a package before writing some other procedure in the same package. For that, I'd like the editor to insert compile-able but not runnable code. But I don't usually debug one procedure while the procedures it calls have not yet been written. - Bob