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.9 required=5.0 tests=BAYES_00,FORGED_GMAIL_RCVD, FREEMAIL_FROM autolearn=no autolearn_force=no version=3.4.4 Path: eternal-september.org!reader01.eternal-september.org!reader02.eternal-september.org!.POSTED!not-for-mail From: =?UTF-8?Q?Bj=c3=b6rn_Lundin?= Newsgroups: comp.lang.ada Subject: Re: body stub not allowed in inner scope Date: Thu, 1 Mar 2018 10:11:04 +0100 Organization: A noiseless patient Spider Message-ID: References: <55cd79f5-4b37-4b08-b292-073ed2f37021@googlegroups.com> <15c49c4e-726a-4fd7-bf35-c7d27ff9a491@googlegroups.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Injection-Date: Thu, 1 Mar 2018 09:11:04 -0000 (UTC) Injection-Info: reader02.eternal-september.org; posting-host="b4829a74677c8c0434603a79b71c9f16"; logging-data="19476"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1/BEK0+iEOaSRtM/DGu1/iX" User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.8.0 In-Reply-To: Cancel-Lock: sha1:JeEFoJZzGDTlrSzrTsS+W5TFQR4= Xref: reader02.eternal-september.org comp.lang.ada:50742 Date: 2018-03-01T10:11:04+01:00 List-Id: On 2018-03-01 00:23, Randy Brukardt wrote: > "Mehdi Saada" <00120260a@gmail.com> wrote in message > news:15c49c4e-726a-4fd7-bf35-c7d27ff9a491@googlegroups.com... >> Thanks. >> But that's ugly... How about fixing this for the next norm ? > > Does anyone other than ACATS tests actually use stubs these days? If stub = separate then we do - a lot. >Why? Auto-generated code. We pass record structures back and forth to our c#-client over a socket. The records are defined in xml The (de)/serialization is generated by a tool as separate procedures, and the part of the server that receives a call from client uses a big if/elsif to find out what just arrived. It then calls the correct de-serialization procedure which is an auto-generated separate. (the tool also generates corresponding (de)/serialization for c#) -- -- Björn