diff --git a/include/boost/spirit/home/support/common_terminals.hpp b/include/boost/spirit/home/support/common_terminals.hpp index ddb00e31b..6885c5923 100644 --- a/include/boost/spirit/home/support/common_terminals.hpp +++ b/include/boost/spirit/home/support/common_terminals.hpp @@ -73,7 +73,6 @@ namespace boost { namespace spirit ( right_align ) ( center ) ( maxwidth ) - ( confix ) ( set_state ) ( in_state ) ( token ) diff --git a/include/boost/spirit/home/support/terminal.hpp b/include/boost/spirit/home/support/terminal.hpp index 49a562bfb..fcf297362 100644 --- a/include/boost/spirit/home/support/terminal.hpp +++ b/include/boost/spirit/home/support/terminal.hpp @@ -280,6 +280,7 @@ namespace boost { namespace spirit type; }; + // FIXME: we need to change this to conform to the result_of protocol template < typename A0 , typename A1 = unused_type @@ -295,7 +296,6 @@ namespace boost { namespace spirit type; }; - // Note: in the following overloads, SFINAE cannot // be done on return type because of gcc bug #24915: // http://gcc.gnu.org/bugzilla/show_bug.cgi?id=24915 @@ -388,28 +388,41 @@ namespace boost { namespace spirit }; /////////////////////////////////////////////////////////////////////////// - namespace traits + namespace result_of { + template + struct terminal; + // Calculate the type of the compound terminal if generated by one of // the spirit::terminal::operator() overloads above - template < - typename Tag - , typename A0 = unused_type - , typename A1 = unused_type - , typename A2 = unused_type - > - struct terminal - { - typedef typename spirit::terminal:: - template result::type type; - }; // The terminal type itself is passed through without modification template - struct terminal + struct terminal { typedef spirit::terminal type; }; + + template + struct terminal + { + typedef typename spirit::terminal:: + template result::type type; + }; + + template + struct terminal + { + typedef typename spirit::terminal:: + template result::type type; + }; + + template + struct terminal + { + typedef typename spirit::terminal:: + template result::type type; + }; } }}