Skip to content

Conversation

@oldnewthing
Copy link
Member

VS 2017 requires an accessible copy constructor even though it is never used. Turns out we're okay with enable_await_cancellation being copied, as long as it's not copied while awaiting (which we don't do). So go ahead and let it be copyable.

VS 2017 also reports an unused variable error when the use of the promise is removed via if constexpr. Mark it as [[maybe_unused]] to help the compiler.

VS 2017 requires accessible copy constructor even though it is never used.
Turns out we're okay with `enable_await_cancellation` being copied,
as long as it's not copied while awaiting (which we don't do).
So go ahead and let it be copyable.

VS 2017 also reports an unused variable error when the use of
the `promise` is removed via `if constexpr`. Mark it as
`[[maybe_unused]]` to help the compiler.
@oldnewthing oldnewthing requested a review from kennykerr October 2, 2020 18:57
Copy link
Collaborator

@kennykerr kennykerr left a comment

Choose a reason for hiding this comment

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

Thanks!

@kennykerr
Copy link
Collaborator

/azp run

@azure-pipelines
Copy link

No pipelines are associated with this pull request.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants