Changes in / [310:a9e8f310507f:312:a4d499904482] in lemon-main
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
demo/arg_parser_demo.cc
r209 r311 28 28 29 29 using namespace lemon; 30 int main(int argc, c onst char **argv)30 int main(int argc, char **argv) 31 31 { 32 32 // Initialize the argument parser -
lemon/arg_parser.cc
r214 r311 27 27 } 28 28 29 ArgParser::ArgParser(int argc, const char * *argv) :_argc(argc), _argv(argv),30 29 ArgParser::ArgParser(int argc, const char * const *argv) 30 :_argc(argc), _argv(argv), _command_name(argv[0]) { 31 31 funcOption("-help","Print a short help message",_showHelp,this); 32 32 synonym("help","-help"); 33 33 synonym("h","-help"); 34 35 34 } 36 35 -
lemon/arg_parser.h
r290 r311 47 47 48 48 int _argc; 49 const char * *_argv;49 const char * const *_argv; 50 50 51 51 enum OptType { UNKNOWN=0, BOOL=1, STRING=2, DOUBLE=3, INTEGER=4, FUNC=5 }; … … 120 120 121 121 ///Constructor 122 ArgParser(int argc, const char * *argv);122 ArgParser(int argc, const char * const *argv); 123 123 124 124 ~ArgParser();
Note: See TracChangeset
for help on using the changeset viewer.