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,38159b1b5557a2e7 X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2004-01-26 10:04:53 PST Path: archiver1.google.com!news2.google.com!newsfeed2.dallas1.level3.net!news.level3.com!crtntx1-snh1.gtei.net!news.gtei.net!newsfeed1.easynews.com!newsfeed2.easynews.com!easynews.com!easynews!newsfeed.news2me.com!wn11feed!worldnet.att.net!207.35.177.252!nf3.bellglobal.com!nf1.bellglobal.com!nf2.bellglobal.com!news20.bellglobal.com.POSTED!not-for-mail From: "Warren W. Gay VE3WWG" User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.4) Gecko/20030624 Netscape/7.1 (ax) X-Accept-Language: en-us, en MIME-Version: 1.0 Newsgroups: comp.lang.ada Subject: Re: Standard Ada Preprocessor (Was: why ada is so unpopular ?) References: <400BDB7C.40100@noplace.com> <400D2150.6000705@noplace.com> <400E72F9.8060501@noplace.com> <100upo7ln5e3k59@corp.supernews.com> <400FC8E8.2040100@noplace.com> <4011127C.4030801@noplace.com> <101377e54car5cc@corp.supernews.com> In-Reply-To: <101377e54car5cc@corp.supernews.com> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit Message-ID: Date: Mon, 26 Jan 2004 12:50:32 -0500 NNTP-Posting-Host: 198.96.223.163 X-Complaints-To: abuse@sympatico.ca X-Trace: news20.bellglobal.com 1075139380 198.96.223.163 (Mon, 26 Jan 2004 12:49:40 EST) NNTP-Posting-Date: Mon, 26 Jan 2004 12:49:40 EST Organization: Bell Sympatico Xref: archiver1.google.com comp.lang.ada:4826 Date: 2004-01-26T12:50:32-05:00 List-Id: Randy Brukardt wrote: > "Warren W. Gay VE3WWG" wrote in message > news:QEcQb.20015$cQ6.817492@news20.bellglobal.com... > >>Dmitry A. Kazakov wrote: >> >>>>I'd like to be able to hand off a collection of source code and say >>> >>>If we could limit variations to compilation units, I think we could, >>>then there might be a better way than preprocessing. >> >>As soon as you start splitting code into different parallel "files", >>you are denormalizing and decentralizing your code. This is >>maintenance hell. If you find a bug in one of these "portability" >>unique files, then you have to edit several files to effect the >>same fix. It also much more difficult to view the impact to >>other "platforms" for such a fix. > > I have to agree with Dmitry. This is a configuration management problem, and > an editor problem, not a language problem. There's no need to mess with the > language here. I would settle for a standard "precompiler tool", if one doesn't want to tinker with the language. For me, this matter is all moot anyway, because all that I am likely to use is gnatprep, lacking any other standard tool. However, having said that, there may be some advantages to integrating conditional compilation into the language. One of the problems that C/C++ has, is that you cannot do things like: #if sizeof(int) == 16 ... #else ... #endif This is just one example. Another might be to test the offset of a structure member, and add padding where necessary. The problem is that the preprocessor does not have the ability to evaluate size expressions. Ada projects may also have similar needs and more. Having a conditional compilation integrated into the language might provide some advanced portability features. Certainly integration like this would be an improvement in capability over other languages beginning with C ;-) And what I find amusing is that except for a few that appreciate this issue, we've heard of every ugly work-around possible, rather than face the issue square in the eye. This is just my opinion mind you, and perhaps small things amuse me ;-) It seems like a large number of people have this "Ada doesn't do it this way" attitude (otherwise known as "not invented here syndrome"). It kind of reminds me of the differences between Linux developers vs the *BSD ones. Both sides can learn from the other, but one side tends to look down on the other, and thus limits their thinking. (I won't say who ;-) As Ada stands now, it only serves the less portable embedded environment. If people truly do want to see wide-spread adoption of Ada, you will need to improve the portability to a level that competes well with C/C++. As for me, based upon what I have seen in this group, I'll just go on using gnatprep like I always have. The fact that ACT created this tool, and the fact that I and others use it, demonstrates a need that is not yet satisfied by the standard. -- Warren W. Gay VE3WWG http://ve3wwg.tk