Just to be safe, I'm going to post this as AM.
I work with a set of Perl libraries that were designed to use Getopt::Long as the standard parameter-passing mechanism. (Oddly, only with single letter variants.)
Among the many things that sucks about this are:
- You cannot pass nested structures, callbacks, references. Objects. Filehandles. Anything but a string. You might not want that now, but trust me, having a OO framework where methods can't take references is suck.
- All strings are copied many times... normally into an "-i$num" string before passing, then on to the stack, then into @ARGV, then into getopt, then into a destination variable. When passing large buffers into methods, this is suck.
- All numeric arguments are cast to opt-prefixed strings, then back to numbers. This is especially suck if you happen to like retaining floating point accuracy.
At one point I had a longer list. It just made me sad, though. Don't do it. Your code maintainers will loath you.