comp.lang.ada
 help / color / mirror / Atom feed
* C to Ada
@ 2006-11-23 22:12 Brian May
  2006-11-24  2:28 ` rodkay
  0 siblings, 1 reply; 14+ messages in thread
From: Brian May @ 2006-11-23 22:12 UTC (permalink / raw)


Hello,

Are there any up-to-date utilities for converting a C *.h file into a
Ada wrapper package?

I don't care if it requires cleaning up by hand afterwords.

Or is it considered better to write the entire wrapper by hand?

(considering a number of C libraries that I would like to be able to
access from Ada here but with no native Ada bindings yet).

Thanks.
-- 
Brian May <bam@snoopy.apana.org.au>



^ permalink raw reply	[flat|nested] 14+ messages in thread
* C to Ada
@ 2003-01-20 19:28 chris.danx
  0 siblings, 0 replies; 14+ messages in thread
From: chris.danx @ 2003-01-20 19:28 UTC (permalink / raw)


-- Apologise if this appears twice, these news servers are a pita!!!


Hi,

How do you map something like this to Ada (for a binding)?  It's 
probable that I'll only be working with GNAT on the Linux front (it's 
all there is), so a GNAT specific option although not ideal, is acceptable.


/* Open the shared object FILE and map it in; return a handle that can 
be passed to `dlsym' to get symbol values from it.  */

extern void *dlopen (__const char *__file, int __mode) __THROW;

I know rougly how to map the __file, and __mode params but am not sure 
how to deal with the void * or in this case the throw.  This is taken 
from dlfcn.h which is the header for dynamic library support in Linux. 
If anyone already has a (GMGPL) binding to this library and they'd like 
to share, please let me know, it'll save me making one.  In any event 
how do you translate this C code so it can be called from Ada?

After I get a wee thin binding working, I'm going to make it a little 
thicker and toss it into the open.


Cheers,
Chris
-- 
for personal replies change spamoff to chris




^ permalink raw reply	[flat|nested] 14+ messages in thread
* C to Ada
@ 1997-02-23  0:00 Cliff Lim
  1997-02-27  0:00 ` David Wheeler
  0 siblings, 1 reply; 14+ messages in thread
From: Cliff Lim @ 1997-02-23  0:00 UTC (permalink / raw)



Is there a trasnlator program from C to Ada?. If so, where can
I download it and how may I find such a program.





^ permalink raw reply	[flat|nested] 14+ messages in thread
* Re: Eiffel and Java + Ada dispatching
@ 1996-10-30  0:00 Jon S Anthony
  1996-11-04  0:00 ` Don Harrison
  0 siblings, 1 reply; 14+ messages in thread
From: Jon S Anthony @ 1996-10-30  0:00 UTC (permalink / raw)



In article <5563vp$1of@buggy.news.easynet.net> Sacha@easynet.fr (Vincent WEBER) writes:

> In article <E00t53.CG2@syd.csa.com.au>, donh@syd.csa.com.au says...
> 
> >
> >Don't mistake Ada's symmetrical syntax for multiple dispatching (binding
> >driven by more than one parameter). Ada is still single dispatched so for
> >dispatching operations, the symmetry is syntactic rather than semantic.  
> >
>
> Hum... I'm lost, two ada specialists saying two different things :)

Well, the problem is that Don is not an "ada specialist" and is in
error about there not being any semantics to this (or maybe just
simplifying to avoid the details).  There are indeed semantic aspects
as I point out in another note, but these do not imply multiple
dispatch.  So, that part is certainly correct.


> Let me cote an article from the french magazine "L'Objet" (Vol 1, no
> 1, Spring 95), by Antoine Bertier (Tomson Software Products) and
> Pascal Plisson (Alsys). I tried to translate from french to english,
> please apologize the mistakes if any :) "It is important to note
> than tags of all the parameters have to be identical at run-time to
> have the dispatching done to only one effective operation.
> Therefore there is no priviliged parameter for dispatching as it is
> the case in other languages. This is an important advantage of Ada
> 95 's model compared to other languages such as C++, that break the
> natural symetry of some operations in privileging the parameter used
> for the dispatching ( et need a way to reference this parameter :
> "this" in C++). For instance :

Yes, this is true and captures some (I suppose most) of the semantic
aspects.  But note that there is no conflict here with the assertion
that these are _not_ multi-dispatch.


> Well I think that one of the two parts is wrong :) any comment ?

Don's statement at face value is in error, but not on the salient part
of multiple-dispatch.


/Jon
-- 
Jon Anthony
Organon Motives, Inc.
Belmont, MA 02178
617.484.3383
jsa@organon.com





^ permalink raw reply	[flat|nested] 14+ messages in thread
* c to ada
@ 1995-04-07  0:00 JH Lee
  0 siblings, 0 replies; 14+ messages in thread
From: JH Lee @ 1995-04-07  0:00 UTC (permalink / raw)


do you known a list of ftp sites where i can find a translator c 
to ada. thank you.




^ permalink raw reply	[flat|nested] 14+ messages in thread

end of thread, other threads:[~2006-11-26 19:00 UTC | newest]

Thread overview: 14+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2006-11-23 22:12 C to Ada Brian May
2006-11-24  2:28 ` rodkay
2006-11-25 22:18   ` Brian May
2006-11-25 23:52     ` rodkay
2006-11-26 15:45       ` Robert A Duff
2006-11-26 18:12         ` Jeffrey Creem
2006-11-26 19:00         ` Martin Krischik
  -- strict thread matches above, loose matches on Subject: below --
2003-01-20 19:28 chris.danx
1997-02-23  0:00 Cliff Lim
1997-02-27  0:00 ` David Wheeler
1996-10-30  0:00 Eiffel and Java + Ada dispatching Jon S Anthony
1996-11-04  0:00 ` Don Harrison
1996-11-04  0:00   ` C to Ada Ali Mirhosseini
1996-11-04  0:00     ` Matthew Daniel
1996-11-04  0:00     ` Robert Dewar
1995-04-07  0:00 c to ada JH Lee

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox