Merge Request:
Please review/accept this change. I have added support for using this from a library, as libraries do not have access to parameters. I have also added a "unit test". In this change, I also made the old call (DebugLog()) just a wrapper for the new call (DebugLog_Lib()) to make future changes easier.
Hmm, tough call on the deprecation.
Pros for deprecation:
I think DebugLog_Lib() works in all cases.
Can easily store the Log in retain.
Can easily have multiple logs.
Cons for deprecation:
but DebugLog() is easier to use if you just want to write a log (and you have control over the application Library Manager).
I would be happy to deprecate it though, in favour of the more universal DebugLog_Lib(). In which case.. we should rename the new function to DebugLog2(). Or, if you are happy to make a breaking change, simply replace it.
I have no attachment to the old implementation, so others may feel unkindly if we broke it for them.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Merge Request:
Please review/accept this change. I have added support for using this from a library, as libraries do not have access to parameters. I have also added a "unit test". In this change, I also made the old call (DebugLog()) just a wrapper for the new call (DebugLog_Lib()) to make future changes easier.
Great work! Will check and merge.
Are you saying that DebugLog() is backward compatible available but deprecated, so new development should use the DebugLog_Lib() function?
Last edit: aliazzz 2020-04-02
Hmm, tough call on the deprecation.
Pros for deprecation:
I think DebugLog_Lib() works in all cases.
Can easily store the Log in retain.
Can easily have multiple logs.
Cons for deprecation:
but DebugLog() is easier to use if you just want to write a log (and you have control over the application Library Manager).
I would be happy to deprecate it though, in favour of the more universal DebugLog_Lib(). In which case.. we should rename the new function to DebugLog2(). Or, if you are happy to make a breaking change, simply replace it.
I have no attachment to the old implementation, so others may feel unkindly if we broke it for them.