문제

int main() {
    std::string input("A90 (a-><>b)");
    std::string::iterator strbegin = input.begin();
    map<char, int> p;
    qi::phrase_parse(strbegin, input.end(),
    (qi::char_ >> qi::int_) % ':', // parser grammar
    qi::space, // delimiter grammar
    p); // attribute to fill while parsing
    return 0;
}

This code gives me error -

error: no matching function for call to ‘std::pair<char, int>::pair(const char&)’

and I am clueless on it.

도움이 되었습니까?

해결책

You need include "boost/fusion/include/std_pair.hpp"

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top