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.3 required=5.0 tests=BAYES_00,INVALID_MSGID autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,496108d9dbc25896 X-Google-Attributes: gid103376,public From: dennison@telepath.com Subject: Re: printf package/Function/Procedure in Ada ?? Date: 1999/03/10 Message-ID: <7c61o6$ops$1@nnrp1.dejanews.com>#1/1 X-Deja-AN: 453407842 References: <7c4e75$e5m@drn.newsguy.com> X-Http-User-Agent: Mozilla/4.5 [en] (WinNT; I) X-Http-Proxy: 1.0 x16.dejanews.com:80 (Squid/1.1.22) for client 204.48.27.130 Organization: Deja News - The Leader in Internet Discussion X-Article-Creation-Date: Wed Mar 10 15:05:50 1999 GMT Newsgroups: comp.lang.ada Date: 1999-03-10T00:00:00+00:00 List-Id: In article <7c4e75$e5m@drn.newsguy.com>, solo wrote: > > Hello, > > Any one knows where one can obtain a printf package/Function written all > in Ada? > (i.e. without Ada interfacing to the C printf() function to do its thing). > > This will be a package that will have a printf procedure that > exactly matches that of the C printf specs. printf() takes an indeterminate amount of arguments. You can't do that in Ada. However you can simulate it with a single argument that is an unconstrained array. Using that trick, along with some of the tricks and the facilities in gnat's Spitbol.* packages, I think it'd be doable. Probably not worth the effort, but doable. For those of you who haven't taken a look at it, I highly reccomend playing with the gnat Spitbol packages. There are some rather nifty coding tricks in there that I had never thought of before. I'm certainly the richer for having figgured out how to use it. T.E.D. -----------== Posted via Deja News, The Discussion Network ==---------- http://www.dejanews.com/ Search, Read, Discuss, or Start Your Own