rjmccall added a comment.

In https://reviews.llvm.org/D44536#1039428, @rjmccall wrote:

> Hmm.  Sema is lazy about actually creating implicit destructor declarations, 
> but it's supposed to only do it whenever the destructor is actually used for 
> something.  I suspect that Sema just thinks that nothing is using c::~c, 
> because the only thing that does use it is d::~d, which is inline and has no 
> apparent users.  But from the stack trace, it seems that IRGen is in fact 
> emitting d::~d.  So the question is, why is IRGen emitting d::~d?  Because 
> AFAIK a non-array new-expression never requires the destructor to exist.


Oh, because it's used in d's v-table, of course, which is needed by the 
implicit constructor for d.


Repository:
  rC Clang

https://reviews.llvm.org/D44536



_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to