summaryrefslogtreecommitdiffstats
path: root/clang/test/SemaTemplate/destructor-template.cpp
Commit message (Collapse)AuthorAgeFilesLines
* [Sema] Fixes a crash with a templated destructorMark de Wever2019-11-071-0/+10
| | | | | | | | The issue was introduced by D33189 which fixed PR33189. Fixes PR38671: "destructor cannot be declared as a template" leads to segfault in Sema::LookupSpecialMember Differential Revision: https://reviews.llvm.org/D69225
* Fix PR 33189: Clang assertion on template destructor declarationHubert Tong2017-06-301-0/+6
| | | | | | | | | | | | | | | | | | | | | | | Summary: This patch aims to fix the bug reported at https://bugs.llvm.org/show_bug.cgi?id=33189. Clang hits an assertion when a template destructor declaration is present. This is caused by later processing that does not expect to encounter a template when looking at a destructor. The resolution is to treat the destructor as being not declared when later processing is interested in the properties of the destructor of a class. Reviewers: rcraik, hubert.reinterpretcast, aaron.ballman, rsmith Reviewed By: rsmith Subscribers: rsmith, cfe-commits Differential Revision: https://reviews.llvm.org/D33833 Patch by Kuang He! llvm-svn: 306905
* Sema: Recover when a function template is in an extern "C" blockDavid Majnemer2015-01-151-3/+7
| | | | llvm-svn: 226135
* Correctly profile CXXPseudoDestructorExprs.Eli Friedman2013-08-091-1/+7
| | | | | | CXXPseudoDestructorExprs may not contain a type. PR16852. llvm-svn: 188123
* <rdar://problem/13140795> Transform the scope type of a pseudo-destructor ↵Douglas Gregor2013-03-081-0/+19
| | | | | | | | | | | | | expression within the object scope. We were transforming the scope type of a pseudo-destructor expression (e.g., the first T in x->T::~T()) as a freestanding type, which meant that dependent template specialization types here would stay dependent even when no template parameters were named. This would eventually mean that a dependent expression would end up in what should be fully-instantiated ASTs, causing IRgen to assert. llvm-svn: 176723
* Diagnose destructor templates. Fixes PR7904.Douglas Gregor2011-03-041-0/+7
| | | | llvm-svn: 127042
* When we've parsed a nested-name-specifier in a member accessDouglas Gregor2010-05-271-0/+10
| | | | | | | expression, "forget" about the object type; only the nested-name-specifier matters for name lookup purposes. Fixes PR7239. llvm-svn: 104834
* Strip cv-qualifiers when building C++ constructor and destructorDouglas Gregor2010-04-231-0/+8
| | | | | | names. llvm-svn: 102171
* Use CXXPseudoDestructorExpr as the stored representation for dependentDouglas Gregor2010-02-251-0/+2
| | | | | | | | | | | | | | | | expressions that look like pseudo-destructors, e.g., p->T::~T() where p has dependent type. At template instantiate time, we determine whether we actually have a pseudo-destructor or a member access, and funnel down to the appropriate routine in Sema. Fixes PR6380. llvm-svn: 97092
* Improve parsing and instantiation of destructor names, so that we canDouglas Gregor2010-02-161-0/+13
| | | | | | | | | | | | | | | | | | | | | | | now cope with the destruction of types named as dependent templates, e.g., y->template Y<T>::~Y() Nominally, we implement C++0x [basic.lookup.qual]p6. However, we don't follow the letter of the standard here because that would fail to parse template<typename T, typename U> X0<T, U>::~X0() { } properly. The problem is captured in core issue 339, which gives some (but not enough!) guidance. I expect to revisit this code when the resolution of 339 is clear, and/or we start capturing better source information for DeclarationNames. Fixes PR6152. llvm-svn: 96367
* Update tests to use %clang_cc1 instead of 'clang-cc' or 'clang -cc1'.Daniel Dunbar2009-12-151-1/+1
| | | | | | | | | - 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
* When checking the base object of a member access expression (b.foo,Douglas Gregor2009-11-201-0/+7
| | | | | | b->foo), don't look through pointers unless we have an -> operator. llvm-svn: 89480
* Skip over bases/fields with dependent types.Fariborz Jahanian2009-08-251-0/+12
Fixes pr4771. llvm-svn: 79999
OpenPOWER on IntegriCloud