From: Dmitry A. Kazakov on
On Thu, 7 Jan 2010 14:11:37 -0800 (PST), Vadim Godunko wrote:

> On Jan 7, 1:59�pm, "Dmitry A. Kazakov" <mail...(a)dmitry-kazakov.de>
> wrote:
>> On Thu, 07 Jan 2010 08:19:17 +0100, Per Sandberg wrote:
>>> The core reason is that the Binary Interface specific the name-mangling
>>> in C++ is different between gcc and MSVC, on top of that the
>>> documentation in the MSVC case is "sparse".
>>
>> That should not be a problem in case of C. One should only make a choice
>> between stdcall and cdecl convention when you make a call from Ada. I guess
>> Qt has plain C interface? Then what happens inside of it is no matter.
>>
> Qt is pure C++ library, there is no C interface provided by it.

Well, the question is whether the interface uses virtual functions and
classes you have to derive from. That would make a real difference.

> QtAda's code includes both C/C++ and Ada code which refers to each
> others in both directions, so it is unpractical to separate it into
> two independent shared libraries to build C/C++ part using MSVC and
> Ada part using GNAT; but mixing of MSVC and GNAT object files in the
> same shared library is not supported now.

I agree. It is the Visual Studio's debugger, which makes MSVC attractive.
Since that won't work with GNAT, there seems to be no reason left to port
Qt into MSVC.

--
Regards,
Dmitry A. Kazakov
http://www.dmitry-kazakov.de
From: Vadim Godunko on
On Jan 8, 1:32 am, Hibou57 (Yannick Duchêne)
<yannick_duch...(a)yahoo.fr> wrote:
>
> While I do not know about the technical details, I use to read from
> place to place, GNAT provides a custom support for interfacing Ada and
> C++ library, as well as ObjectAda does, if I'm not wrong.
>
GNAT C++ interface feature is expected to be used only with C++ code
compiled by G++. Don't known about ObjectAda, may be it can interface
with MSVC.

> Honestly, I do not like so called “ portable ” UIs (personal feeling
> with reasons), but although I do not really enjoy it, it seems to me
> GTK is easier to use than Qt (and more lightweight in most of case).
>
Because I am one of authors of QtAda, I let others to compare GtkAda
and QtAda. :-)
From: Vadim Godunko on
On Jan 8, 2:02 am, "Dmitry A. Kazakov" <mail...(a)dmitry-kazakov.de>
wrote:
> On Thu, 7 Jan 2010 14:11:37 -0800 (PST), Vadim Godunko wrote:
> > On Jan 7, 1:59 pm, "Dmitry A. Kazakov" <mail...(a)dmitry-kazakov.de>
> > wrote:
> >> On Thu, 07 Jan 2010 08:19:17 +0100, Per Sandberg wrote:
> >>> The core reason is that the Binary Interface specific the name-mangling
> >>> in C++ is different between gcc and MSVC, on top of that the
> >>> documentation in the MSVC case is "sparse".
>
> >> That should not be a problem in case of C. One should only make a choice
> >> between stdcall and cdecl convention when you make a call from Ada. I guess
> >> Qt has plain C interface? Then what happens inside of it is no matter.
>
> > Qt is pure C++ library, there is no C interface provided by it.
>
> Well, the question is whether the interface uses virtual functions and
> classes you have to derive from. That would make a real difference.
>
Both are expected to be used actively. The most complicated area of
QtAda design was providing a useful (for the end programmer) way to
interfacing with virtual functions and handling association between
the same object at Ada and C++ side.
From: Dmitry A. Kazakov on
On Thu, 7 Jan 2010 23:10:25 -0800 (PST), Vadim Godunko wrote:

> On Jan 8, 1:32�am, Hibou57 (Yannick Duch�ne)
> <yannick_duch...(a)yahoo.fr> wrote:
>>
>> While I do not know about the technical details, I use to read from
>> place to place, GNAT provides a custom support for interfacing Ada and
>> C++ library, as well as ObjectAda does, if I'm not wrong.
>>
> GNAT C++ interface feature is expected to be used only with C++ code
> compiled by G++. Don't known about ObjectAda, may be it can interface
> with MSVC.

You can even debug programs compiled by ObjectAda (7.2) in Visual Studio,
to a certain extent. However, I cannot tell if ObjectAda C++ interfacing
works, I never tried that.

To be honest, it is a big mistake to make a library with only C++
interface, because that exposes not only the constants, subprograms and
their profiles defined in terms of simple types, but it also does virtual
tables and internal layouts of the classes. That is too much coupling from
the software design point of view. (The same would apply to Ada's tagged
types, unfortunately.)

--
Regards,
Dmitry A. Kazakov
http://www.dmitry-kazakov.de
First  |  Prev  | 
Pages: 1 2 3
Prev: Best Beauty Tips online
Next: What is a student?