diff options
author | Pavel Labath <labath@google.com> | 2018-01-18 11:15:50 +0000 |
---|---|---|
committer | Pavel Labath <labath@google.com> | 2018-01-18 11:15:50 +0000 |
commit | 013ade4ac6ec9ac52ac69d54d9f6adeb8cfc26cb (patch) | |
tree | 0582a39242d31263ac0291df1513ff1a1abce3c3 | |
parent | 215f8dc9ada385e659d3b9d45d7df5b03e6f95db (diff) |
Fix logging test on windows
Refactor in r322653 broke the logging test on windows because MSVC uses
a fully qualified name as the value of __FUNCTION__, which is not what
we were expecting. I'm changing the code to use the more portable
__func__, which behaves the same as on clang/gcc.
The standard still says that the value of __func__ is implementation
defined, so if we run into problems with this test again we may just
need to drop it.
git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@322834 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r-- | include/lldb/Utility/Log.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/include/lldb/Utility/Log.h b/include/lldb/Utility/Log.h index 80a80fc16..81028381b 100644 --- a/include/lldb/Utility/Log.h +++ b/include/lldb/Utility/Log.h @@ -208,14 +208,14 @@ private: do { \ ::lldb_private::Log *log_private = (log); \ if (log_private) \ - log_private->Format(__FILE__, __FUNCTION__, __VA_ARGS__); \ + log_private->Format(__FILE__, __func__, __VA_ARGS__); \ } while (0) #define LLDB_LOGV(log, ...) \ do { \ ::lldb_private::Log *log_private = (log); \ if (log_private && log_private->GetVerbose()) \ - log_private->Format(__FILE__, __FUNCTION__, __VA_ARGS__); \ + log_private->Format(__FILE__, __func__, __VA_ARGS__); \ } while (0) #endif // LLDB_UTILITY_LOG_H |