c++ - Why can't I use the << operator with the value extracted from this variables_map? -


i'm familiarizing myself boost::program_options (and c++ in general). wrote function below, can't quite understand error i'm getting. here's code (note po alias boost::program_options).

int application(po::variables_map& vm) {     std::cout << &vm << std::endl;     std::cout << vm["infile"];      return success; } 

the error i'm receiving second line in function body. reads: "no match ‘operator<<’ (operand types ‘std::ostream {aka std::basic_ostream<char>}’ , ‘const boost::program_options::variable_value’)"

what doing wrong?


Comments

Popular posts from this blog

SPSS keyboard combination alters encoding -

Add new record to the table by click on the button in Microsoft Access -

CSS3 Transition to highlight new elements created in JQuery -