comp.lang.ada
 help / color / mirror / Atom feed
From: Maciej Sobczak <see.my.homepage@gmail.com>
Subject: Re: System calls - GNAT library vs. direct bindings
Date: Fri, 01 Jun 2007 13:45:25 -0700
Date: 2007-06-01T13:45:25-07:00	[thread overview]
Message-ID: <1180730725.902452.161820@m36g2000hse.googlegroups.com> (raw)
In-Reply-To: <gUY7i.143046$_c5.113755@attbi_s22>

On 1 Cze, 19:42, "Jeffrey R. Carter"
<spam.jrcarter....@acm.nospam.org> wrote:

> It's usually better to reuse something that has been widely used than to
> recreate the wheel. Reuse is generally less effort than creating a new
> library.

That's right.

> Portability is generally a good thing, even if you don't think you need
> it.

Please note that I was talking about targetting POSIX systems.
That *is* thinking about portability!

> To my mind, given the existence of a library that is portable across
> compilers and platforms, such a library should be used.

Yes. The point is - GNAT library is not compiler-agnostic.

> In the absence
> of such a library, but given the existence of an existing library such
> as GNAT's, I'd probably choose the existing library,

Yes, but...

> but would add a
> wrapper around it

Bingo. And calling system API directly also requires a wrapper - at
least for convenience. Interestingly, for funcions as simple as read/
write/listen/etc., both wrappers will have comparable complexity.
Note that no matter how the wrapper is written, it isolates two
parties and as such can be later used to achieve freedom from both
compiler and system.

So we are really comparing writing two wrappers. Same effort with same
effect.

--
Maciej Sobczak
http://www.msobczak.com/




  parent reply	other threads:[~2007-06-01 20:45 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-05-31 14:58 System calls - GNAT library vs. direct bindings Maciej Sobczak
2007-05-31 15:06 ` Ludovic Brenta
2007-05-31 15:23   ` Maciej Sobczak
2007-05-31 16:14     ` Ludovic Brenta
2007-05-31 19:08       ` Michael Bode
2007-05-31 19:48         ` Markus E Leypold
2007-05-31 20:07 ` Simon Wright
2007-05-31 21:10   ` Georg Bauhaus
2007-06-01 19:50     ` Simon Wright
2007-06-01  6:27   ` Maciej Sobczak
2007-06-01 19:29     ` Simon Wright
2007-06-01  6:59 ` anon
2007-06-01 10:17   ` Markus E Leypold
2007-06-01 13:01   ` Maciej Sobczak
2007-06-01 20:13   ` Pascal Obry
2007-06-01 20:35     ` Pascal Obry
2007-06-01 17:42 ` Jeffrey R. Carter
2007-06-01 19:32   ` Simon Wright
2007-06-01 20:45   ` Maciej Sobczak [this message]
2007-06-02  5:35     ` Jeffrey R. Carter
replies disabled

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