Revision tags: llvmorg-18.1.8, llvmorg-18.1.7, llvmorg-18.1.6, llvmorg-18.1.5, llvmorg-18.1.4, llvmorg-18.1.3, llvmorg-18.1.2, llvmorg-18.1.1, llvmorg-18.1.0, llvmorg-18.1.0-rc4, llvmorg-18.1.0-rc3, llvmorg-18.1.0-rc2, llvmorg-18.1.0-rc1, llvmorg-19-init, llvmorg-17.0.6, llvmorg-17.0.5, llvmorg-17.0.4, llvmorg-17.0.3, llvmorg-17.0.2, llvmorg-17.0.1, llvmorg-17.0.0, llvmorg-17.0.0-rc4, llvmorg-17.0.0-rc3, llvmorg-17.0.0-rc2, llvmorg-17.0.0-rc1, llvmorg-18-init, llvmorg-16.0.6, llvmorg-16.0.5, llvmorg-16.0.4, llvmorg-16.0.3, llvmorg-16.0.2, llvmorg-16.0.1, llvmorg-16.0.0, llvmorg-16.0.0-rc4, llvmorg-16.0.0-rc3, llvmorg-16.0.0-rc2, llvmorg-16.0.0-rc1, llvmorg-17-init, llvmorg-15.0.7, llvmorg-15.0.6, llvmorg-15.0.5, llvmorg-15.0.4, llvmorg-15.0.3, working, llvmorg-15.0.2 |
|
#
326feaaf |
| 25-Sep-2022 |
Matheus Izvekov <mizvekov@gmail.com> |
[clang] Implement sugared substitution changes to infrastructure
Implements the changes required to perform substitution with non-canonical template arguments, and to 'finalize' them by not placing
[clang] Implement sugared substitution changes to infrastructure
Implements the changes required to perform substitution with non-canonical template arguments, and to 'finalize' them by not placing 'Subst' nodes.
A finalized substitution means we won't resugar them later, because these templates themselves were eagerly substituted with the intended arguments at the point of use. We may still resugar other templates used within those, though.
This patch does not actually implement any uses of this functionality, those will be added in subsequent patches, so expect no changes to existing tests.
Signed-off-by: Matheus Izvekov <mizvekov@gmail.com>
Differential Revision: https://reviews.llvm.org/D134604
show more ...
|
#
8383c2a4 |
| 26-Oct-2022 |
Matheus Izvekov <mizvekov@gmail.com> |
Revert "[clang] Implement sugared substitution changes to infrastructure"
This reverts commit c4c2a3c65684e062efcd101a957c6cae0a304a7a.
|
#
c4c2a3c6 |
| 25-Sep-2022 |
Matheus Izvekov <mizvekov@gmail.com> |
[clang] Implement sugared substitution changes to infrastructure
Implements the changes required to perform substitution with non-canonical template arguments, and to 'finalize' them by not placing
[clang] Implement sugared substitution changes to infrastructure
Implements the changes required to perform substitution with non-canonical template arguments, and to 'finalize' them by not placing 'Subst' nodes.
A finalized substitution means we won't resugar them later, because these templates themselves were eagerly substituted with the intended arguments at the point of use. We may still resugar other templates used within those, though.
This patch does not actually implement any uses of this functionality, those will be added in subsequent patches, so expect no changes to existing tests.
Signed-off-by: Matheus Izvekov <mizvekov@gmail.com>
Differential Revision: https://reviews.llvm.org/D134604
show more ...
|
Revision tags: llvmorg-15.0.1, llvmorg-15.0.0, llvmorg-15.0.0-rc3, llvmorg-15.0.0-rc2, llvmorg-15.0.0-rc1, llvmorg-16-init, llvmorg-14.0.6, llvmorg-14.0.5, llvmorg-14.0.4, llvmorg-14.0.3, llvmorg-14.0.2, llvmorg-14.0.1, llvmorg-14.0.0, llvmorg-14.0.0-rc4, llvmorg-14.0.0-rc3, llvmorg-14.0.0-rc2, llvmorg-14.0.0-rc1, llvmorg-15-init, llvmorg-13.0.1, llvmorg-13.0.1-rc3, llvmorg-13.0.1-rc2, llvmorg-13.0.1-rc1, llvmorg-13.0.0, llvmorg-13.0.0-rc4, llvmorg-13.0.0-rc3, llvmorg-13.0.0-rc2, llvmorg-13.0.0-rc1, llvmorg-14-init, llvmorg-12.0.1, llvmorg-12.0.1-rc4, llvmorg-12.0.1-rc3, llvmorg-12.0.1-rc2, llvmorg-12.0.1-rc1, llvmorg-12.0.0, llvmorg-12.0.0-rc5, llvmorg-12.0.0-rc4, llvmorg-12.0.0-rc3, llvmorg-12.0.0-rc2, llvmorg-11.1.0, llvmorg-11.1.0-rc3, llvmorg-12.0.0-rc1, llvmorg-13-init, llvmorg-11.1.0-rc2, llvmorg-11.1.0-rc1, llvmorg-11.0.1, llvmorg-11.0.1-rc2, llvmorg-11.0.1-rc1, llvmorg-11.0.0, llvmorg-11.0.0-rc6, llvmorg-11.0.0-rc5, llvmorg-11.0.0-rc4, llvmorg-11.0.0-rc3, llvmorg-11.0.0-rc2, llvmorg-11.0.0-rc1, llvmorg-12-init, llvmorg-10.0.1, llvmorg-10.0.1-rc4, llvmorg-10.0.1-rc3, llvmorg-10.0.1-rc2, llvmorg-10.0.1-rc1 |
|
#
499b2a8d |
| 28-Mar-2020 |
Richard Smith <richard@metafoo.co.uk> |
PR45294: Fix handling of assumed template names looked up in the lexical scope.
There are a few contexts in which we assume a name is a template name; if such a context is one where we should perfor
PR45294: Fix handling of assumed template names looked up in the lexical scope.
There are a few contexts in which we assume a name is a template name; if such a context is one where we should perform an unqualified lookup, and lookup finds nothing, we would form a dependent template name even if the name is not dependent. This happens in particular for the lookup of a pseudo-destructor.
In passing, rename ActOnDependentTemplateName to just ActOnTemplateName given that we apply it for non-dependent template names too.
show more ...
|
#
88c7ffaf |
| 28-Mar-2020 |
Richard Smith <richard@metafoo.co.uk> |
Form invalid template-id annotations when parsing a construct that is required to be a template-id but names an undeclared identifier.
|
Revision tags: llvmorg-10.0.0, llvmorg-10.0.0-rc6, llvmorg-10.0.0-rc5, llvmorg-10.0.0-rc4, llvmorg-10.0.0-rc3, llvmorg-10.0.0-rc2, llvmorg-10.0.0-rc1, llvmorg-11-init, llvmorg-9.0.1, llvmorg-9.0.1-rc3, llvmorg-9.0.1-rc2, llvmorg-9.0.1-rc1, llvmorg-9.0.0, llvmorg-9.0.0-rc6, llvmorg-9.0.0-rc5, llvmorg-9.0.0-rc4, llvmorg-9.0.0-rc3, llvmorg-9.0.0-rc2, llvmorg-9.0.0-rc1, llvmorg-10-init, llvmorg-8.0.1, llvmorg-8.0.1-rc4, llvmorg-8.0.1-rc3, llvmorg-8.0.1-rc2, llvmorg-8.0.1-rc1, llvmorg-8.0.0, llvmorg-8.0.0-rc5, llvmorg-8.0.0-rc4, llvmorg-8.0.0-rc3, llvmorg-7.1.0, llvmorg-7.1.0-rc1, llvmorg-8.0.0-rc2, llvmorg-8.0.0-rc1, llvmorg-7.0.1, llvmorg-7.0.1-rc3, llvmorg-7.0.1-rc2, llvmorg-7.0.1-rc1, llvmorg-7.0.0, llvmorg-7.0.0-rc3, llvmorg-7.0.0-rc2, llvmorg-7.0.0-rc1, llvmorg-6.0.1, llvmorg-6.0.1-rc3, llvmorg-6.0.1-rc2 |
|
#
7981004e |
| 11-May-2018 |
Richard Smith <richard-llvm@metafoo.co.uk> |
Improve diagnostics and error recovery for template name lookup.
For 'x::template y', consistently give a "no member named 'y' in 'x'" diagnostic if there is no such member, and give a 'template key
Improve diagnostics and error recovery for template name lookup.
For 'x::template y', consistently give a "no member named 'y' in 'x'" diagnostic if there is no such member, and give a 'template keyword not followed by a template' name error if there is such a member but it's not a template. In the latter case, add a note pointing at the non-template.
Don't suggest inserting a 'template' keyword in 'X::Y<' if X is dependent if the lookup of X::Y was actually not a dependent lookup and found only non-templates.
llvm-svn: 332076
show more ...
|
Revision tags: llvmorg-6.0.1-rc1, llvmorg-5.0.2, llvmorg-5.0.2-rc2, llvmorg-5.0.2-rc1, llvmorg-6.0.0, llvmorg-6.0.0-rc3, llvmorg-6.0.0-rc2, llvmorg-6.0.0-rc1, llvmorg-5.0.1, llvmorg-5.0.1-rc3, llvmorg-5.0.1-rc2, llvmorg-5.0.1-rc1, llvmorg-5.0.0, llvmorg-5.0.0-rc5, llvmorg-5.0.0-rc4, llvmorg-5.0.0-rc3, llvmorg-5.0.0-rc2, llvmorg-5.0.0-rc1, llvmorg-4.0.1, llvmorg-4.0.1-rc3, llvmorg-4.0.1-rc2, llvmorg-4.0.1-rc1, llvmorg-4.0.0, llvmorg-4.0.0-rc4, llvmorg-4.0.0-rc3, llvmorg-4.0.0-rc2, llvmorg-4.0.0-rc1, llvmorg-3.9.1, llvmorg-3.9.1-rc3, llvmorg-3.9.1-rc2, llvmorg-3.9.1-rc1, llvmorg-3.9.0, llvmorg-3.9.0-rc3, llvmorg-3.9.0-rc2, llvmorg-3.9.0-rc1, llvmorg-3.8.1, llvmorg-3.8.1-rc1, llvmorg-3.8.0, llvmorg-3.8.0-rc3, llvmorg-3.8.0-rc2, llvmorg-3.8.0-rc1 |
|
#
85dec559 |
| 10-Dec-2015 |
Charles Li <charles_li@playstation.sony.com> |
[Lit Test] Updated 20 Lit tests to be C++11 compatible.
This is the 5th Lit test patch. Expanded expected diagnostics to vary by C++ dialect. Expanded RUN line to: default, C++98/03 and C++11.
llvm
[Lit Test] Updated 20 Lit tests to be C++11 compatible.
This is the 5th Lit test patch. Expanded expected diagnostics to vary by C++ dialect. Expanded RUN line to: default, C++98/03 and C++11.
llvm-svn: 255196
show more ...
|
Revision tags: llvmorg-3.7.1, llvmorg-3.7.1-rc2, llvmorg-3.7.1-rc1, llvmorg-3.7.0, llvmorg-3.7.0-rc4, llvmorg-3.7.0-rc3, studio-1.4, llvmorg-3.7.0-rc2, llvmorg-3.7.0-rc1, llvmorg-3.6.2, llvmorg-3.6.2-rc1, llvmorg-3.6.1, llvmorg-3.6.1-rc1, llvmorg-3.5.2, llvmorg-3.5.2-rc1, llvmorg-3.6.0, llvmorg-3.6.0-rc4, llvmorg-3.6.0-rc3, llvmorg-3.6.0-rc2, llvmorg-3.6.0-rc1, llvmorg-3.5.1, llvmorg-3.5.1-rc2, llvmorg-3.5.1-rc1, llvmorg-3.5.0, llvmorg-3.5.0-rc4, llvmorg-3.5.0-rc3, llvmorg-3.5.0-rc2, llvmorg-3.5.0-rc1, llvmorg-3.4.2, llvmorg-3.4.2-rc1, llvmorg-3.4.1, llvmorg-3.4.1-rc2, llvmorg-3.4.1-rc1, llvmorg-3.4.0, llvmorg-3.4.0-rc3, llvmorg-3.4.0-rc2, llvmorg-3.4.0-rc1, llvmorg-3.3.1-rc1, llvmorg-3.3.0, llvmorg-3.3.0-rc3, llvmorg-3.3.0-rc2, llvmorg-3.3.0-rc1, llvmorg-3.2.0, llvmorg-3.2.0-rc3, llvmorg-3.2.0-rc2, llvmorg-3.2.0-rc1, llvmorg-3.1.0, llvmorg-3.1.0-rc3, llvmorg-3.1.0-rc2, llvmorg-3.1.0-rc1, llvmorg-3.0.0, llvmorg-3.0.0-rc4, llvmorg-3.0.0-rc3, llvmorg-3.0.0-rc2, llvmorg-3.0.0-rc1, llvmorg-2.9.0, llvmorg-2.9.0-rc3, llvmorg-2.9.0-rc2 |
|
#
5ecbb1bc |
| 11-Mar-2011 |
Douglas Gregor <dgregor@apple.com> |
Don't ask if a depenendent CXXRecordDecl has any dependent bases unless we already know that it has a definition. Fixes PR9449/<rdar://problem/9115785>.
llvm-svn: 127512
|
Revision tags: llvmorg-2.9.0-rc1 |
|
#
8b6070bb |
| 04-Mar-2011 |
Douglas Gregor <dgregor@apple.com> |
Teach Sema::ActOnCXXNestedNameSpecifier and Sema::CheckTemplateIdType to cope with non-type templates by providing appropriate errors. Previously, we would either assert, crash, or silently build a d
Teach Sema::ActOnCXXNestedNameSpecifier and Sema::CheckTemplateIdType to cope with non-type templates by providing appropriate errors. Previously, we would either assert, crash, or silently build a dependent type when we shouldn't. Fixes PR9226.
llvm-svn: 127037
show more ...
|
Revision tags: llvmorg-2.8.0, llvmorg-2.8.0-rc3, llvmorg-2.8.0-rc2, llvmorg-2.8.0-rc1, llvmorg-2.8.0-rc0 |
|
#
df65c8ed |
| 28-Jul-2010 |
Douglas Gregor <dgregor@apple.com> |
When a nested-name-specifier refers into a current instantiation that has dependent bases, construct a dependent nested-name-specifier rather than complaining that the name could not be found within
When a nested-name-specifier refers into a current instantiation that has dependent bases, construct a dependent nested-name-specifier rather than complaining that the name could not be found within the current instantiation itself. Fixes PR7725.
llvm-svn: 109582
show more ...
|
#
ffa20398 |
| 17-Jun-2010 |
Douglas Gregor <dgregor@apple.com> |
When pushing a copy of the TypeLoc information for a dependent template specialization type, copy the location information but use the new type. Fixes PR7385.
llvm-svn: 106224
|
#
bb119653 |
| 16-Jun-2010 |
Douglas Gregor <dgregor@apple.com> |
When we see a 'template' disambiguator that marks the next identifier (or operator-function-id) as a template, but the context is actually non-dependent or the current instantiation, allow us to use
When we see a 'template' disambiguator that marks the next identifier (or operator-function-id) as a template, but the context is actually non-dependent or the current instantiation, allow us to use knowledge of what kind of template it is, e.g., type template vs. function template, for further syntactic disambiguation. This allows us to parse properly in the presence of stray "template" keywords, which is necessary in C++0x and it's good recovery in C++98/03.
llvm-svn: 106167
show more ...
|
#
f7d77718 |
| 16-Jun-2010 |
Douglas Gregor <dgregor@apple.com> |
Fix the recently-added warning about 'typename' and 'template' disambiguation keywords outside of templates in C++98/03. Previously, the warning would fire when the associated nested-name-specifier w
Fix the recently-added warning about 'typename' and 'template' disambiguation keywords outside of templates in C++98/03. Previously, the warning would fire when the associated nested-name-specifier was not dependent, but that was a misreading of the C++98/03 standard: now, we complain only when we're outside of any template.
llvm-svn: 106161
show more ...
|
#
c9d2682d |
| 14-Jun-2010 |
Douglas Gregor <dgregor@apple.com> |
Warn when a 'typename' or a 'template' keyword refers to a non-dependent type or template name, respectively, in C++98/03. Fixes PR7111 and <rdar://problem/8002682>.
llvm-svn: 105968
|
#
f3d3ae66 |
| 14-May-2010 |
Douglas Gregor <dgregor@apple.com> |
Make sure to search semantic scopes and appropriate template-parameter scopes during unqualified name lookup that has fallen out to namespace scope. Fixes PR7133.
llvm-svn: 103766
|
#
99b2fe5f |
| 29-Apr-2010 |
John McCall <rjmccall@apple.com> |
Rebuild the nested name specifiers in member-pointer declarator chunks when entering the current instantiation. Set up a little to preserve type location information for typename types while we're i
Rebuild the nested name specifiers in member-pointer declarator chunks when entering the current instantiation. Set up a little to preserve type location information for typename types while we're in there.
Fixes a Boost failure.
llvm-svn: 102673
show more ...
|
Revision tags: llvmorg-2.7.0 |
|
#
1f476a17 |
| 26-Feb-2010 |
John McCall <rjmccall@apple.com> |
Fix an assertion-on-error during tentative constructor parsing by propagating error conditions out of the various annotate-me-a-snowflake routines. Generally (but not universally) removes redundant
Fix an assertion-on-error during tentative constructor parsing by propagating error conditions out of the various annotate-me-a-snowflake routines. Generally (but not universally) removes redundant diagnostics as well as, you know, not crashing on bad code. On the other hand, I have just signed myself up to fix fiddly parser errors for the next week. Again.
llvm-svn: 97221
show more ...
|
#
8fbe78f6 |
| 15-Dec-2009 |
Daniel Dunbar <daniel@zuster.org> |
Update tests to use %clang_cc1 instead of 'clang-cc' or 'clang -cc1'. - This is designed to make it obvious that %clang_cc1 is a "test variable" which is substituted. It is '%clang_cc1' instead o
Update tests to use %clang_cc1 instead of 'clang-cc' or 'clang -cc1'. - This is designed to make it obvious that %clang_cc1 is a "test variable" which is substituted. It is '%clang_cc1' instead of '%clang -cc1' because it can be useful to redefine what gets run as 'clang -cc1' (for example, to set a default target).
llvm-svn: 91446
show more ...
|
#
7427fe28 |
| 29-Nov-2009 |
Daniel Dunbar <daniel@zuster.org> |
Remove unnecessary -fms-extensions=0 from tests (this command line syntax is going away).
llvm-svn: 90066
|
#
120635bc |
| 11-Nov-2009 |
Douglas Gregor <dgregor@apple.com> |
Fix speculative parsing of dependent template names in nested-name-specifiers so that they don't gobble the template name (or operator-function-id) unless there is also a template-argument-list. For
Fix speculative parsing of dependent template names in nested-name-specifiers so that they don't gobble the template name (or operator-function-id) unless there is also a template-argument-list. For example, given
T::template apply
we would previously consume both "template" and "apply" as part of parsing the nested-name-specifier, then error when we see that there is no "<" starting a template argument list. Now, we parse such constructs tentatively, and back off if the "<" is not present. This allows us to parse dependent template names as one would use them for, e.g., template template parameters:
template<typename T, template<class> class X = T::template apply> struct MetaSomething;
Also, test default arguments for template template parameters.
llvm-svn: 86841
show more ...
|
#
ec87bb5c |
| 27-Oct-2009 |
John Thompson <John.Thompson.JTSoftware@gmail.com> |
Disabling some MS extensions which cause these tests to fail
llvm-svn: 85236
|
Revision tags: llvmorg-2.6.0 |
|
#
b4a8fe8d |
| 14-Apr-2009 |
Chris Lattner <sabre@nondot.org> |
Make the implicit-int handling error recovery stuff handle C++ nested name specifiers. Now we emit stuff like:
t.cpp:8:13: error: unknown type name 'X' static foo::X P; ~~~~ ^
instead of:
Make the implicit-int handling error recovery stuff handle C++ nested name specifiers. Now we emit stuff like:
t.cpp:8:13: error: unknown type name 'X' static foo::X P; ~~~~ ^
instead of:
t.cpp:8:16: error: invalid token after top level declarator static foo::X P; ^
This is inspired by a really awful error message I got from g++ when I misspelt diag::kind as diag::Kind.
llvm-svn: 69086
show more ...
|
#
fe3d7d08 |
| 01-Apr-2009 |
Douglas Gregor <dgregor@apple.com> |
Make parsing a semantic analysis a little more robust following Sema failures that involve malformed types, e.g., "typename X::foo" where "foo" isn't a type, or "std::vector<void>" that doens't insta
Make parsing a semantic analysis a little more robust following Sema failures that involve malformed types, e.g., "typename X::foo" where "foo" isn't a type, or "std::vector<void>" that doens't instantiate properly.
Similarly, be a bit smarter in our handling of ambiguities that occur in Sema::getTypeName, to eliminate duplicate error messages about ambiguous name lookup.
This eliminates two XFAILs in test/SemaCXX, one of which was crying out to us, trying to tell us that we were producing repeated error messages.
llvm-svn: 68251
show more ...
|
#
b67535d1 |
| 31-Mar-2009 |
Douglas Gregor <dgregor@apple.com> |
Parsing and AST representation for dependent template names that occur within nested-name-specifiers, e.g., for the "apply" in
typename MetaFun::template apply<T1, T2>::type
At present, we can't
Parsing and AST representation for dependent template names that occur within nested-name-specifiers, e.g., for the "apply" in
typename MetaFun::template apply<T1, T2>::type
At present, we can't instantiate these nested-name-specifiers, so our testing is sketchy.
llvm-svn: 68081
show more ...
|
#
a45cf5b6 |
| 24-Mar-2009 |
Daniel Dunbar <daniel@zuster.org> |
Rename clang to clang-cc.
Tests and drivers updated, still need to shuffle dirs.
llvm-svn: 67602
|