Issue 58112
Summary Clang accepts invalid out of class definition for destructor
Labels new issue
Assignees
Reporter ranaanoop
    The following invalid program is accepted by clang. [Demo](https://godbolt.org/z/TYjEzss6q)

```
template<typename T>
struct C
{
    ~C();
};
template<typename T>
C<T>::~C<T>()             //this is accepted by clang!!
{

}
int main()
{
    C<int> c;;
}
```

This has been discussed [here](https://stackoverflow.com/questions/73928601/clang-accepts-out-of-class-destructor-definition-while-gcc-does-not)
_______________________________________________
llvm-bugs mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs

Reply via email to