arphaman marked an inline comment as done. arphaman added inline comments.
================ Comment at: clang/lib/CodeGen/CGDecl.cpp:377 - if (D.needsDestruction(getContext()) && HaveInsertPoint()) { + if (hasNontrivialDestruction(D.getType()) && HaveInsertPoint()) { // We have a constant initializer, but a nontrivial destructor. We still ---------------- rjmccall wrote: > The long-term fix here is probably for `needsDestruction` to say that > variables of static storage duration of non-trivial ARC type and/or > non-trivial C struct type don't need destruction. I don't have time to fix it properly right now, but I filed https://github.com/llvm/llvm-project/issues/93 to keep track of the issue. Can this be committed now before the branch next week to avoid shipping this bug in the release? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D72411/new/ https://reviews.llvm.org/D72411 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits