Boost logo

Boost Users :

From: Andreas Huber (ahd6974-spamgroupstrap_at_[hidden])
Date: 2006-08-14 15:41:37


Johan Nilsson wrote:
[snip]
> I'm very well aware of that, and can understand why you didn't
> provide a way for this from the beginning as it is generally unsafe.

Sorry, I figured that you already know that. I've developed a habit of
overexplaining things in public forums.

[snip]
> Thank you! It works perfectly.

I forgot to mention that this only works portably if you are compiling
with BOOST_STATECHART_USE_NATIVE_RTTI defined. It works always with GCC
as state_base has a virtual dtor to avoid compiler warnings. Here's the
habit again ;-)...

> The only (minor) annoyance is that I'll have to provide the
> unconsumed_event inside the class for testing purposes only, but that
> could be conditionally enabled using preprocessor directives.

Right, I've wondered before whether I should provide an appropriate
fifo_scheduler method for this but have so far rejected it because it
would mean to add something asynchronous_state_machine-specific to the
otherwise generic interface of fifo_scheduler. I'll think about this
some more, ideas welcome...

Regards,

-- 
Andreas Huber
When replying by private email, please remove the words spam and trap
from the address shown in the header. 

Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net