nob.h
nob.h copied to clipboard
[Suggestion] Make nob_needs_rebuild accept input paths as __VA_ARGS__
nob_needs_rebuild is not very convenient to use. I suggest this macro(copied from nob_cmd_append):
#define foo(output_path, ...) \
nob_needs_rebuild( \
output_path, ((const char *[]){__VA_ARGS__}), \
(sizeof((const char *[]){__VA_ARGS__}) / sizeof(const char *)))
if (foo("yyjson.o", "yyjson.c", "yyjson.h")) {
// ...
}
We cannot use the name nob_nees_rebuild and I have no idea how to name it.
I have no idea how to call it either. But if you come up with a good name feel free to submit a PR. :)