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 autolearn=unavailable autolearn_force=no version=3.4.4 Path: eternal-september.org!reader01.eternal-september.org!reader02.eternal-september.org!news.eternal-september.org!mx02.eternal-september.org!.POSTED!not-for-mail From: "Jeffrey R. Carter" Newsgroups: comp.lang.ada Subject: Re: I'm facing an issue with: call to abstract procedure must be dispatching Date: Tue, 8 Dec 2015 16:42:45 -0700 Organization: Also freenews.netfront.net; news.tornevall.net; news.eternal-september.org Message-ID: References: <8bc7fd76-f00a-4eea-9715-470af028fc84@googlegroups.com> <1krm4xun4e4ny.jmh9kvf6s0a9.dlg@40tude.net> <12dc7aea-933d-4271-95bd-10df808917e4@googlegroups.com> <5hfb2q9imjfu.zs3xp9gxw0d3.dlg@40tude.net> <5788b259-8886-4ee2-8c3d-7799abfd840e@googlegroups.com> <14acd8b0-a5e9-40fd-b7cc-d319f914d507@googlegroups.com> Mime-Version: 1.0 Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 7bit Injection-Date: Tue, 8 Dec 2015 23:40:19 -0000 (UTC) Injection-Info: mx02.eternal-september.org; posting-host="caa759af2a9c666aec02942f6fe5abd6"; logging-data="17721"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX19V9higTlBsjZjoUE8fZFHLhjg+eqKBe6E=" User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.3.0 In-Reply-To: Cancel-Lock: sha1:HtzZfgmrTtkvC9sc2sOdhLkC5kg= X-Enigmail-Draft-Status: N1110 Xref: news.eternal-september.org comp.lang.ada:28726 Date: 2015-12-08T16:42:45-07:00 List-Id: On 12/08/2015 04:04 PM, Serge Robyns wrote: > > How do I then pass the context? I mean, now I pass the parameter around. > through global variables? Also in the future I would like to have multiple > "tasks" running, each with their "context", especially the db session. I do > believe these are good reasons for having a variable. The case I was saying should be a pkg is when there's only 1. In that case, the state is in the pkg body. Why should the rest of the code need to pass anything around? For multiple tasks with independent states, then clearly something needs to be passed in. Whether that's the entire state or something that lets the pkg obtain the correct state is a design decision. -- Jeff Carter "Your mother was a hamster and your father smelt of elderberries." Monty Python & the Holy Grail 06