Open RobLoach opened 2 years ago
When compiling with -Wall -Wextra, there are a few unused-parameter warnings. See the entire list of unused parameter warnings.
-Wall -Wextra
While we don't really need to fix these up, it would be nice...
I propose in wren_common.h...
// Allow specifying unused parameters of a function. #define WREN_UNUSED(x) (void)(x)
And then when there is an unused parameter, declare it.
// wren_opt_random.c WrenForeignClassMethods wrenRandomBindForeignClass(WrenVM* vm, const char* module, const char* className) { ASSERT(strcmp(className, "Random") == 0, "Should be in Random class."); WrenForeignClassMethods methods; methods.allocate = randomAllocate; methods.finalize = NULL; WREN_UNUSED(vm); return methods; }
To be more safe it should be:
#define WREN_UNUSED(x) ((void)(x))
Otherwise it is good for me.
When compiling with
-Wall -Wextra
, there are a few unused-parameter warnings. See the entire list of unused parameter warnings.While we don't really need to fix these up, it would be nice...
I propose in wren_common.h...
And then when there is an unused parameter, declare it.