[llvm-bugs] [Bug 25783] New: Compilation of explicit destructor call look-alike call inside template fails
via llvm-bugs
llvm-bugs at lists.llvm.org
Tue Dec 8 16:57:14 PST 2015
https://llvm.org/bugs/show_bug.cgi?id=25783
Bug ID: 25783
Summary: Compilation of explicit destructor call look-alike
call inside template fails
Product: clang
Version: 3.7
Hardware: PC
OS: Linux
Status: NEW
Severity: normal
Priority: P
Component: -New Bugs
Assignee: unassignedclangbugs at nondot.org
Reporter: altsysrq at gmail.com
CC: altsysrq at gmail.com, llvm-bugs at lists.llvm.org
Classification: Unclassified
Created attachment 15420
--> https://llvm.org/bugs/attachment.cgi?id=15420&action=edit
clang++-3.7 -v template_class_call_dtor.cpp
Compiling following example leads to segfault inside clang 3.7:
// template_class_call_dtor.cpp
template<class T>
struct C
{
~C()
{
}
void f() {
// segfault:
C<T>::~C();
// OK:
//this->C<T>::~C();
//this->~C();
}
};
int main()
{
C<int> c;
c.f();
}
Not sure is this is a correct syntax of explicit destructor call according by
the Standard, but this example compiles (and calls destructor) in g++ 5.3.
--
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20151209/b5bedaea/attachment.html>
More information about the llvm-bugs
mailing list