-
Notifications
You must be signed in to change notification settings - Fork 12.4k
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
Assertion failure when parsing invalid file #121980
Comments
@llvm/issue-subscribers-clang-frontend Author: Mikail Bagishov (MikailBag)
Code: https://gist.github.com/MikailBag/76a27cb9bc497cb608adf358bc890c86
Error:
Full error: server.iim:2:38: error: expected '='
PLEASE ATTACH THE FOLLOWING FILES TO THE BUG REPORT: </p> I am using clang which I've built myself (from clean source tree), but failure reproduces on Godbolt as well: https://godbolt.org/z/E5Ev993hK Context: I was trying to reduce reproducer #118137, but apparently ran into unrelated problem 😐 |
Looks like a clang-trunk regression: https://godbolt.org/z/cezMd94cc |
After 0dedd6f and 03229e7, invalid concept declarations might lack expressions for evaluation and normalization. This could make it crash in certain scenarios, apart from the one of evaluation concepts showed in 03229e7, there's also an issue when checking specializations where the normalization also relies on a non-null expression. This patch prevents that by avoiding building up a type constraint in such situations, thereafter the template parameter wouldn't have a concept specialization of a null expression. With this patch, the assumption in ASTWriterDecl is no longer valid. Namely, HasConstraint and TypeConstraintInitialized must now represent different meanings for both source fidelity and semantic requirements. Fixes #115004 Fixes #121980
Code: https://gist.github.com/MikailBag/76a27cb9bc497cb608adf358bc890c86
Error:
Full error:
Details
I am using clang which I've built myself (from clean source tree), but failure reproduces on Godbolt as well: https://godbolt.org/z/E5Ev993hK
Context: I was trying to reduce reproducer #118137, but apparently ran into unrelated problem 😐
The text was updated successfully, but these errors were encountered: