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=ham autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,550291bc2bbf5019 X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2001-09-17 02:39:01 PST Path: archiver1.google.com!newsfeed.google.com!newsfeed.stanford.edu!news.tele.dk!small.news.tele.dk!212.74.64.35!colt.net!dispose.news.demon.net!news.demon.co.uk!demon!pipehawk.demon.co.uk!not-for-mail From: john.mccabe@emrad.com.nospam (John McCabe) Newsgroups: comp.lang.ada Subject: Re: Multiple task bodies for one task type? Date: Mon, 17 Sep 2001 09:37:51 GMT Organization: Emrad Ltd Message-ID: <3ba5c37f.6210990@news.demon.co.uk> References: <3BA2A012.1C2A2903@san.rr.com> NNTP-Posting-Host: pipehawk.demon.co.uk X-NNTP-Posting-Host: pipehawk.demon.co.uk:158.152.226.81 X-Trace: news.demon.co.uk 1000719502 nnrp-12:9021 NO-IDENT pipehawk.demon.co.uk:158.152.226.81 X-Complaints-To: abuse@demon.net X-Newsreader: Forte Free Agent 1.21/32.243 Xref: archiver1.google.com comp.lang.ada:13113 Date: 2001-09-17T09:37:51+00:00 List-Id: On Sat, 15 Sep 2001 00:26:01 GMT, Darren New wrote: If I understand yuo correctly, what you want is a heterogeneous array of tasks. If that is the case, I don't believe it is supported by Ada as the task type is not extendable. >But it looks like each task type gets exactly one task body. That is correct. >Of course, the primary problem is that things like "accept" and "abort" >and such have to actually be in the task body itself, not in subprograms >called from the task body, or I'd just make (say) a generic with a >procedure for each entry, or something. >Any hints how one would go about this? Thanks in advance! You may be able to implement someting like this using a discriminant on the task type. You would have to include all possible variations on the code within a case statement in the task. There may be other ways of course! Hope this helps.