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.6 required=5.0 tests=BAYES_00,TO_NO_BRKTS_FROM_MSSP autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,94bac711cf2950f X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2001-10-26 07:02:39 PST Path: archiver1.google.com!news1.google.com!newsfeed.stanford.edu!news-spur1.maxwell.syr.edu!news.maxwell.syr.edu!out.nntp.be!propagator-SanJose!in.nntp.be!newsranger.com!www.newsranger.com!not-for-mail Newsgroups: comp.lang.ada From: Ted Dennison References: <3BD87B95.2000703@maciejsobczak.com> Subject: Re: Newbie wanna Ada Message-ID: X-Abuse-Info: When contacting newsranger.com regarding abuse please X-Abuse-Info: forward the entire news article including headers or X-Abuse-Info: else we will not be able to process your request X-Complaints-To: abuse@newsranger.com NNTP-Posting-Date: Fri, 26 Oct 2001 10:02:00 EDT Organization: http://www.newsranger.com Date: Fri, 26 Oct 2001 14:02:00 GMT Xref: archiver1.google.com comp.lang.ada:15242 Date: 2001-10-26T14:02:00+00:00 List-Id: In article <3BD87B95.2000703@maciejsobczak.com>, Maciej Sobczak says... >2. Is there some more or less standard GUI lib? I've spot a Tcl/Tk >binding somewhere: Probably the best Ada GUI lib for a Linux user would be GtkAda (http://libre.act-europe.fr/GtkAda/). >3. What is the level of portability of the source code? C++ suffers from >the fact that many vendors dare to dump crap on the market with the C++ >logo on the boxes. The result is that we have many different 'dialects' >of this (standardised) language. What about Ada? If I write something >for GNAT, can I assume that some imaginary Windows compiler will eat it? The Ada culture is very different from the C++ culture there. Ada compilers that don't properly implement the standard are just *not* accepted by the user community, and thus there aren't many of them. Any compiler vendor can tell you that it is quite common to get angry messages (and demands for bug fixes) from users when they percieve that some section of the Ada Language Reference Manual has been violated. In my experience any actual non-compliance found *is* treated as a bug by the vendors. However, there are some areas (clearly defined in the standard) where vendors have some lattitude. Many of the "Annexes" in the standard are optional. In fact, I believe there's still one that is only supported by Gnat. Also, vendors are free to add their own pragmas. If a compiler encounters a pragma it doesn't understand, it will ignore it, so this isn't disasterous, but it can make your code non-portable if you aren't careful. In general, the places where things are implmentation-defined are clearly called out in the spec, and it isn't difficult to write code that is completely portable between compilers and platforms. My company has a multi-threaded real-time scheduler that compiles and runs without change on Win32 and vxWorks. >4. What is the possibility of interfacing Ada with C (mainly - using C >libs from Ada)? Is this made during the linking or in the spirit of Quite easily done. There is a secion in the LRM all about it. See section B.3 and all subsections ( http://www.ada-auth.org/~acats/arm-html/RM-B-3.html ). The pragmas used are shown in B proper. >Native Interfaces (like in Java)? For extremists - is it possible to >call back some Ada procedure from the C function (possibly running in >another thread)? Yup. I had to do both once when we had an existing C routine to call that allocated memory, but we needed it to use Ada's allocators so that the memory would be visible to other Ada tasks (this was on a Harris NightHawk, where tasks were implemented as processes and all "globals" and dynamic allocation came from shared memory). We just implmented our own C-interfaced allocation routine in Ada and exported it as "malloc". Worked like a charm. >5. Is there a CORBA binding implemented for Ada? Unfortunately I'm stuck in a Windows ghetto, so I don't know about that. But I do know that there is a really good COM binding. From what I remember of CORBA, an Ada binding wouldn't be difficult to do yourself in a pinch, but someone probably has one already. --- T.E.D. homepage - http://www.telepath.com/dennison/Ted/TED.html No trees were killed in the sending of this message. However a large number of electrons were terribly inconvenienced.