comp.lang.ada
 help / color / mirror / Atom feed
From: Simon Wright <simon@pushface.org>
Subject: Re: ADA and Open GL
Date: Wed, 10 Aug 2011 12:09:52 +0100
Date: 2011-08-10T12:09:52+01:00	[thread overview]
Message-ID: <m2liv134lb.fsf@pushface.org> (raw)
In-Reply-To: 4e424822$0$2559$703f8584@news.kpn.nl

"ldries46" <bertus.dries@planet.nl> writes:

> My program seems correct now, but I get the following error message:
>
> opengl-glu.ads:373:31: warning: subprogram pointer
> "gluNurbsCallback.CallBackFunc" should have foreign convention
> opengl-glu.ads:373:31: warning: add Convention pragma to declaration
> of "GLU.GLUFUNCPTR" at line 231
>
> This is found in a standard unit nl. the adabindings to Open GL, GLU
> and GLUT
>
> Can I disregard this warning or should I do something to avoid it. I
> don't thoink I should be altering my copy of the ADA bindings so
> where should I do something.
> In my program I don't call this routine directly soit is a result of a
> call from another routine within the ADA bindings.

Perhaps you're compiling with a different set of compiler options than
those used by the developer of the bindings?

Very often, GNAT will in fact translate iffy code like this correctly
(the compiler backend understands C, of course). Better not to risk it,
though, convention errors can be a real pain to debug.

Those bindings aren't "standard" in the RM sense. Personally I'd make
the change and send a patch to the bindings maintainer.



  reply	other threads:[~2011-08-10 11:09 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-08-09 14:31 ADA and Open GL ldries46
2011-08-09 14:48 ` Georg Bauhaus
2011-08-09 14:51 ` Simon Wright
2011-08-10  8:58 ` ldries46
2011-08-10 11:09   ` Simon Wright [this message]
2011-08-10 13:23     ` ldries46
2011-08-10 15:35       ` Simon Wright
  -- strict thread matches above, loose matches on Subject: below --
2011-08-10 14:24 ldries46
replies disabled

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