comp.lang.ada
 help / color / mirror / Atom feed
From: nickroberts@ukf.net (Nick Roberts)
Subject: Re: object ada, visual c and tasking combined.
Date: Sat, 23 Feb 2002 13:36:04 GMT
Date: 2002-02-23T13:36:04+00:00	[thread overview]
Message-ID: <3c7780e1.308904750@news.cis.dfn.de> (raw)
In-Reply-To: 3C6CC24D.D013A4AC@chariot.net.au

On Fri, 15 Feb 2002 18:39:49 +1030, john donoghue <donoghue@chariot.net.au>
strongly typed:

>...
>... It seems to work ... next problem .... The visual c windowing stuff
>is in its own task, and there is also another C task that needs to wait
>on an ada function to return with data - but everytime I call the
>"pointered" functions from these tasks the app spits the dummy (
>terminates with a exception that provides no name or message or
>anything. )
>I am guessing that you cant call the ada functions from the other C
>tasks since they are in other tasks to the ada functions :) ... but is
>there a way around it?

What do you mean by "another C task"? Do you mean a Windows thread, or do
you mean a separate process (as in execXX etc.)? In either case (as best I
recall) Windows, since threads permit options regarding memory sharing (and
your Ada may take advantage of these options), I suspect the cross-'task'
calls fail because they cause code to try to access memory that it it is
not permitted to.

You may hate this suggestion, but my suggestion to you would be to
modularise your application at a different (higher) level, e.g. COM.

You could make your Ada 'engine' into a stand-alone program whch is a COM
server, and the VC front-end into a COM client. I am no expert on Windows
COM, but I think the stuff on AdaPower should give you most of what you
need to do it. I think in the end you'd find this to be a better solution.

Best of luck!
-- 
Nick Roberts



  parent reply	other threads:[~2002-02-23 13:36 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-02-15  8:09 object ada, visual c and tasking combined john donoghue
2002-02-15 18:06 ` Stephen Leake
2002-02-15 18:34   ` tmoran
2002-02-15 20:29     ` john donoghue
2002-02-16  4:14 ` Steve Doiel
2002-02-23 13:36 ` Nick Roberts [this message]
2002-02-25 12:05   ` john donoghue
2002-02-25 13:20     ` Frank J. Lhota
2002-02-25 20:10     ` Randy Brukardt
2002-02-27 20:53       ` john donoghue
replies disabled

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