[all-commits] [llvm/llvm-project] abf4a8: [Clang] Improve diagnostics when using a concept a...
cor3ntin via All-commits
all-commits at lists.llvm.org
Thu Mar 30 07:30:38 PDT 2023
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: abf4a8cb15d4faf04ee0da14e37d7349d3bde9a1
https://github.com/llvm/llvm-project/commit/abf4a8cb15d4faf04ee0da14e37d7349d3bde9a1
Author: Corentin Jabot <corentinjabot at gmail.com>
Date: 2023-03-30 (Thu, 30 Mar 2023)
Changed paths:
M clang/docs/ReleaseNotes.rst
M clang/lib/Parse/ParseDecl.cpp
M clang/lib/Parse/Parser.cpp
A clang/test/Parser/cxx-template-template-recovery.cpp
Log Message:
-----------
[Clang] Improve diagnostics when using a concept as template argument
When using the name of a template variable or concept in places
where an expression was expected, Clang would drop the cxxscope token
preceeding it, if any.
This leads to subpar diagnostics - complaining about the
identifier being undeclared as clang would not know to look into a
non-global scope.
We make sure the scope is preserved.
When encountering `ns::Concept foo x;`, Clang would also fail
to provide the same quality as it does at global scope.
Reviewed By: aaron.ballman, erichkeane
Differential Revision: https://reviews.llvm.org/D146719
More information about the All-commits
mailing list