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,772ae8afc5db35f2 X-Google-Attributes: gid103376,public From: Samuel Mize Subject: Re: Can't export object of private type Date: 1999/03/03 Message-ID: <7bjihr$25t7@news1.newsguy.com>#1/1 X-Deja-AN: 450788818 References: Organization: ImagiNet Communications, Ltd. User-Agent: tin/pre-1.4-981002 ("Phobia") (UNIX) (AIX/3-2) Newsgroups: comp.lang.ada Date: 1999-03-03T00:00:00+00:00 List-Id: Don Harrison wrote: > Matt Heaney wrote: > :If you know up front how many "instances" of an abstraction you have > :--what I call the "well-known objects" pattern-- then a state machine > :package is probably the way to go. > > Partitioning objects into "well-known" and less-well-known :) will always > be somewhat arbitrary. Perhaps a clearer term would be "enumerable" if this kind of confusion is going to occur. It doesn't seem arbitrary to me that either you can list all the objects up front, by their nature, like the planets -- or not. >However, in the context of non-pure OOPLs (such as > Ada), you're probably right in suggesting it's worth distinguishing between > single-fixed-variant (your "well-known") objects and more general ones. > The additional flexibility gained in declaring an explicit derivable type > is a waste of time if future variants are unlikely. Is it not a waste of time in an OOPL, or is it not possible to avoid doing it in an OOPL? (That sounds confrontational and I apologize, but I can't think of a better way to phrase it.) > :In a typical Ada application, some abstractions are implemented as state > :machine packages, and some abstractions are implemented as instances of > :an abstract data type. There is nothing odd or unnatural about this. > > It's certainly idiomatic. Does you mean this to counter Matt's statement? If a language forces you to use just one or the other, you would, and that would be idiomatic too. I'm not sure what you're trying to get across. Best, Sam Mize -- Samuel Mize -- smize@imagin.net (home email) -- Team Ada Fight Spam: see http://www.cauce.org/ \\\ Smert Spamonam