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=-0.7 required=5.0 tests=BAYES_00,INVALID_DATE, PLING_QUERY autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,329032975b221f1 X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 1994-10-05 14:59:58 PST Path: bga.com!news.sprintlink.net!howland.reston.ans.net!europa.eng.gtefsd.com!MathWorks.Com!zombie.ncsc.mil!gmi!msuinfo!harbinger.cc.monash.edu.au!bunyip.cc.uq.oz.au!brisbane.celsius.oz.au!dawe From: dawe@celsius.oz.au (Daniel Wengelin) Newsgroups: comp.lang.ada Subject: Re: Q: common types?! Date: 5 Oct 1994 04:40:45 GMT Organization: CelsiusTech Australia Distribution: world Message-ID: <36taod$3o5@brisbane.celsius.oz.au> References: <36c1c0$lve@pong.lasc.lockheed.com> NNTP-Posting-Host: localhost.celsius.oz.au X-Newsreader: TIN [version 1.2 PL0] Date: 1994-10-05T04:40:45+00:00 List-Id: Tony Leavitt (tony@deepthought.Sgi.COM) wrote: : I have a question for all you Ada wizards. I do not have a lot of experience : with Ada (only about 3000 lines), and I have begun to start making a common : types package. This package would define all kinds of types for feet, nautical : miles, degrees, radians, etc, ad nuasium, for all different kinds and sizes : of float and integers. Am I about to go insane by trying this? Or, does : this exist already on the Internet somewhere? If I was to attempt to do this : how would you recommend about doing it? Stuff deleted.... : Tony Leavitt Hi, yes I'd think you'll go nuts trying to handle all the type conversions necessary. Here's what I think you should do: Define new basic types, such as integer and float, to facilitate portability. Define you maths stuff (according to the appropriate standard or annexe) on your new basic float. Define your physical units as subtypes, not for type checking, but for better naming. subtype Volt ... Go out and obtain packages for the complex types, such as geodetic positions. They are pretty tricky to implement if you want a full set of functions. Just my 2cents... -------------------------------------------------------------------- -- Daniel Wengelin -- Team Ada, what a nice idea.... -- -- CelsiusTech -- -- -- dawe@celsiustech.se -- -- -- -- -- -------------------------------------------------------------------- with Standard_Disclaimer; --------------------------------------------------------------------