From 2cbc634b3b603ec67c6c312bd18177cd52c71b63 Mon Sep 17 00:00:00 2001 From: Mike Buland Date: Fri, 18 Dec 2009 16:07:31 +0000 Subject: Ok...sweet, the OptParser now supports everything the old one did, but in much less code, and it does everything with more style and panache, also fewer bugs. --- src/tests/optparser.cpp | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'src/tests') diff --git a/src/tests/optparser.cpp b/src/tests/optparser.cpp index f5df7ed..5c91351 100644 --- a/src/tests/optparser.cpp +++ b/src/tests/optparser.cpp @@ -40,6 +40,8 @@ public: setOverride("str", "Bob!"); addHelpOption(); + + setNonOption( slot( this, &Opts::nonOption ) ); } int yesparam( StrArray aParams ) @@ -54,6 +56,12 @@ public: return 0; } + int nonOption( StrArray aParams ) + { + sio << " - nonOption" << aParams << sio.nl; + return aParams.getSize()-1; + } + int iBob; float dBob; Bu::FString sVar; -- cgit v1.2.3