<filesystem>: filesystem_error's copy functions are not noexcept
Nobody has claimed this yet.
- Dominant language
- C++
- Stars
- 11.1k
- Forks
- 1.7k
- Avg merge
- 4d 15h
- Merged PRs (30d)
- 22
Description
The standard draft says that copy functions of every standard exception class are noexcept in [exception]/2. The wording has been changed since N4659 but the change is treated editorial.
Currently MS STL's filesystem_error directly holds two paths and one string as its subobject, which makes its defaulted (implicitly declared) copy functions non-noexcept.
libc++ and libstdc++ use a shared_ptr or its equivalent alternative to hold these objects, and thus the copy functions can be noexcept.
vNext note: Resolving this issue will require breaking binary compatibility. We won't be able to accept pull requests for this issue until the vNext branch is available. See #169 for more information.
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 with stl/inc/filesystem around the filesystem_error definition and review the referenced libc++ and libstdc++ implementations for comparison. Read #169 and the vNext note before proceeding, since the issue says pull requests must wait for that branch. Done means filesystem_error copy functions meet the noexcept requirement without ignoring the stated binary-compatibility constraint.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- cpp
- Domain
- operating-systems
- Issue type
- Bug
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 25/100