You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Both examples contain conversion from enum to string. It is a code duplication and could be refactored into single function.
Also it is a good design to create pairs of functions to convert enum to string and string to enum.
The text was updated successfully, but these errors were encountered:
Looks like a duplication. I see this code above. It is better to create function which transforms enum to string and back.
Originally posted by @PokhodenkoSA in #93 (comment)
Example code:
dpctl/backends/source/dppl_sycl_device_interface.cpp
Line 62 in bb41bb6
dpctl/backends/source/dppl_sycl_platform_interface.cpp
Line 129 in 9fcbaa5
Both examples contain conversion from enum to string. It is a code duplication and could be refactored into single function.
Also it is a good design to create pairs of functions to convert enum to string and string to enum.
The text was updated successfully, but these errors were encountered: