comp.lang.ada
 help / color / mirror / Atom feed
From: Oliver Kowalke <oliver.kowalke@gmx.de>
Subject: Re: networking support?
Date: Sat, 20 Dec 2008 00:05:39 +0100
Date: 2008-12-20T00:05:39+01:00	[thread overview]
Message-ID: <gih97r$31h$1@online.de> (raw)
In-Reply-To: eb9a0c32-c108-41b6-8ae6-92165b882d4a@l33g2000pri.googlegroups.com

Maciej Sobczak wrote:

> On 18 Gru, 13:47, Georg Bauhaus <rm.dash-bauh...@futureapps.de> wrote:
> 
>> How would your program benefit from first wrapping system
>> functions (that use C conventions) in C++ classes only for
>> having to match Ada's O-O types and C++'s O-O types in
>> a second step?
>> Seems like an artificial setup to me.
> 
> Except that a lot of things in the C world (especially in the system
> APIs) are defined in header files as preprocessor constants, optional
> or even unofficial structure fields or field order within a struct -
> all this means that the binary layout of data structures is a big
> question mark. This problem is particularly notorious with network
> services.
> There is no way to reasonably interface with all this mess from Ada
> and having a wrapper layer that fixes some of this optional/unofficial/
> ordering stuff for the Ada part is a valid option.
> Now the question is how thick this adapter layer should be - and here
> a layer that does a bit of lifetime management or error reporting in
> addition to just parameter passing is also a valid solution.
> Then you might discover that all the work that is done in this
> adapting layer can be reused in C++ projects as well (it is a low-
> hanging fruit, so why not benefit from it?) and you end up with a
> regular C++ library that encapsulates some system services and is used
> from the Ada program.
> There is nothing artifical in it - it starts with a fundamental
> feasibility issues and ends up with simple economy.

my intention was to call some boost libraries (www.boost.org).
I'm not sure if C++-templates can be accessed/used by Ada.

regards,
Oliver




  reply	other threads:[~2008-12-19 23:05 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-12-17 18:33 networking support? Oliver Kowalke
2008-12-18  9:28 ` Georg Bauhaus
2008-12-18 11:55   ` Oliver Kowalke
2008-12-18 12:47     ` Georg Bauhaus
2008-12-19 21:49       ` Maciej Sobczak
2008-12-19 23:05         ` Oliver Kowalke [this message]
2008-12-20 19:23           ` Maciej Sobczak
2008-12-21 17:57             ` Oliver Kowalke
2008-12-21 22:21               ` Maciej Sobczak
2008-12-19 23:57         ` Georg Bauhaus
2008-12-18 18:09   ` Jeffrey R. Carter
2008-12-18 18:30     ` Georg Bauhaus
2008-12-18  9:54 ` Jacob Sparre Andersen
2008-12-18 16:14 ` anon
replies disabled

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