User Activity

  • Created ticket #22 on Templatized C++ Command Line Parser

    Make return value of TCLAP::ValueArg<T>::getValue const

  • Posted a comment on discussion Open Discussion on Templatized C++ Command Line Parser

    A simple example would be any application expecting a filename. If a user accedentically had a '-' at the start of a filename argument, then they were probably attempting to use a flag instead. While an application can easily catch this, having the command line parser directly catch it is cleaner and results in a more sensible error/usage message. For instance, the error mesage when doing a 'ls -dummy' is: ls: option requires an argument -- 'y' Try 'ls --help' for more information. instead of something...

  • Modified a comment on discussion Open Discussion on Templatized C++ Command Line Parser

    The UnlabeledValueArg arg type currently matches against arguments starting with a '-'. Could either a new class or an optional parameter be added to indicate an argument should not be allowed to start with an '-'? For instance, namespace TCLAP{ template<typename T> class UnlabeledStringValueArg : public UnlabeledValueArg<T>{ public: using UnlabeledValueArg<T>::UnlabeledValueArg; virtual bool processArg(int* i, std::vector<std::string>& args){ if(args[*i][0] == '-') return(false); return(UnlabeledValueArg<T>::processArg(i,...

  • Posted a comment on discussion Open Discussion on Templatized C++ Command Line Parser

    The UnlabeledValueArg arg type currently matches against parameters starting with a '-'. Could either a new class or an optional parameter be added to inidcate an argument should not be allowed to start with an '-'? For instance, namespace TCLAP{ template<typename T> class UnlabeledStringValueArg : public UnlabeledValueArg<T>{ public: using UnlabeledValueArg<T>::UnlabeledValueArg; virtual bool processArg(int* i, std::vector<std::string>& args){ if(args[*i][0] == '-') return(false); return(UnlabeledValueArg<T>::processArg(i,...

View All

Personal Data

Username:
sandytf
Joined:
2019-05-31 21:38:29

Projects

  • No projects to display.

Personal Tools