Ticket #5591: main.cpp
| File main.cpp, 460 bytes (added by , 11 years ago) |
|---|
| Line | |
|---|---|
| 1 | #include <boost/spirit/include/qi.hpp> |
| 2 | |
| 3 | int main() |
| 4 | { |
| 5 | using namespace boost::spirit::qi; |
| 6 | |
| 7 | typedef std::string::iterator iter; |
| 8 | |
| 9 | rule<iter, int()> a; |
| 10 | rule<iter, int()> a_cp; |
| 11 | a_cp = a; //compiles |
| 12 | a_cp = a.copy(); //compiles |
| 13 | a_cp = a.alias(); //compiles |
| 14 | |
| 15 | rule<iter, int(int)> b; |
| 16 | rule<iter, int(int)> b_cp; |
| 17 | b_cp = b; //compiles |
| 18 | b_cp = b.copy(); //fails to compile |
| 19 | b_cp = b.alias(); //fails to compile |
| 20 | } |
