Boost logo

Boost Users :

Subject: [Boost-users] problem with boost::program_options
From: Hasanul Ferdaus (sunny_register_at_[hidden])
Date: 2009-06-25 09:41:38


Hi,
I am trying to parse unregistered options using  boost::program_options for config files but it does not recognize the unregistered options. the code is like to the following -
--------------------------------
boost::program_options::options_description *optionsDescription;
boost::program_options::variables_map *variablesMap;
optionsDescription->add_options()
        ("ariba.bootstrap.hints", "Bootstrap Hints");

std::ifstream ifs(configFileName.c_str());
store(parse_config_file(ifs, *optionsDescription, true), *variablesMap);
notify(*variablesMap);
----------------------------------

As it says, passing true to the 3rd argument of parse_config_file() should allow unregistered options to be parsed, but it does not recognize any unregistered options in config file.
If anyone knows how to enable unregistered options in config file, please respond.
Thanks in advance.
Sunny



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