3 ms·
Long function names are often self-documenting in terms of what they're supposed to do, even if not the how. What's more clear? find_windows_kit_root_with_key
by WesleyJohnson 5y ago
Long function names are often self-documenting in terms of what they're supposed to do, even if not the how. What's more clear?
find_windows_kit_root_with_key
find_kit
- shiryel 5y agoThe ideal solution is to use modules/classes and parameters names to contextualize, eg: Windows.find_kit_root(key) And is even better if your language supports pattern match on the parameters like elixir, so you can "overload" the function with many types of arguments, eg: Windows.find_kit_root(%User{key: key}) Windows.find_kit_root(%Admin{key: key}) Providing different behaviors to the same function name