comp.lang.ada
 help / color / mirror / Atom feed
* Newbie question: Implementing a callback mechanism with Ada 83
@ 2007-02-10 19:38 benibilme
  2007-02-10 20:40 ` Dmitry A. Kazakov
  2007-02-11  2:46 ` Jeffrey R. Carter
  0 siblings, 2 replies; 6+ messages in thread
From: benibilme @ 2007-02-10 19:38 UTC (permalink / raw)


Hello,

I need to develop an Ada application which must conform to Ada83. It
will be part of legacy system. I am very much new in Ada. The
application I have to develop is very much event driven. As an old
time C programmer I wanted to implement an event handling module which
you can subscribe callback functions and trigger the events when
necessary and unfortunately I have realized that Ada 83 does not
support pointer to subprograms. I have read about generics with which
defining subprograms as parameters of subprograms seems possible. On
the other hand, I could not figure out how to do it.

I simply want to store function pointers to some data structure for
some certain events and call them with dynamic data when the event is
triggered.

How can I do it in Ada 83 without the support of pointers to
subprograms. It is clear how to do this Ada95 as there is a direct
support for pointer to subprograms.

Any help is much appreciated.




^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2007-02-12 19:32 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2007-02-10 19:38 Newbie question: Implementing a callback mechanism with Ada 83 benibilme
2007-02-10 20:40 ` Dmitry A. Kazakov
2007-02-11  2:46 ` Jeffrey R. Carter
2007-02-11 21:40   ` benibilme
2007-02-12  5:03     ` Jeffrey R. Carter
2007-02-12 19:32     ` Adam Beneschan

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