Commit Graph

140 Commits

Author SHA1 Message Date
Christoph Reiter
b3bf23f3c4
Remove leftover usage of the __std_stream header (#3663)
2dd4fa8742 removed all usage of __std_stream because
it is no longer available with clang v17. That commit missed one place
where the header was still used (only used when building with -DFMT_MODULE=ON).
Remove it there too.

See #3654
2023-10-01 08:16:42 -07:00
Victor Zverovich
0f823df46a Remove detail namespace hack 2023-06-04 15:19:50 -07:00
Victor Zverovich
b2106f3639 Tweak comments 2023-05-31 09:52:44 -07:00
Bin Lan
61fb3a15ff
Add VxWorks7 user space and kernel space support (#3467) 2023-05-31 06:35:07 -07:00
Victor Zverovich
b14913fae5 FMT_MODULE_EXPORT -> FMT_EXPORT 2023-05-17 07:38:06 -07:00
Victor Zverovich
93a30a0746 unicode_to_utf8 -> to_utf8 since both sides of conversion are Unicode 2023-05-10 16:26:02 -07:00
Vladislav Shchapov
dde8cf3bb7 Unification utf16/utf32 to utf8 conversion
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2023-05-06 08:32:51 -07:00
Daniela Engert
192df93d7b
modules missing pieces (#3399)
- don't export names from `detail`
- put more headers into the global module fragment
- support MSYS2 and Clang
2023-05-05 10:21:18 -07:00
mogemimi
d8973bf16b
Add FMT_STRING for format_to() call (#3413) 2023-05-03 07:58:40 -07:00
Daniela Engert
eafcd3c8e1
Optionally attach declarations to the global module rather than module fmt (#3387)
This allows coexistence with TUs that use {fmt} through #include without duplicating declarations, definitions, linker symbols, and object code.
2023-04-23 06:04:36 -07:00
Daniela Engert
0489c19dcb
fix and improve module (#3386)
* export public documented API
* don't export `namespace detail`
* add `std.h` into module
* add missing namespace qualification in `xchar.h`
* fix call to `detail::get_iterator` in `xchar.h`
* fix ambiguous overload of `detail::isfinite` in `chrono.h`
2023-04-18 06:47:01 -07:00
Victor Zverovich
d9c19940a3 Update add_module_library 2023-04-13 17:13:52 -07:00
Victor Zverovich
c98e5a08a4 Fix modular build on clang 2023-04-10 12:07:25 -07:00
Victor Zverovich
119c6bd16f Move the modules check 2023-04-10 09:28:00 -07:00
Victor Zverovich
77eeb71830 Remove unused headers 2023-04-10 09:08:19 -07:00
Victor Zverovich
13bf99f9db Enable modules in clang 16 2023-04-10 08:44:43 -07:00
Victor Zverovich
1d0257e4c0 FMT_MODULE_EXPORT_* -> FMT_EXPORT_* 2023-04-10 08:33:39 -07:00
Mikhail Paulyshka
d3c10f5167
fix compilation for MSDOS (#3369) 2023-04-01 13:40:53 -07:00
Victor Zverovich
d646fd0daf Minor cleanup 2023-02-16 11:21:08 -08:00
Froster
b5c2f74f45
change sopen_s to wsopen_s (fmtlib#3234) (#3293) 2023-02-16 11:17:55 -08:00
Shawn Zhong
3c5464ba1c
Fix OpenBSD build error (#3295) 2023-02-11 08:46:28 -08:00
Victor Zverovich
9e4a54fa6e Disable remaining implicit conversions 2023-01-03 12:08:42 -08:00
Victor Zverovich
6056e07125 Simplify symbols 2022-12-30 19:35:05 -08:00
Ihor Dutchak
80f8d34427
fmt::ostream - aggregate buffer instead of inheriting it (#3139)
Some MSVC-specific behavior:
When class fmt::ostream inherits detail::buffer - the last gets implicitly exported when fmt is built as a shared library.
Unless os.h is included, the compiler assumes detail::buffer is not externally exported and instantiates a local copy of it, which causes ODR violation.
With aggregation - there is no extra exporting of detail::buffer symbols.
2022-10-23 07:21:36 -07:00
Andy Maloney
8ae56161c8
Fix compilation with FMT_ENFORCE_COMPILE_STRING and FMT_WERROR (#3091) 2022-09-10 18:05:10 -07:00
Victor Zverovich
d6a8704605 Improve locale support 2022-09-02 11:52:19 -07:00
Victor Zverovich
48327a82e3 Make format.h compile faster 2022-09-01 17:06:47 -07:00
Victor Zverovich
64e29893cf Improve locale support 2022-09-01 14:48:43 -07:00
agga
ba50c19e82 use qualified call to avoid ADL conflict with std::format_to 2022-06-01 15:57:15 -07:00
Victor Zverovich
d1026fa5d2 Remove extern format_float 2022-05-29 13:11:19 -07:00
Victor Zverovich
ce246aaf74 Remove deprecated APIs 2022-05-22 07:10:09 -07:00
Victor Zverovich
496aff7c33 Remove deprecated APIs 2022-05-21 15:12:38 -07:00
Victor Zverovich
3c61799fbf Cleanup fuzzing mode 2022-03-18 12:01:52 -07:00
Victor Zverovich
c076a54a4d Move snprintf_float to format.h 2022-03-18 08:31:31 -07:00
Andreas Rogge
ae1aaaee5f
Fix access mode of files created (#2530) (#2733)
The previous fix for this in 4a85db1 was incomplete. The intent was to
mimic what `fopen()` is doing. As per standard[1] `fopen()` also sets
`S_IWGRP` and `S_IWOTH` and lets the umask handle the rest.

[1] https://pubs.opengroup.org/onlinepubs/9699919799.2018edition/functions/fopen.html
2022-01-28 17:12:49 -08:00
Victor Zverovich
c28500556a FMT_NOEXCEPT -> noexcept 2022-01-20 16:55:47 -08:00
Victor Zverovich
713c7c7c62 Cleanup os.cc 2021-12-01 06:47:41 -08:00
Acretock
9b1807a8a2
fix int -> uint warning (#2611)
* fix int -> uint warning

* change unsigned int to mode_t

* undef + warn uint -> ushort loss presision

* fix mode_t

* mode_t in detail

Co-authored-by: Acretock <George.Goncharov@finch-xr.com>
2021-12-01 06:40:17 -08:00
Florin Iucha
acad8cfab1 Reformat all source code; no functional changes
Before adding the format checker, the mainline should be clean, to
avoid false failures.
2021-11-25 09:15:25 -08:00
Victor Zverovich
4a85db1ce1 Change default open mode to -rw-r--r-- (#2530) 2021-10-03 06:36:40 -07:00
Victor Zverovich
3d0c7ae385 Move data to format.cc 2021-09-13 06:23:57 -07:00
Victor Zverovich
3e7a29cc92 Workaround clang/gcc incompatibility 2021-07-02 13:29:22 -07:00
Daniela Engert
0193e7c428 Support compile-time strings and compile-time format string compilation in module
Make just the necessary parts available for lookup from client context.
2021-06-11 09:38:53 -07:00
Victor Zverovich
f4c95f6dd9 Improve handling of thousands separator 2021-06-03 18:25:08 -07:00
Daniela Engert
70e67ae018 Re-enable module testing
Prepare for compilation with gcc (modules branch).
2021-06-01 14:49:56 -07:00
Victor Zverovich
ff37e41625 wchar.h -> xchar.h because it handles other code unit types too 2021-05-29 09:37:17 -07:00
Daniela Engert
b99c2bd345 Remove deprecated locale.h from module interface unit 2021-05-23 06:17:25 -07:00
Victor Zverovich
34b8acaef7 More wchar_t-specific API to wchar.h 2021-05-21 18:24:39 -07:00
Daniela Engert
6e2e6b796f Restore support for wchar_t overloads in module 2021-05-20 10:03:58 -07:00
Victor Zverovich
61b4c923d7 Reduce code bloat 2021-05-20 05:51:45 -07:00