isocpp / isocpp/CppCoreGuidelines
Guideline against unconventional overloads
Nobody has claimed this yet.
- Dominant language
- CSS
- Stars
- 45.3k
- Forks
- 5.6k
- PR merge metrics
- No merged PRs in 30d
Description
Should there be a guideline recommending against overloading operators that people almost never anticipate to be overloaded? This would include things like:
- overloading the comma operator
- overloading logical AND and logical OR
There is fairly strong consensus in the community that doing so is questionable at best, and afaik standard libraries aren't all comma-safe either.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reviewing the existing operator-overloading guidance in the C++ Core Guidelines and the issue's examples of comma, logical AND, and logical OR overloads. Done means reaching agreement on whether a rule is warranted, its scope, and wording; the issue has no named file or test to run.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- cpp
- Domain
- documentation
- Issue type
- Documentation
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100