in reply to Re^2: Are sub/method synonyms acceptable coding practice?
in thread Are sub/method synonyms acceptable coding practice?
While this isn't strictly on the original topic, it's not strictly off-topic, either. Perhaps this mental confusion is because neither one is a perfect name. In a case where you can't come up with a perfect name, aliases may be warranted, but in cases where a better name exists, perhaps just moving the code to the new name would be better. In this case, I'd suggest "isInGods" as a potential alternative. This all does stem from the fact that a member of the group gods is a "god" - so the flag and the groupname don't match. The same problem does not exist for pmdev (if the group were named "pmdevs" it would), but does for others, such as holders of unholy power or breathers of fire. The "isIn*" idiom would hold for all of the groups, whether they changed name or not.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^4: Are sub/method synonyms acceptable coding practice?
by rcseege (Pilgrim) on Nov 19, 2005 at 17:23 UTC |