here's a macro to move to the next argument (kjs mentioned in an
earlier thread that this isn't a descriptive name)
/* na(c) [Next Argument (Char pointer)]
*
* Moves the pointer to the next argument in the user input.
*/
#define na(c) { \
while (*c && !isspace((int) *c)) \
c++; \
while (*c && isspace((int) *c)) \
c++; }
50 lines later, here's a function by a totally different name, which
does exactly the same thing:
/*
=item C<static const char* skip_command(const char* str)>
Returns the pointer past the current debugger command. (This is an
alternative to the C<na()> macro above.)
=cut
*/
static const char*
skip_command(const char* str)
{
while (*str && !isspace((int) *str))
str++;
while (*str && isspace((int) *str))
str++;
return str;
}
why, oh why? i suggest we drop the macro, but i'm willing to hear
arguments, because there may be a benefit i don't see.
~jerry