From: "Dan'l Miller" <optikos@verizon.net>
Subject: Re: Binding a C function wit FILE* object
Date: Sun, 27 Jul 2014 09:34:21 -0700 (PDT)
Date: 2014-07-27T09:34:21-07:00 [thread overview]
Message-ID: <e449cec0-a92c-4dc1-a8e7-baf68f3263d8@googlegroups.com> (raw)
In-Reply-To: <lr36qe$gib$1@speranza.aioe.org>
On Sunday, July 27, 2014 10:45:20 AM UTC-5, Victor Porton wrote:
> I am writing thick bindings for Raptor C library.
No, as multiple people keep implying or keep telling you overtly: you are writing a thin binding. If you are asking how to represent a pointer to FILE almost directly in Ada, then clearly you are writing a thin binding. Perhaps a thin binding is best for what you envision, but be clear in your thinking what you are and what you are not doing.
> What should I do regarding the following function?
> int raptor_uri_print (const raptor_uri *uri, FILE *stream);
> The trouble is that Ada probably has no interface with FILE* objects.
In a thick binding, Ada would have its own first-class-citizen representation roughly analogous to FILE (not pointer to FILE), such as a tagged record for byte-streams in general from which each format of file is derived into subclasses.
next prev parent reply other threads:[~2014-07-27 16:34 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-07-27 15:45 Binding a C function wit FILE* object Victor Porton
2014-07-27 16:34 ` Dan'l Miller [this message]
2014-07-27 16:51 ` Victor Porton
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox