In my code I call the startup macro a few times for a few different reasons. I have two questions about this:
First, is there some limit of calls to the startup macro? Or can it be called as many times as necessary? E.g. which of the following is better:
STARTUP(System.enableFeature(FEATURE_RETAINED_MEMORY));
STARTUP(System.enableFeature(FEATURE_RESET_INFO));
OR
void startupMacro() {
System.enableFeature(FEATURE_RETAINED_MEMORY);
System.enableFeature(FEATURE_RESET_INFO);
}
STARTUP(startupMacro());
Second, are there any issues with calling the same startup function multiple times? E.g. if I use a library that calls a startup function, like STARTUP(System.enableFeature(FEATURE_RETAINED_MEMORY)); and then I call that same startup function again elsewhere, are any issues created?
Both of the above seem to be ok, but want to get an authoritative answer on this.
