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=-2.9 required=5.0 tests=BAYES_00,MAILING_LIST_MULTI autolearn=unavailable autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,fe9ec916c5bbbd59 X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2001-12-14 18:25:04 PST Path: archiver1.google.com!news1.google.com!newsfeed.stanford.edu!news-spur1.maxwell.syr.edu!news.maxwell.syr.edu!btnet-peer1!btnet!isdnet!enst!enst.fr!not-for-mail From: "Alexandre E. Kopilovitch" Newsgroups: comp.lang.ada Subject: Re: Consider her way -- Re: Dimensionality Checking Date: Sat, 15 Dec 2001 05:24:53 +0300 (MSK) Organization: ENST, France Sender: comp.lang.ada-admin@ada.eu.org Message-ID: Reply-To: comp.lang.ada@ada.eu.org NNTP-Posting-Host: marvin.enst.fr Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: avanie.enst.fr 1008383103 29021 137.194.161.2 (15 Dec 2001 02:25:03 GMT) X-Complaints-To: usenet@enst.fr NNTP-Posting-Date: Sat, 15 Dec 2001 02:25:03 +0000 (UTC) To: comp.lang.ada@ada.eu.org Return-Path: X-Mailer: Mail/@ [v2.44 MSDOS] Errors-To: comp.lang.ada-admin@ada.eu.org X-BeenThere: comp.lang.ada@ada.eu.org X-Mailman-Version: 2.0.6 Precedence: bulk List-Help: List-Post: List-Subscribe: , List-Id: comp.lang.ada mail<->news gateway List-Unsubscribe: , Errors-To: comp.lang.ada-admin@ada.eu.org X-BeenThere: comp.lang.ada@ada.eu.org Xref: archiver1.google.com comp.lang.ada:17940 Date: 2001-12-15T05:24:53+03:00 "Mark Lundquist" wrote: >you have to hand-code all needed conversions for base >and derived units (vs. defining them for a handful of base units). Nor are >they reversible, i.e. for interoperability between m and km I would have to >write the conversion going each way rather than simply defining the >relationship between them. So you are going to introduce the explicit relationships between the types, and some reduction rules for the statements such as Variable := Expression; - right? Hmm, that will be a great job, substantial innovation, and will produce a visible impact on the whole Ada core language. The applications of that new feature surely will not be restricted to the unit conversions. >> > in this regard (unit abstraction for numeric types). >> By the way, I still don't see an abstraction here. How will you describe the >> notion of unit as an abstraction? For example "a type is the set of possible >> values and the set of operations" - and what is a unit? > >Well, what is a "value"? :-) No problem. Let us be slightly more formal: "a type is an ordered pair of the sets; the elements of the first set are called the values of this type; the elements of the second set are subroutines, and they are called the operations of this type". >The concept of >unit, like that of value, is not "definable" in the language, but that is >not necessary. You're getting all philosophical about it and making it >harder than it really is :-). But I certainly do see an abstraction in units... In such a case, perhaps you are able to describe - more or less formally - that abstraction, which you see here? Alexander Kopilovitch aek@vib.usr.pu.ru Saint-Petersburg Russia