Commit Graph

4974 Commits

Author SHA1 Message Date
Victor Zverovich
ccf4ccde23 Cleanup tests and format string compilation 2021-04-29 19:50:04 -07:00
Victor Zverovich
e96a92f869 Cleanup tests and format string compilation 2021-04-29 16:21:08 -07:00
Alexey Ochapov
fd43e4dcbc gtest: fix std::is_trivially_copy_constructible for GCC 4.8 & 4.9 properly
`std::is_pod<T>` was deprecated in C++20

original (pre `is_pod`) error on GCC 4.8:
```
/fmt/test/gtest/gtest.h: In static member function 'static constexpr bool testing::internal::MatcherBase<T>::IsInlined()':
/fmt/test/gtest/gtest.h:6512:12: error: 'is_trivially_copy_constructible' was not declared in this scope
            std::is_trivially_copy_constructible<M>::value &&
            ^
/fmt/test/gtest/gtest.h:6512:45: error: expected primary-expression before '>' token
            std::is_trivially_copy_constructible<M>::value &&
                                                  ^
/fmt/test/gtest/gtest.h:6512:46: error: '::value' has not been declared
            std::is_trivially_copy_constructible<M>::value &&
                                                   ^
```
2021-04-29 07:11:49 -07:00
Alexey Ochapov
3d51ccdaae gtest: remove obsolete GTEST_LANG_CXX11 compile definition setting 2021-04-29 07:11:49 -07:00
Alexey Ochapov
833377ff1e gtest: add .clang-format file into test/gtest directory to prevent formatting there 2021-04-29 07:11:49 -07:00
Alexey Ochapov
53ca0cbe75 gtest: move GTest/GMock files to separate directory, update GTest/GMock usages
* all GTest/GMock files moved to `test/gtest` directory
* `CMakeLists.txt` created in `test/gtest` from `CMakeLists.txt` in `test`
* GTest/GMock target in CMake renamed to `gtest` (was `gmock`)
* CMake `gtest` target updated to export includes as "gtest/gtest.h" or "gmock/gmock.h" only
* includes in tests updated: "gtest.h" -> "gtest/gtest.h", "gmock.h" -> "gmock/gmock.h"
* removed duplications of `target_include_directories` for GTest/GMock directories (CMake manages them)
2021-04-29 07:11:49 -07:00
Daniela Engert
342973b349 Make wchar_t overloads usable in module
Bring ''detail::find()' into scope.
2021-04-28 09:37:57 -07:00
Victor Zverovich
355be4b13f Make FMT_COMPILE fallback on runtime without if constexpr (#2261) 2021-04-28 09:11:47 -07:00
Владислав Щапов
0cd0fb9184 C++17: std::char_traits<>::{compare,length} is constexpr - v2 2021-04-28 07:05:32 -07:00
Daniela Engert
d1a6e5603f Keep defaulted destructors inline
applies to exception classes in case of msvc only
2021-04-28 06:17:26 -07:00
Victor Zverovich
84a36b99bf Move data to functions 2021-04-27 17:21:32 -07:00
Victor Zverovich
ab7c33ede0 Suppress checked iterator warnings 2021-04-27 13:54:39 -07:00
Alexey Ochapov
77258f6069 fix FMT_CONSTEXPR_CHAR_TRAITS check for MSVC 2021-04-26 16:35:32 -07:00
Alexey Ochapov
d23e315ea2 CI windows: add MSVC C++20 build 2021-04-26 16:35:32 -07:00
Alexey Ochapov
f085c3d7a0 use proper check for non-type template parameters 2021-04-26 16:35:32 -07:00
Victor Zverovich
69bdc20a3c Workaround missing std::system on iOS, take 2 2021-04-26 06:21:44 -07:00
Victor Zverovich
847aac4315 Follow naming conventions in tests 2021-04-25 21:26:30 -07:00
Victor Zverovich
39818e7979 Cleanup core-test 2021-04-25 17:59:23 -07:00
Ilya Kurdyukov
0e6f989b0d
__THROW warning fix for e2k (#2253) 2021-04-25 08:51:37 -07:00
Alexey Ochapov
1678ed6235 simplify field::format() and spec_field::format(), fix typo 2021-04-25 07:53:49 -07:00
Alexey Ochapov
ca821982ee use named arg with static name in compile-time API
to get arg index by name at compile-time
2021-04-25 07:53:49 -07:00
Alexey Ochapov
ce6e7d8620 use fixed_string to create named arg class with static name for _a literal 2021-04-25 07:53:49 -07:00
Alexey Ochapov
fc56af14c2 move fixed_string from compile.h to format.h 2021-04-25 07:53:49 -07:00
Victor Zverovich
bb006f9735 Replace TYPED_TEST_CASE with TYPED_TEST_SUITE 2021-04-24 17:46:49 -07:00
Victor Zverovich
6956b10b2d Fix gcc 4.8 build 2021-04-24 11:04:34 -07:00
Victor Zverovich
b4f9a05894 Update gtest 2021-04-24 11:03:40 -07:00
Victor Zverovich
8f9ddf452d Remove deprecated posix.h 2021-04-24 07:03:11 -07:00
Daniela Engert
dacd1356e4 Add module interface unit 2021-04-24 06:39:57 -07:00
Daniela Engert
d3c523e0d2 Export printf-related contexts from printf.h 2021-04-24 06:39:57 -07:00
Daniela Engert
2c25df089f Export replacement type_traits, too 2021-04-24 06:39:57 -07:00
Victor Zverovich
553022dc56 Don't use std::system on iOS (#2248) 2021-04-24 06:17:05 -07:00
Victor Zverovich
8a040d187a Cleanup core-test 2021-04-23 20:07:48 -07:00
Victor Zverovich
064cac2bf9 Bump version 2021-04-23 16:05:03 -07:00
Victor Zverovich
5b2c740ad8 Remove deprecated APIs 2021-04-23 15:27:25 -07:00
Victor Zverovich
b9ab5c8836 Remove printf.h dependency on ostream.h 2021-04-23 10:42:57 -07:00
Victor Zverovich
c47f211296 Simplify data handling 2021-04-23 06:52:10 -07:00
Victor Zverovich
54d3b1710e Move more data out of basic_data 2021-04-23 06:45:23 -07:00
Vladislav Shchapov
128f007b25
C++17: std::char_traits<>::{compare,length} is constexpr. (#2246) 2021-04-23 06:11:34 -07:00
Victor Zverovich
841aad95b4 Move data out of basic_data 2021-04-22 15:29:42 -07:00
Alexey Ochapov
1d4199f46b
fix udl_compiled_string with non-byte chars (e.g. wchar) (#2242) 2021-04-19 08:29:35 -07:00
yumeyao
c5d4fcb119
Appending a space to guarantee non-empty strftime() result. (#2244) 2021-04-18 19:13:51 -07:00
Victor Zverovich
6271406233 Fix a warning (#2233) 2021-04-16 15:58:17 -07:00
denchat
52bd62c72f
Create separate dllexport marking points for clang and msvc. (#2229)
* add FMT_INSTANTIATION_DEF_API for msvc

This should fix https://github.com/fmtlib/fmt/issues/2228

To fix difference dllexport requirements
msvc:  dllexport at template instantiation definition in format.cc
clang: dllexport at template instantiation declaration (extern template) in format.h
2021-04-16 12:34:18 -07:00
Daniela Engert
f4bbc54cc4
Tag official API for module export (#2235)
* functions
 * classes
 * UDLs
 * other declarations

Export everything in namespace 'fmt' from core.h and format.h
2021-04-16 11:04:55 -07:00
Daniela Engert
d8910af80d
Use qualified name lookup rather than ADL. (#2239)
Name lookup within exported templates cannot find non-exported entities by ADL when instantiation takes place outside the module.
2021-04-16 09:38:25 -07:00
crbrz
9260114162
Ranges wide strings support (#2236)
* Ranges copy wchar_t

* arg_join formatter not working for wide strings

* Added ranges wide string tests

Co-authored-by: Cristi <cristi@emailaddressmanager.com>
2021-04-16 06:25:35 -07:00
denchat
24c9751558
Try to suppress MVSC warn of narrowing (#2230) 2021-04-13 07:30:43 -07:00
Victor Zverovich
a1c6bfd77b Add a link to llvm diff 2021-04-12 10:05:14 -07:00
denchat
42eccac454
Fix clang warning about ignoring __declspec(dllexport) on basic_data<void> template instantitation definition (#2220) 2021-04-12 09:31:44 -07:00
Victor Zverovich
aec504344a
Update README.rst 2021-04-10 08:48:11 -07:00