|
Boost Users : |
From: Zoltan \'cad\' Juhasz (cad_at_[hidden])
Date: 2007-03-12 12:15:27
Andreas Huber <ahd6974-spamboostorgtrap <at> yahoo.com> writes:
> The following version of transition.hpp *might* fix the problem:
>
http://boost.cvs.sourceforge.net/*checkout*/boost/boost/boost/statechart/transit
ion.hpp?revision=1.15
>
> I coudn't verify this on GCC4.1 but at least it compiles on MSVC7.1 and
> GCC3.4. Could you please replace your local version of transition.hpp
> with the above one and report back whether that fixes your problem?
The previous problem ( http://usalug.org/pastebin/pastebin.php?show=392 ) is
solved with gcc (GCC) 4.1.0 20060304 (Red Hat 4.1.0-3), but with gcc32 (GCC)
3.2.3 20030502 (Red Hat Linux 3.2.3-55.fc5) the following problem arise:
g++32 -g -I /boost_1_33_1/ -std=c++98 -pedantic main.cpp -o car_assembler
In file included from main.cpp:17:
/boost_1_33_1/boost/statechart/transition.hpp:48: no class template named `
no_context' in `boost::statechart::detail'
main.cpp:38: object `<expression error>' cannot be used as template argument
main.cpp:38: warning: ISO C++ forbids declaration of `reactions' with no type
make: *** [debug32] Error 1
There is another problem. The full code can be found here:
http://usalug.org/pastebin/pastebin.php?show=411
If you define some post_event, the following error occures with gcc (GCC)
4.1.0 20060304 (Red Hat 4.1.0-3):
g++ -g -I /boost_1_33_1/ -std=c++98 -pedantic main.cpp -o car_assembler
main.cpp: In constructor 'default_state<T>::default_state(typename
boost::statechart::state<default_state<T>, sample_machine<T>,
boost::mpl::list<mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na,
mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na,
mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na>,
has_no_history>::my_context)':
main.cpp:51: error: there are no arguments to 'post_event' that depend on a
template parameter, so a declaration of 'post_event' must be available
main.cpp:51: error: (if you use '-fpermissive', G++ will accept your code, but
allowing the use of an undeclared name is deprecated)
make: *** [debug] Error 1
With gcc32 (GCC) 3.2.3 20030502 (Red Hat Linux 3.2.3-55.fc5):
g++32 -g -I /boost_1_33_1/ -std=c++98 -pedantic main.cpp -o car_assembler
In file included from main.cpp:19:
/boost_1_33_1/boost/statechart/transition.hpp:48: no class template named `
no_context' in `boost::statechart::detail'
main.cpp:44: object `<expression error>' cannot be used as template argument
main.cpp:44: warning: ISO C++ forbids declaration of `type name' with no type
make: *** [debug32] Error 1
Best Regards,
-- Zoltan 'cad' Juhasz http://people.inf.elte.hu/cad/
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