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.9 required=5.0 tests=BAYES_00,FREEMAIL_FROM autolearn=unavailable autolearn_force=no version=3.4.4 X-Received: by 2002:a24:7996:: with SMTP id z144-v6mr987382itc.10.1542056536582; Mon, 12 Nov 2018 13:02:16 -0800 (PST) X-Received: by 2002:a9d:fed:: with SMTP id m42mr56265otd.6.1542056536325; Mon, 12 Nov 2018 13:02:16 -0800 (PST) Path: eternal-september.org!reader01.eternal-september.org!reader02.eternal-september.org!feeder.eternal-september.org!news.gegeweb.eu!gegeweb.org!usenet-fr.net!proxad.net!feeder1-2.proxad.net!209.85.166.216.MISMATCH!g188-v6no556532itg.0!news-out.google.com!n199-v6ni881itn.0!nntp.google.com!g188-v6no556528itg.0!postnews.google.com!glegroupsg2000goo.googlegroups.com!not-for-mail Newsgroups: comp.lang.ada Date: Mon, 12 Nov 2018 13:02:15 -0800 (PST) In-Reply-To: Complaints-To: groups-abuse@google.com Injection-Info: glegroupsg2000goo.googlegroups.com; posting-host=2a02:c7d:3c35:b000:325a:3aff:fe0f:37a5; posting-account=L2-UcQkAAAAfd_BqbeNHs3XeM0jTXloS NNTP-Posting-Host: 2a02:c7d:3c35:b000:325a:3aff:fe0f:37a5 References: <59fabb8a-45b4-429d-822b-58878a208df0@googlegroups.com> User-Agent: G2/1.0 MIME-Version: 1.0 Message-ID: Subject: Re: Aliased Unchecked_Unions not seen or taken notice of From: Lucretia Injection-Date: Mon, 12 Nov 2018 21:02:16 +0000 Content-Type: text/plain; charset="UTF-8" Xref: reader02.eternal-september.org comp.lang.ada:54820 Date: 2018-11-12T13:02:15-08:00 List-Id: On Monday, 12 November 2018 20:13:53 UTC, Dmitry A. Kazakov wrote: > On 2018-11-12 19:29, Lucretia wrote: > > On Monday, 12 November 2018 17:56:05 UTC, Lucretia wrote: > > > >> type Results (Success : Boolean) is > >> record > >> case Success is > >> when False => > >> Error : Errors_Ptr; > >> > >> when True => > >> Output : Values_Ptr; > >> end case; > >> end record with > >> Convention => C_Pass_By_Copy; > > > > This compiles fine. So it seems impossible to use unchecked_union and access types together. > > What about C_Pass_By_Copy? That looks much inconsistent with access to me. I did try removing that too. > BTW, why do you want to use unchecked union? In comparable cases I > rather simply overload imported functions with whatever arguments: Because it's not that simple.