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=ham autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,625ff2b9397b148c,start X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2004-04-07 11:13:45 PST Path: archiver1.google.com!news2.google.com!fu-berlin.de!uni-berlin.de!142.red-80-25-0.pooles.rima-tde.NET!not-for-mail From: Helio Newsgroups: comp.lang.ada Subject: Concurrency in Ada in a Linux and Solaris Date: Wed, 07 Apr 2004 19:47:29 +0200 Message-ID: NNTP-Posting-Host: 142.red-80-25-0.pooles.rima-tde.net (80.25.0.142) Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-15 Content-Transfer-Encoding: 8bit X-Trace: news.uni-berlin.de 1081361624 89119727 I 80.25.0.142 ([165255]) User-Agent: Pan/0.14.2.91 (As She Crawled Across the Table (Debian GNU/Linux)) Xref: archiver1.google.com comp.lang.ada:6816 Date: 2004-04-07T19:47:29+02:00 List-Id: Hi, The code bellow compiled and executed in a Linux system [1] doesn't write nothing at output. However, the same code compiled and executed in a Solaris system [2] run right [3]. Any idea? [1] Linux, debian testing, gnat 3.15p-7, gcc 3.3 [2] Solaris 5.7, gnat 3.11, gcc 2.95 [3] ./principal RsiTimer Interrupcion?PetekanInterrupcion?... -- code -- with ada.text_IO; procedure principal is task printer is entry put(s: in string); entry put_line(s: in string); end printer; task body printer is begin loop select accept put(s: in string) do Ada.Text_IO.Put(s); end put; or accept put_line(s: in string) do Ada.Text_IO.Put_Line(s); end put_line; end select; end loop; end printer; task rsi is entry interrupcion; end rsi; task body rsi is begin printer.put("Rsi"); loop select accept interrupcion do printer.Put("Petekan"); end interrupcion; or delay 1.0; printer.Put("FalloRSI"); end select; end loop; end rsi; task timer; task body timer is begin printer.Put_Line("Timer"); loop printer.Put("Interrupcion?"); select rsi.interrupcion; or delay 0.5; printer.Put_Line("Rsi no trata interrupcion"); end select; end loop; end timer; begin Null; end principal;