[PATCH] D119209: [clang] Add cc1 option -fctor-dtor-return-this

Fangrui Song via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Mon Oct 3 14:07:43 PDT 2022


MaskRay accepted this revision.
MaskRay added inline comments.
This revision is now accepted and ready to land.


================
Comment at: clang/include/clang/Driver/Options.td:5608
+def fctor_dtor_return_this : Flag<["-"], "fctor-dtor-return-this">,
+  HelpText<"Change the C++ ABI to returning `this` pointer from constructors "
+           "and non-deleting destructors. (No effect on Microsoft ABI.)">,
----------------
MaskRay wrote:
> scw wrote:
> > MaskRay wrote:
> > > If you use Itanium C++ ABI, it's clear it doesn't change Microsoft ABI.
> > > 
> > > The convention for HelpText is to omit the trailing period.
> > I was gonna do that but realized the change actually apply to all C++ ABIs (I changed CGCXXABI). It's just Microsoft overrides the same method I changed making it a no-op.
> Not done?
Thanks. This is fine.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D119209/new/

https://reviews.llvm.org/D119209



More information about the cfe-commits mailing list