In case this code is still up for debate or as a recommendation for the future:
Try to avoid repeating string literals in your code base. Consider enum class types instead or, if string literals are also printed, think of having const char * constants that you can use. Both ways the compiler can detect typos or similar mistakes which it can't in you current approach.
In case this code is still up for debate or as a recommendation for the future: Try to avoid repeating string literals in your code base. Consider
enum class
types instead or, if string literals are also printed, think of havingconst char *
constants that you can use. Both ways the compiler can detect typos or similar mistakes which it can't in you current approach._Originally posted by @HannesSommer in https://github.com/ethz-asl/time_stamper/pull/5#discussion_r867669598_