I think this would be a little more convenient to use if it generated a header file with just DocoptArgs and docopt(). The use case for this would be a program that deals with parsed arguments in many places.
If the parsed arguments (DocoptArgs) are needed in different files that are eventually linked together, we can't just do #include "docopt.c" like in the main file, since we would be redefining various variables and functions. We would instead have to redefine just the struct in each file that the parsed arguments are needed.
I think this would be a little more convenient to use if it generated a header file with just
DocoptArgsanddocopt(). The use case for this would be a program that deals with parsed arguments in many places.If the parsed arguments (
DocoptArgs) are needed in different files that are eventually linked together, we can't just do#include "docopt.c"like in the main file, since we would be redefining various variables and functions. We would instead have to redefine just the struct in each file that the parsed arguments are needed.