comp.lang.ada
 help / color / mirror / Atom feed
* Buffer PO
@ 2016-06-03 13:29 tonyg
  2016-06-03 15:35 ` Anh Vo
                   ` (4 more replies)
  0 siblings, 5 replies; 6+ messages in thread
From: tonyg @ 2016-06-03 13:29 UTC (permalink / raw)



I have a Fifo buffer in a protect object with a push / pop procedures and an is_empty function storing a gaggle of variant records.

I push just fine but when I come to collect my data with a pop, I have to assign it to a variable which is predeclared.

I cannot use a function as this cannot change the inside of a protected object.

Now I could use an extra buffer to contain the variant record discriminator but is there a better way?

I did think of adding a function to peek at the discriminator, but this could cause a problem as a push may change the record being viewed before my pop.


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

end of thread, other threads:[~2016-06-04 11:49 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-06-03 13:29 Buffer PO tonyg
2016-06-03 15:35 ` Anh Vo
2016-06-03 16:20 ` Mark Lorenzen
2016-06-03 17:48 ` Jeffrey R. Carter
2016-06-03 19:10 ` Dmitry A. Kazakov
2016-06-04 11:49 ` tonyg

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