aaron.ballman added inline comments.

================
Comment at: clang/lib/Sema/SemaTemplateDeduction.cpp:5184
 
-  // FIXME: This mimics what GCC implements, but doesn't match up with the
-  // proposed resolution for core issue 692. This area needs to be sorted out,
----------------
ychen wrote:
> aaron.ballman wrote:
> > aaron.ballman wrote:
> > > We tend not to use top-level const on locals in the project as a matter 
> > > of style.
> > Does GCC still implement it this way?
> > 
> > One concern I have is that this will be an ABI breaking change, and I'm not 
> > certain how disruptive it will be. If GCC already made that change, it may 
> > be reasonable for us to also break it without having to add ABI tags or 
> > something special. But if these changes diverge us from GCC, that may 
> > require some extra effort to mitigate.
> Unfortunately, GCC is still using the old/non-conforming behavior. 
> https://clang.godbolt.org/z/5K4916W71. What is the usual way to mitigate this?
You would use the `ClangABI` enumeration to alter behavior between ABI 
versions: 
https://github.com/llvm/llvm-project/blob/main/clang/include/clang/Basic/LangOptions.h#L174
 like done in: 
https://github.com/llvm/llvm-project/blob/main/clang/lib/AST/DeclCXX.cpp#L929


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D128745

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

Reply via email to