Commit Graph

283 Commits (63535f140b938af0c0894d5778c25150bbfa28d9)

Author SHA1 Message Date
gabime d94830814f Removed SPDLOG_WCHAR_TO_UTF8_SUPPORT 2 years ago
gabime 1f61f5e019 clang format 2 years ago
Gabi Melman 31cf79a70d
Remov foreward to standard vformat_to 2 years ago
Eli Boyarski 62a4b8ce4e
Fix fmt build (#2744) 2 years ago
Charles Milette 4f80077339
Support compile-time format string checking with std::format (#2544)
* Support compile-time format string checking with std::format

* Fix pre-VS 17.5 compilation

* Fix compilation without wchar_t support

* What am I doing

* Bring back fmt optimization

* Move to_string_view to common.h

* Fix SPDLOG_CONSTEXPR_FUNC emitting duplicate symbol errors when building in C++11

* Also add inline on VS 2013

* Appender doesn't work on wide strings
3 years ago
gabime 4accce5d7b Try again fixing fmt::vformat_to when SPDLOG_WCHAR_TO_UTF8_SUPPORT is defined 3 years ago
gabime 678a79c0be Fixed syntax error from prev commit 3 years ago
gabime fdb1f5926e Fix fmt::vformat_to when SPDLOG_WCHAR_TO_UTF8_SUPPORT is defined 3 years ago
gabime 6c975fa13b Replace fmt::detail::vformat_to(buf,..) with fmt::vformat_to(fmt::appender(buf) 3 years ago
gabime c627c66560 Replace fmt::detail::vformat_to(buf,..) with fmt::vformat_to(fmt::appender(buf) 3 years ago
Gabi Melman 6c95f4c816
Fix #2419 by documenting the set_pattern behaviour 3 years ago
John Armstrong 799802f93b Add FMT_STRING to allow compilation with FMT_ENFORCE_COMPILE_STRING 3 years ago
gabime 128cbe5a06 clang-format 3 years ago
gabime 6d587f5181 Use fmt::detail::vformat_to(buf, ...) since it is ~20ns faster than fmt::vformat_to(std::back_inserter(buf),..) 3 years ago
Charles Milette ee00f2e07d
Remove fmt_helper.h include from logger.h 3 years ago
Charles Milette 3cf94968e7
Add missing include 3 years ago
Charles Milette ebeb3707b1
Switch to vformat_to
Drive-by: reduce the amount of occurences of #ifdef SPDLOG_USE_STD_FORMAT
3 years ago
gabime dc030ec53c clang-format 4 years ago
Charless Milette 6ff1b83038 Fix usage of std::forward 4 years ago
Charless Milette 44a4517e2b Support C++20 std::format as an alternative to fmtlib 4 years ago
Gabi Melman 29e5930090
Update logger.h 4 years ago
Wolfgang Petroschka 0d10e21c2f Remove inner try catch in SPDLOG_LOGGER_CATCH
The fmt::format call should not throw formatting the exception message and the source code location.
4 years ago
Wolfgang Petroschka ed27592537 Switch additional information to source location of bad log message 4 years ago
Wolfgang Petroschka df45d78d14 Windows/wchar problems
Mixing char types in libfmt is a problem and WIP.
4 years ago
Wolfgang Petroschka 119467c580 Added additional information for error handler
Useful when formatting log messages fails. Now you can tell which log message caused the problem.
4 years ago
dkavolis e471ec884e remove conditional `is_convertible_*` structs for wide chars 4 years ago
dkavolis cb35191fc1 clang is acting weird with disabled constructors 4 years ago
Stephane Janel aecdfc60a0 Fix comment and clang-format 4 years ago
gabime 9049f9aeb9 Fix ambiguous error in clang13 and c++20 4 years ago
dkavolis d8f13cbd5b replace FormatString template argument with fmt::basic_format_string 4 years ago
dkavolis 1344d44a5a check args on formatting 4 years ago
gabime db1bc035f7 clang-format 4 years ago
gabime fe1a4f5fb6 Added SPDLOG_FMT_RUNTIME macro for compatibilty with fmt prior 8 4 years ago
gabime 9c90fe8264 Fixed wchar support 4 years ago
Gabi Melman 5ba95f6816
Update logger.h 4 years ago
Gabi Melman dc38b7c3c4
Update logger.h 4 years ago
Gabi Melman 6484b03dd9
Update logger.h 4 years ago
gabime 29235d9b4b minor string_view change and comment 4 years ago
gabime e98265a49b cosmetic reorder of logger funcs definitions 4 years ago
gabime e87f69bdb6 Removed check if format string can be converted to fmt::is_compile_string 4 years ago
gabime 8faabb4e3a Fix msvc compile 4 years ago
gabime 2838c2c8a5 use vformat_to instead for format_to for better performance 4 years ago
gabime 70b36aa55d Remove fmt::runtime() wrapper in logger.h 4 years ago
gabime 0f83b33d4f backward compatibility with fmt version < 8 4 years ago
Gabi Melman ffd813435a
fix compile error again with wchar formatting 4 years ago
gabime cdad84aa46 merge 4 years ago
gabime a5f5ff70e0 Fixed clang c++20 compile 4 years ago
Gabi Melman 6811112208
Update logger.h 4 years ago
gabime 7b14a65b2b Fixed format_to deprecated warning by wrapping the buffer with std::back_inserter 4 years ago
gabime e9635c7b2d rethrnow non std exceptions to fix #533 4 years ago
dkavolis 23572369fc Perfect forwarding for arguments 5 years ago
gabime 231ca50700 clang-format 5 years ago
gabime e69699e12c enable_if 5 years ago
gabime b0c4794305 Use default pointer type in enable_if 5 years ago
Joe Burzinski 741b0d6e82 Address code review comments: remove perfect forwarding on FormatString template parameters. 5 years ago
Joe Burzinski 3041faffab Address code review comments: revert perfect forwarding on places that didn't need it, remove negative compilation unit test. 5 years ago
Joe Burzinski 30ee690401 Add support for FMT_STRING compile time checking. Add negative compilation unit test for compilers and c++ standard that support relaxed constexpr. 5 years ago
Ron Rechenmacher faaef7686d pass log_time param by value 5 years ago
Ron Rechenmacher 9e6f5b6b2d add single logger method and log_msg constructor and tests/test_time_point.cpp 5 years ago
Martin Vejdarski 0ca2cb625e Add shared library support for Windows 6 years ago
gabime 5370443ece clang-format 6 years ago
dominicpoeschko 25b10dc264 additional log overload
calling log with a string_view as msg called
```
 template<typename... Args>
    void log(source_loc loc, level::level_enum lvl, string_view_t fmt, const Args &... args)
```

instead of
```
template<class T, typename std::enable_if<std::is_convertible<const T &, spdlog::string_view_t>::value, T>::type * = nullptr>
    void log(source_loc loc, level::level_enum lvl, const T &msg)
```

which lead to an unnecessary call to fmt::format
6 years ago
Cristian Morales Vega 7cdd65075c "#include" <spdlog/.*> instead of "spdlog/.*"
The meaning of using quotes to #include is implementation defined, so it
may or not may be what we want. At least POSIX
(https://pubs.opengroup.org/onlinepubs/9699919799/utilities/c99.html)
says: "headers whose names are enclosed in double-quotes ( "" ) shall be
searched for first in the directory of the file with the #include line",
so not what we want since "spdlog" ends up twice in the path.
6 years ago
gabime bf40855825 Micro-optimize level checking by inlining 6 years ago
gabime 79468cf676 Micro-optimze log_it_ 6 years ago
gabime 15b393193a Replaced a forgotten try with SPDLOG_TRY 6 years ago
Florian Pigorsch 4aad51a352 Fix some spelling errors.
casese -> cases (1)
chache -> cache (1)
cirucal -> circular (1)
dependecy -> dependency (1)
detrmine -> determine (2)
eavluate -> evaluate (1)
exertnal -> external (1)
ony -> only (1)
registation -> registration (3)
registring -> registering (2)
regsistration -> registration (3)
seperate -> separate (2)
wit -> with (1)
withe -> with (1)
6 years ago
gabime 9a0a0c2d8c clang-format 6 years ago
gabime fcc809f4f1 Refactored logger 6 years ago
gabime 9369fe8c27 Fix #1262 6 years ago
Gabi Melman bf49bebe7a
Update logger.h 6 years ago
gabime 4c45c6fbd8 Removed redundant func 6 years ago
gabime f795297e15 try different apprach to backtracer object 6 years ago
gabime ed8d099607 Fixed #1197 6 years ago
gabime f3a7ef1199 Fix compile bug 6 years ago
Gabi Melman cb890c96b9
Update logger.h 6 years ago
gabime f5492aed12 Unified usage of fmt::memory_buffer across the codebase 6 years ago
gabime c97c025adb clang-format 6 years ago
gabime 0fa09f6af4 Removed dead clode 6 years ago
gabime 011ed270e8 backtrace support for wchar api under windows 6 years ago
gabime 408a162044 Removed logger::clone() from API 6 years ago
gabime e1be7f3d6f Refactoring to better support backtrace 6 years ago
gabime 04a8485b17 Replaced backtace implementation 6 years ago
gabime f3e379cf78 Fixed async dump_backtrace 6 years ago
gabime 099137fe9a backtrace_sink code cleanup 6 years ago
gabime a7f7984c4a backtrace support api 6 years ago
gabime dd33c16aae Replace backtrace trigger with dump_backtrace() 6 years ago
gabime 8d8aacf5e9 Protect from double call to enable_backtrace() 6 years ago
gabime a6d8b52686 Added enable_backtrace to spdlog_api 6 years ago
gabime 0284a23d0a Changed sink_it_ to accept const log_message& 6 years ago
gabime 0335e3fcc0 Print error and abort instead of throw if SPDLOG_NO_EXEPTIONS is defined 6 years ago
gabime 6506b73523 Add noexcept to move ctor and operator= 6 years ago
gabime 01eb59ca9b Removed spdlog::default_level and its usage in registry 6 years ago
gabime ffb7c317b5 Fix #1176 again 6 years ago
Gabi Melman bb7420fc22
Update logger.h 6 years ago
gabime 0df9164e7c Fix #1176 6 years ago
Charles Milette eb51f37c67
Fix ambiguous overload errors 6 years ago
Charles Milette 4ef4d0659d
Improve correctness of convertion checks 6 years ago
Charles Milette 2ce9a3f70f
Add overload to logger when T can be statically converted to wstring_view_t 6 years ago
gabime a7ba6e447d clang-format 6 years ago