pvnick / rf-ace

Automatically exported from code.google.com/p/rf-ace
0 stars 0 forks source link

ArgParse fails for select cases, due to dependency on GNU getopt_long #8

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
As documented in the source code, certain cases appear to cause ArgParse to 
fail after its rewrite to rely upon GNU C's getopt_long:

* When long arguments are specified in form "--longoption value" 
* When short arguments are packed together, such as "-abcd valueForD"

Wrapping this code in a standard try-catch fails since the code throws across 
linking barriers. Other attempts to catch the error are equally ineffectual.

Given the problems inherent to use of getopt_long as a drop-in rewrite of the 
previous iteration of ArgParse, while maintaining its inefficient time 
complexity, it's advised that this construct be rewritten to use a hashmap with 
a very limited, well-defined number of input cases. Such a framework is trivial 
once all of the supported input cases are defined.

Original issue reported on code.google.com by trobinso...@gtempaccount.com on 15 Aug 2011 at 10:20