Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

@frederick-vs-ja
Copy link
Contributor

@frederick-vs-ja frederick-vs-ja commented Jun 16, 2023

The deleted overloads prevent overload resolution flowing into another unintended overload when the invocation should be (SFINAE-friendlily) ill-formed.

Since the operator() overloads are constrained in default template arguments now, I think it would be better to use decltype(auto) to specify the return types.

There seems to be something wrong with modules when using traditional SFINAE, so I'm changing to use requires when possible.

Unblock one libc++ test:

  • std/utilities/function.objects/func.bind_front/bind_front.pass.cpp

The test seemly requires bind_front to be SFINAE-friendly, while the Standard uses "Mandates:"... As a result, I decided to copy some parts of that file into MSVC STL's test file.

Driven-by: _STD-qualify the internal calling helpers.

@frederick-vs-ja frederick-vs-ja requested a review from a team as a code owner June 16, 2023 17:19
@StephanTLavavej StephanTLavavej added the bug Something isn't working label Jun 16, 2023
@StephanTLavavej StephanTLavavej self-assigned this Jun 19, 2023
@StephanTLavavej
Copy link
Member

The test seemly requires bind_front to be SFINAE-friendly

My mother was an English teacher so I feel compelled to explain 😸 - "seemingly" is the word to use here (like "apparently"). "seemly" is a completely different word (and is rarely used; usually only the antonym "unseemly" is used). 📚

Copy link
Member

@StephanTLavavej StephanTLavavej left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks! I'll validate and push changes...

@StephanTLavavej
Copy link
Member

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

@StephanTLavavej StephanTLavavej merged commit df4dc31 into microsoft:main Jul 14, 2023
@StephanTLavavej
Copy link
Member

Thanks for improving this very tricky metaprogramming! 🛠️ ⚙️ 🎉

@frederick-vs-ja frederick-vs-ja deleted the bind-overloads branch July 14, 2023 02:33
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

None yet

Development

Successfully merging this pull request may close these issues.

3 participants