[clang] [clang-cl] Fix value of __FUNCTION__ in MSVC mode. (PR #84014)
Zahira Ammarguellat via cfe-commits
cfe-commits at lists.llvm.org
Tue Mar 5 08:12:45 PST 2024
zahiraam wrote:
> I’m not entirely sure this change is a good idea: some people might be relying on Clang’s behaviour wrt `__FUNCTION__`, especially with how long it’s been around; Clang may not be fully MSVC-compatible in this case, but that incompatibilty seems unlikely to cause problems imo since afaik most people that actually depend on the output of these sorts of macros for e.g. reflexion use `__FUNCSIG__` or `__PRETTY_FUNCTION__` instead—then again, that could also be a reason as to why changing it might actually be fine.
Thanks for the review. This is an issue that we encountered in our internal testing with an application using `__FUNCTION__`. I agree that might not be used by a lot of users/apps, but it is used and having it compatible with MSVC doesn't actually hurt? (I hope).
https://github.com/llvm/llvm-project/pull/84014
More information about the cfe-commits
mailing list