dblaikie added a comment. In D90719#2377883 <https://reviews.llvm.org/D90719#2377883>, @rsmith wrote:
> Perhaps we could address both the UB and the debug info homing issue by > adding a new attribute on the libc++ types that says it's valid to create an > instance of the type without calling a constructor? (If we want to support > old libc++ with trunk clang, we could detect those types and automatically > synthesize the attribute, but libc++ is moving towards being version-locked > to clang anyway, so I don't think we need to worry about that too much.) My guess would be that this doesn't come up often enough to merit an attribute, etc, and that libc++ is fixable. (if the code really wants to do no work when constructing, changing the type to have a trivial ctor and the places that want non-trivial construction can initialize the members as needed seems like it'd be viable) But it does present significant challenges/hamstring code optimization opportunities, sure, an attribute could be handy/a way forward. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D90719/new/ https://reviews.llvm.org/D90719 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits