From: gautier_niouzes@hotmail.com
Subject: Re: pragma/aspect Import, Convention parameters
Date: Fri, 14 Aug 2015 22:22:00 -0700 (PDT)
Date: 2015-08-14T22:22:00-07:00 [thread overview]
Message-ID: <2d5be9db-145c-4f96-ba94-18b73b82d532@googlegroups.com> (raw)
In-Reply-To: <14f6844a-0950-4157-80af-d6a962a56246@googlegroups.com>
Le vendredi 14 août 2015 01:42:30 UTC+2, David Botton a écrit :
> In GWindows I used expressions based on the Win32 API that one chose to support. Windows has a duplicate Ansi and UNICODE set of APIs. It worked out well.
It work*s*, and to the full satisfaction of its users :-) !
To be more concrete, GWindows spec. has this (the file gwindows.ads depends on whether ANSI or UNICODE is used):
Character_Mode_Identifier : constant String := "W";
and there are at hundreds of places in children packages:
procedure GetTextMetrics
(HDC : in GWindows.Types.Handle;
M : out Font_Metrics_W);
pragma Import (StdCall, GetTextMetrics,
"GetTextMetrics" & Character_Mode_Identifier);
So, having the convention as a string could be helpful if one needs to switch between C and StdCall as well.
_________________________
Gautier's Ada programming
http://gautiersblog.blogspot.com/search/label/Ada
NB: follow the above link for a valid e-mail address
next prev parent reply other threads:[~2015-08-15 5:22 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-08-13 8:27 pragma/aspect Import, Convention parameters Dmitry A. Kazakov
2015-08-13 10:24 ` G.B.
2015-08-13 11:52 ` Dmitry A. Kazakov
2015-08-13 20:32 ` Randy Brukardt
2015-08-14 7:23 ` Dmitry A. Kazakov
2015-08-14 20:30 ` Randy Brukardt
2015-08-15 1:15 ` Shark8
2015-08-17 21:40 ` Randy Brukardt
2015-08-17 21:47 ` Bob Duff
2015-08-20 16:00 ` Shark8
2015-08-13 23:42 ` David Botton
2015-08-15 5:22 ` gautier_niouzes [this message]
2015-08-17 21:54 ` Randy Brukardt
2015-08-20 16:07 ` Shark8
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox