Page MenuHomePhabricator

Remove qualtype qualifier in coroutine error to prevent assert in debug

Authored by tks2103 on Jul 9 2018, 1:50 PM.



A forward-declared coroutine_traits should trip an error; we need
a complete type.

Unfortunately, in debug mode only, we trip an assert when attempting
to provide the fully qualified type for the error message.
If you try to compile a program with a forward-declared
coroutine_traits in debug mode, clang will crash.

I've included a test for the behavior and removed the q modifier
on the error message. This prevents the crash in debug mode and
does not change the behavior for the error message on a
forward-declaration of a coroutine_traits type.

Test Plan:
I've included a test for the forward-declaration.

Diff Detail

rC Clang

Event Timeline

tks2103 created this revision.Jul 9 2018, 1:50 PM
modocache accepted this revision.Jul 10 2018, 6:18 AM

Excellent, thanks!

This revision is now accepted and ready to land.Jul 10 2018, 6:18 AM

If you don't have commit access, let me know here if you'd like me to commit this on your behalf.

@modocache please commit on my behalf please =)

This revision was automatically updated to reflect the committed changes.