wil::com_ptr typedef is silently omitted if WI_ENABLE_EXCEPTIONS isn't defined
Nobody has claimed this yet.
- Dominant language
- C++
- Stars
- 3k
- Forks
- 300
- Avg merge
- 19h 12m
- Merged PRs (30d)
- 1
Description
If exceptions aren't enabled using wil::com_ptr results in an error that isn't immediately clear without digging through the source.
error C2039: 'com_ptr': is not a member of 'wil'
It should be pretty easy to add a struct that takes a compile time message and static_assert(false, message) if that class is instantiated to produce a clearer error message when using throwing types in binaries that don't support exceptions.
Contributor guide
No contributing guide indexed for this repository
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 tracing the wil::com_ptr definition and the WI_ENABLE_EXCEPTIONS conditional that omits it. Check the no-exceptions configuration and verify that using a throwing type produces a clear compile-time diagnostic instead of a missing-member error.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- cpp
- Domain
- operating-systems
- Issue type
- Bug
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100