[PATCH] D24704: PR30401: Fix substitutions for functions with abi_tag

Dmitry Polukhin via cfe-commits cfe-commits at lists.llvm.org
Sun Sep 18 12:00:19 PDT 2016


DmitryPolukhin added inline comments.

================
Comment at: lib/AST/ItaniumMangle.cpp:668
@@ -664,3 +667,3 @@
   llvm::raw_svector_ostream FunctionEncodingStream(FunctionEncodingBuf);
   CXXNameMangler FunctionEncodingMangler(*this, FunctionEncodingStream);
   // Output name of the function.
----------------
rsmith wrote:
> Maybe it'd be simpler to just override the output stream here rather than creating a new mangler?
I'm not sure that it is simpler because it will also require substitutions save/restore for name mangling (mangleNameWithAbiTags) to produce the same substitutions twice (without implicate abi_tags and later with implicit abi_tags). IMHO, it is almost identical approaches but current one is a bit cleaner because it copies explicitly everything required from temp to outer mangler.


https://reviews.llvm.org/D24704





More information about the cfe-commits mailing list