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,c7ea1cb7a2beb2ee X-Google-Attributes: gid103376,public From: dale@cs.rmit.edu.au (Dale Stanbrough) Subject: Re: Disallowing Pre-Defined Operations Date: 2000/03/16 Message-ID: #1/1 X-Deja-AN: 598217363 References: <8a9eeg$qtv$1@newpoisson.nosc.mil> <8ababr$c3u$1@wanadoo.fr> <8aqc0e$n851@ftp.kvaerner.com> X-Trace: 16 Mar 2000 21:47:26 GMT, r1021c-29.ppp.cs.rmit.edu.au Organization: RMIT Newsgroups: comp.lang.ada Date: 2000-03-16T00:00:00+00:00 List-Id: Tucker Taft wrote in >I understand your goal, and it is reasonable. The usual question is >whether it is worth the cost. There are so many great ideas that >are possible, but only so many can be accommodated in a single >language. What you really want are a small number of very powerful >and flexible concepts that allow you to solve all the >interesting problems elegantly and safely. Personally, I would like a full-up >"units" capability, where generally A * A => A is not defined, since >that doesn't balance from a units point of view. I have some ideas >how to get there, and would be interested in opinions from others. >The techniques using discriminants are unsatisfactory in my view, >and too "heavy." VHDL has the notion of "units" built into the language, >and its approach should probably be evaluated. The C++ template model (for units) which was presented here some months back seemed to me to be pretty damm good. A series of templates which took mass, time and weight as parameters, and some typedefs for common instantiations did all of the work. No run time overhead, no space overhead as far as I could see. Looking at it, I don't think Ada could do as good. Dale