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,cc7bad83fb245cb3 X-Google-Attributes: gid103376,public From: "Matthew Heaney" Subject: Re: Binding a type to a union. Date: 1999/11/23 Message-ID: <383ae9f8_3@news1.prserv.net>#1/1 X-Deja-AN: 552173163 Content-transfer-encoding: 7bit References: Content-Type: text/plain; charset="US-ASCII" X-Complaints-To: abuse@prserv.net X-Trace: 23 Nov 1999 19:24:40 GMT, 129.37.62.252 Organization: Global Network Services - Remote Access Mail & News Services Mime-version: 1.0 Newsgroups: comp.lang.ada Date: 1999-11-23T00:00:00+00:00 List-Id: In article , Tom_Hargraves@Raytheon.com wrote: > However, wouldn't its use be restricted to when the type was to be used in a > 'C' language interface call? Why else would you need an union type? If you don't need a union, then just use a discriminated (variant) record. > The pragma comes with a long list of restrictions which perhaps, generally, > would be undesirable. The restrictions are there to simplify the semantics of a union, which is not a native Ada type. (pragma Unchecked_Union is GNAT-specific.) -- Help keep evolution in the science classroom and religion out: become a member of the National Center for Science Education.