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.1 required=5.0 tests=BAYES_05,INVALID_MSGID autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,ee5fe10168979a38 X-Google-Attributes: gid103376,public From: "Marin D. Condic" Subject: Re: Question regarding package Date: 2000/03/27 Message-ID: <38DF957B.75C1A90F@quadruscorp.com>#1/1 X-Deja-AN: 602953907 Content-Transfer-Encoding: 7bit References: <%JDD4.10$p52.1521@news.pacbell.net> Organization: Quadrus Corporation X-Sender: "Marin D. Condic" (Unverified) X-Server-Date: 27 Mar 2000 14:09:12 GMT Content-Type: text/plain; charset=us-ascii Mime-Version: 1.0 Newsgroups: comp.lang.ada Date: 2000-03-27T14:09:12+00:00 List-Id: joe Tsai wrote: > for example if I wrote generic package call Gen_List. I can use it with the > following ways, > > package Stuff is newGen_List(Integer); > use Stuff; > > the question is that if I can assign a package as type? > > type thing is > ..... > Your question is not 100% clear - maybe you should explain a little more about what you want to accomplish & we can help point the way. In general, the answer to your question is "no". A package is a conglomeration of types, objects, subprograms and tasks. Making it generic does not really change this. A type is a definition of how to interpret raw memory. (O.K. not *strictly* accurate, but good enough for this purpose.) How could a type contain actual memory for objects? Declaring new objects of that type starts getting you into a paradox of sorts. You might think of a generic package instantiation as a kind of object declaration. The generic package is similar to a type and the instance is similar to an object - a specific occurence of the general definition. If you had something else in mind, post more detail and I'm sure someone will be glad to point out that I don't know what I'm talking about. :-) MDC -- ============================================================= Marin David Condic - Quadrus Corporation - 1.800.555.3393 1015-116 Atlantic Boulevard, Atlantic Beach, FL 32233 http://www.quadruscorp.com/ m c o n d i c @ q u a d r u s c o r p . c o m ***PLEASE REMOVE THE "-NOSPAM" PART OF MY RETURN ADDRESS*** Visit my web site at: http://www.mcondic.com/ "Because that's where they keep the money." -- Willie Sutton when asked why he robbed banks. =============================================================