[PATCH] Add helper function to convert enums to string