Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Deduce the return type of queue::emplace and stack::emplace #4980

Merged

Conversation

StephanTLavavej
Copy link
Member

Followup to #4963. Fixes VSO-2261359 / AB#2261359 "[VCPKG] rocksdb installation failed with error C2440":

stack(125): error C2440: 'return': cannot convert from 'void' to 'rocksdb::TransactionBaseImpl::SavePoint &'

As the container adaptors are required to use decltype(auto) in C++17, the "warning C5046: Symbol involving type with internal linkage not defined" in the convertible_to_any scenario and the ODR violation when mixing C++14 and C++17 TUs are unavoidable.

In <xmemory>, I'm lexicographically sorting _ADAPTOR_EMPLACE_RETURN before _CONTAINER_EMPLACE_RETURN, which will avoid an adjacent-add conflict with #4975 adding _LIST_REMOVE_RETURN (also in lex order).

@StephanTLavavej StephanTLavavej added the bug Something isn't working label Sep 24, 2024
@StephanTLavavej StephanTLavavej requested a review from a team as a code owner September 24, 2024 22:46
@CaseyCarter CaseyCarter removed their assignment Sep 24, 2024
@CaseyCarter
Copy link
Member

CaseyCarter commented Sep 24, 2024

Woops 😊. Thanks again, RWC!

@StephanTLavavej
Copy link
Member Author

I'm mirroring this to the MSVC-internal repo - please notify me if any further changes are pushed.

@StephanTLavavej StephanTLavavej merged commit d194fcd into microsoft:main Sep 28, 2024
39 checks passed
@StephanTLavavej StephanTLavavej deleted the oops-we-smashed-the-stack branch September 28, 2024 20:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

3 participants