Victor Zverovich
a6e871e39b
Don't pull in locale dependency
2025-12-04 06:28:37 -08:00
Watal M. Iwasaki
e137db699a
Fix doc CSS to display white-space properly ( #4622 )
...
See fmtlib/fmt.dev#25
2025-12-03 11:35:04 -08:00
dependabot[bot]
d6712ff2c0
Bump actions/checkout from 5.0.0 to 6.0.0 ( #4621 )
...
Bumps [actions/checkout](https://github.com/actions/checkout ) from 5.0.0 to 6.0.0.
- [Release notes](https://github.com/actions/checkout/releases )
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md )
- [Commits](08c6903cd8...1af3b93b68 )
---
updated-dependencies:
- dependency-name: actions/checkout
dependency-version: 6.0.0
dependency-type: direct:production
update-type: version-update:semver-major
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-12-01 09:04:20 -08:00
Victor Zverovich
2d839bbc61
Fix format_to_n
2025-11-30 07:12:48 -08:00
Victor Zverovich
5bc56e24a9
Update clang-format to version 21
2025-11-28 20:05:18 -08:00
bigmoonbit
2727215c11
chore: minor improvement for docs ( #4616 )
...
Signed-off-by: bigmoonbit <bigmoonbit@outlook.com>
2025-11-28 12:55:25 -08:00
Victor Zverovich
790b9389ae
Update README for clarity on performance comparison
2025-11-23 11:15:23 -08:00
Victor Zverovich
a731c73fd5
Make FMT_USE_FULL_CACHE_DRAGONBOX depend on __OPTIMIZE_SIZE__ by default
...
Thanks to Matthias Kretz for the idea.
2025-11-23 09:03:02 -08:00
Victor Zverovich
3391f9e992
Cleanup test
2025-11-22 19:14:32 -08:00
friedkeenan
9f197b22ae
Make FMT_STRING redundant when FMT_USE_CONSTEVAL is enabled ( #4612 )
2025-11-22 14:36:29 -08:00
Victor Zverovich
f20b16617e
Fix formatting
2025-11-22 13:48:03 -08:00
Victor Zverovich
14451704d5
Opt out std::complex from tuple formatting
2025-11-22 08:23:11 -08:00
Victor Zverovich
7a0da1c68a
Merge compile-time FP tests into other compile-time tests
2025-11-22 07:46:38 -08:00
Victor Zverovich
e3d2174b3c
Remove more invalid tests
2025-11-22 07:30:11 -08:00
Victor Zverovich
a6fb4d3b06
Remove invalid tests
2025-11-22 07:00:06 -08:00
Victor Zverovich
706fecea30
Apply clang-format
2025-11-22 06:45:50 -08:00
Victor Zverovich
e00fd756cc
Update link
2025-11-19 06:58:44 -08:00
Victor Zverovich
fc17e825d9
Remove the broken fmt::say function
2025-11-12 11:06:01 -08:00
Victor Zverovich
3fccfb8a80
Update benchmark table formatting in README
2025-11-07 10:05:56 -08:00
Victor Zverovich
690c9c71a0
Update benchmark results
2025-11-06 17:25:24 -08:00
Victor Zverovich
1122268510
Make path formatting lossless with WTF-8
2025-11-05 10:59:06 -10:00
Victor Zverovich
a4c7e17133
Improve build speed, take 2
2025-11-04 10:19:39 -10:00
Victor Zverovich
bfd0129b91
Improve build speed
2025-11-04 09:33:18 -10:00
Victor Zverovich
62f57b2496
Fix the macOS build
2025-11-04 09:12:57 -10:00
Victor Zverovich
ef7a566413
Reduce bloat-test result in debug mode from ~200k to ~85k
2025-11-03 16:21:10 -10:00
Victor Zverovich
42840cb415
Update benchmark results
2025-11-03 16:50:43 -08:00
Victor Zverovich
5ac44cd128
Fix a warning
2025-11-03 13:39:29 -10:00
Victor Zverovich
23c13b3060
Handle ulink in docs
2025-11-03 13:14:48 -10:00
Victor Zverovich
29c46fb82d
Add support for more doxygen tags
2025-11-03 10:57:41 -10:00
Victor Zverovich
a0571f3f59
Document output_file
2025-11-03 10:11:31 -10:00
dependabot[bot]
a195dd6b37
Bump github/codeql-action from 3.30.5 to 4.31.2 ( #4599 )
...
Bumps [github/codeql-action](https://github.com/github/codeql-action ) from 3.30.5 to 4.31.2.
- [Release notes](https://github.com/github/codeql-action/releases )
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md )
- [Commits](3599b3baa1...0499de31b9 )
---
updated-dependencies:
- dependency-name: github/codeql-action
dependency-version: 4.31.2
dependency-type: direct:production
update-type: version-update:semver-major
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-11-03 08:53:27 -08:00
Victor Zverovich
33ad559eb8
Fix fuzzer
2025-11-02 07:52:16 -10:00
dependabot[bot]
b6cd356196
Bump actions/upload-artifact from 4.6.0 to 5.0.0 ( #4598 )
...
Bumps [actions/upload-artifact](https://github.com/actions/upload-artifact ) from 4.6.0 to 5.0.0.
- [Release notes](https://github.com/actions/upload-artifact/releases )
- [Commits](65c4c4a1dd...330a01c490 )
---
updated-dependencies:
- dependency-name: actions/upload-artifact
dependency-version: 5.0.0
dependency-type: direct:production
update-type: version-update:semver-major
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-11-01 09:39:15 -07:00
J. Berger
c3be070b7e
When using MSVC x86 to compile v12.0.0 or v12.1.0, conversions from __int64 to a 32bit unsigned int trigger warnings. ( #4594 )
...
This is a follow-up for PR #4572 .
2025-11-01 09:38:30 -07:00
Stéén
27bf8b47fe
Add FMT_CONSTEXPR to static_format_result members ( #4591 )
...
Co-authored-by: Robin Oger <roger@qcify.com>
2025-10-29 18:34:42 -07:00
Victor Zverovich
407c905e45
Update version
2025-10-29 07:40:27 -07:00
Victor Zverovich
f781d2b932
Update ChangeLog.md
2025-10-25 09:10:24 -07:00
Victor Zverovich
5987082c47
Bump version
2025-10-25 08:30:50 -07:00
Victor Zverovich
681c9e689b
Update changelog
2025-10-25 08:30:50 -07:00
Peter Hill
913507044b
Fix leaky diagnostic ignored pragma ( #4588 )
...
Ignoring the `-Wconversion` diagnostic in `make_format_args` was
leaking out of the header, resulting in that warning being ignored in
downstream code that includes `fmt/base.h`.
Instead, we should `push`/`pop` the diagnostics to ensure this is
cleaned up.
2025-10-25 08:28:24 -07:00
Victor Zverovich
ff357e9e4a
Remove extra whitespace
2025-10-25 08:10:57 -07:00
Victor Zverovich
728dfeab5b
Fix apidoc comment
2025-10-25 08:06:23 -07:00
Victor Zverovich
7adc922ebb
Update changelog
2025-10-25 08:02:24 -07:00
Victor Zverovich
70ed0ab82a
Update changelog
2025-10-25 07:51:29 -07:00
Victor Zverovich
b95fd6132b
Avoid an ABI break for clang
2025-10-25 07:17:41 -07:00
Victor Zverovich
7241bbb149
Update changelog
2025-10-22 15:32:15 -07:00
Victor Zverovich
c0ddbacfd3
Bump version
2025-10-22 15:32:15 -07:00
Victor Zverovich
9395ef5fcb
Don't include std::locale::collate value in the symbol
2025-10-22 13:48:13 -07:00
Victor Zverovich
9721d974fc
Workaround ABI compatibility between clang and gcc
2025-10-22 12:34:47 -07:00
Fatih BAKIR
d6bdb69c62
Move FMT_API from ostream class to members ( #4584 )
...
Putting FMT_API on the class definition propagates it to the base class
detail::buffer<char>'s members. However, MSVC not emit definitions for
inline members unless it sees the symbols as FMT_API when compiling.
This fix removes the FMT_API declaration from the class itself and marks
individual non-inline members as FMT_API to address the issue.
Fixes https://github.com/fmtlib/fmt/issues/4576
2025-10-20 07:49:23 -07:00
Victor Zverovich
08d38d6e78
Make error_code formatter debug-enabled
2025-10-19 10:35:45 -07:00
Victor Zverovich
a2289b8593
Fix the build
2025-10-19 10:30:42 -07:00
Victor Zverovich
e8da5ba275
Fix formatting
2025-10-19 10:22:39 -07:00
Victor Zverovich
e2aa06cd0a
Workaround ABI incompatibility between clang ang gcc
2025-10-19 08:40:13 -07:00
Vladislav Shchapov
85f6ecc7a0
Add format_as support for std::variant and std::expected formatters ( #4575 )
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2025-10-18 14:05:21 -07:00
Harry Denholm
378a5ab3c1
value-initialise the buffer array member of detail::ansi_color_escape so that it can be used in a constexpr context in MSVC; compiler rejects as non-constant due to 'uninitialized symbol' otherwise ( #4581 )
...
Co-authored-by: Harry Denholm <ishani@users.noreply.github.com>
2025-10-17 08:10:56 -07:00
John Zimmerman
656d14db8b
docs: format two unescaped printf references with backticks ( #4578 )
2025-10-16 11:27:51 -07:00
Justin Riddell
31bed1bb65
Fix module fmt::join<string_view> ( #4577 )
...
FMT_USE_STRING_VIEW define was incorrectly not being defined when using
modules, so there was no appropriate formatter specialization for
std::string_view
Fixes #4379
2025-10-16 11:25:19 -07:00
LiangHu
8eebb4334b
[fix] #4565 When using MSVC to compile v12.0.0, many compilation warn… ( #4572 )
2025-10-12 10:56:13 -07:00
Victor Zverovich
beefc1c14f
Tweak wording
2025-10-12 10:54:28 -07:00
Victor Zverovich
81fe170849
Update docs
2025-10-12 10:42:12 -07:00
Victor Zverovich
491dc16a6d
Cleanup docs
2025-10-12 10:33:05 -07:00
Victor Zverovich
41326207c7
Cleanup docs
2025-10-12 10:20:16 -07:00
Victor Zverovich
c4f70ab69e
Cleanup docs
2025-10-12 09:34:46 -07:00
Victor Zverovich
5e214f0c43
Cleanup docs
2025-10-12 09:24:58 -07:00
Victor Zverovich
1234bc312e
Apply clang-tidy
2025-10-11 07:58:17 -07:00
rohitsutreja
b77a751625
Revert std::malloc/std::free to global malloc/free ( #4569 ) ( #4570 )
2025-10-10 09:37:05 -07:00
rohitsutreja
8db24c0ea9
restore 'inline' for normalize_libcxx_inline_namespaces ( #4571 )
2025-10-10 07:49:53 -07:00
Fatih BAKIR
03c7e28965
write_demangled_name supports libc++ + clang-cl ( #4560 )
...
The current implementation assumes whenever we're on an FMT_MSC_VERSION
compiler, the standard library is MSVC's STL. However, with clang-cl we
have the possibility of using LLVM libc++ instead of MSVC STL. In that
scenario, the previous implementation produced the wrong demangled names
for RTTI types.
This patch detects the different combinations, and combines the existing
demangling implementations to produce the correct names and make all
tests pass on libc++ + clang-cl.
2025-10-08 12:23:57 -07:00
Victor Zverovich
47a18b2fe9
Minor cleanup
2025-10-07 13:52:59 -07:00
Peter Steneteg
eb44d87b52
docs: range formatter grammar fix ( #4567 )
2025-10-07 11:34:00 -07:00
Martin Valgur
b580360ab7
base.h: _BitInt is not available when Clang is used as a host compiler for NVCC ( #4564 )
2025-10-06 08:45:12 -07:00
Oleksandr Koval
486e7ba579
support std::optional holding cv-qualified types ( #4562 )
...
Fixes #4561
2025-10-03 04:40:44 -07:00
Victor Zverovich
27ea09836a
Error on unsafe uses of join
2025-10-02 16:24:22 -04:00
Victor Zverovich
b5b9317a3c
Warn about unsafe use of join
2025-10-02 12:35:07 -04:00
dependabot[bot]
d13e5d048d
Bump github/codeql-action from 3.29.7 to 3.30.5 ( #4558 )
...
Bumps [github/codeql-action](https://github.com/github/codeql-action ) from 3.29.7 to 3.30.5.
- [Release notes](https://github.com/github/codeql-action/releases )
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md )
- [Commits](51f77329af...3599b3baa1 )
---
updated-dependencies:
- dependency-name: github/codeql-action
dependency-version: 3.30.5
dependency-type: direct:production
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-10-02 06:08:07 -07:00
teruyamato0731
b9ac8b225d
style: Correct indentation in locale initialization ( #4557 )
2025-10-02 04:10:31 -07:00
teruyamato0731
4801f54e59
docs: Add compile-time options to API documentation ( #4551 )
2025-09-30 14:03:11 -07:00
Victor Zverovich
5f66e07cb0
Suppress an unused argument warning
2025-09-28 19:45:41 -04:00
Victor Zverovich
17be91c079
Fix a clang-tidy error
2025-09-26 08:28:51 -07:00
Victor Zverovich
dcea616535
Fix compilation with locale disabled in header-only mode
2025-09-26 07:48:43 -07:00
SnapperTT
a2fd48e039
Make FMT_USE_CONSTEVAL optional #4545 ( #4546 )
2025-09-24 11:00:41 -07:00
Nikita Tsarev
e28c371c0f
Fix ambiguous call to fprintf when compiling as a C++20 module ( #4548 )
2025-09-22 11:58:59 -07:00
Victor Zverovich
6b6cdd9405
Store size in a local variable while unchanged
2025-09-21 12:51:06 -07:00
Victor Zverovich
c5e55972ae
Minor improvements to mkdocs
2025-09-21 12:47:15 -07:00
Victor Zverovich
dc409ee86d
Explain mkdocs deploy invocation
2025-09-21 12:47:09 -07:00
Yuwei Zhao
4cce5f458d
Perf: Optimize function append in include/fmt/base.h ( #4541 )
2025-09-21 12:40:26 -07:00
Victor Zverovich
aa8a30838a
Fix mike invocation
2025-09-21 08:03:21 -07:00
CrackedMatter
b18ece7d71
Export is_compiled_string and operator""_cf ( #4544 )
2025-09-19 08:54:54 -07:00
Victor Zverovich
e424e3f2e6
Update version
2025-09-17 09:45:35 -07:00
Victor Zverovich
ddd20d57ec
Bump version
2025-09-17 09:14:47 -07:00
Victor Zverovich
594143e374
Fix formatting in ChangeLog benchmark section
...
Correct formatting of the benchmark table in ChangeLog.
2025-09-17 09:08:01 -07:00
Victor Zverovich
09005428ab
Fix formatting in ChangeLog.md
2025-09-17 09:05:36 -07:00
Victor Zverovich
aaefc029d1
Update changelog
2025-09-17 09:05:15 -07:00
Victor Zverovich
9fb9f17dac
Update changelog
2025-09-17 09:04:32 -07:00
Victor Zverovich
a3b3d7ed46
Simplify duration cast
2025-09-13 11:32:03 -07:00
Victor Zverovich
9aee518f3e
Update changelog
2025-09-13 10:51:11 -07:00
Victor Zverovich
83189189a1
Remove get_dynamic_spec
2025-09-13 10:38:50 -07:00
Victor Zverovich
9bb14ffc47
Remove deprecated APIs
2025-09-13 10:07:16 -07:00
Victor Zverovich
556c4177b6
Remove deprecated localtime
2025-09-13 09:41:24 -07:00
Victor Zverovich
bfdef8b15d
Remove deprecated functions
2025-09-13 09:25:53 -07:00
Victor Zverovich
e33c76a1c2
Update changelog
2025-09-13 08:17:13 -07:00
Victor Zverovich
f9face7147
Update changelog
2025-09-13 07:59:25 -07:00
Uilian Ries
36390db094
Add Conan instructions in getting-started page ( #4537 )
...
Signed-off-by: Uilian Ries <uilianries@gmail.com>
2025-09-10 11:04:48 -07:00
crueter
da97ba2914
[cmake] fix MASTER_PROJECT heuristic; only enable install if master project ( #4536 )
...
SOURCE vs CURRENT_SOURCE is unreliable. `DEFINED PROJECT_NAME` is a much more portable way of determination.
Also, installation shouldn't default to on if it is a subproject.
2025-09-10 11:01:25 -07:00
Victor Zverovich
79a5e93027
Update changelog
2025-09-10 10:59:23 -07:00
Fatih BAKIR
18e160eb4c
Add missing include for crtdbg.h ( #4534 )
...
This header uses _CRT_ASSERT, which is defined in crtdbg.h but does not
include it, causing a build error in format-test.cc
Fixes the issue by including the header
2025-09-08 09:37:43 -07:00
Victor Zverovich
53d006abfd
Update changelog
2025-09-07 09:20:53 -07:00
Victor Zverovich
63bef33999
Update changelog
2025-09-07 08:36:07 -07:00
Victor Zverovich
d7cbfef11c
Update changelog
2025-09-07 08:29:03 -07:00
Victor Zverovich
26b033e239
Update changelog
2025-09-07 07:54:59 -07:00
Victor Zverovich
609188cb92
Cleanup macro definitions
2025-09-07 07:44:49 -07:00
Victor Zverovich
84b9c00711
Update changelog
2025-09-07 07:44:11 -07:00
Marcel
9908d00037
Delete Bazel support ( #4530 )
2025-09-05 15:53:13 -07:00
Anas
0a94e06750
Combined emphases into a single escape sequence ( #4528 )
2025-09-05 09:50:56 -07:00
Victor Zverovich
053d262944
Add .clang-tidy
2025-09-03 11:05:49 -07:00
Victor Zverovich
e72e43af1c
Apply clang-tidy
2025-09-03 11:05:41 -07:00
Victor Chernyakin
80549a630e
Avoid repeated call to GetLastError in file::size ( #4522 )
2025-09-03 08:38:31 -07:00
dependabot[bot]
f17b9aa44c
Bump actions/checkout from 4.2.0 to 5.0.0 ( #4523 )
...
Bumps [actions/checkout](https://github.com/actions/checkout ) from 4.2.0 to 5.0.0.
- [Release notes](https://github.com/actions/checkout/releases )
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md )
- [Commits](d632683dd7...08c6903cd8 )
---
updated-dependencies:
- dependency-name: actions/checkout
dependency-version: 5.0.0
dependency-type: direct:production
update-type: version-update:semver-major
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-09-02 09:04:42 -07:00
Victor Zverovich
882702c219
Apply clang-tidy
2025-09-01 12:21:17 -07:00
Victor Zverovich
16d371b649
Apply clang-tidy
2025-09-01 12:00:35 -07:00
Victor Zverovich
619b3a5aa0
Suppress a false positive in clang-tidy
2025-09-01 11:42:00 -07:00
Victor Zverovich
79c7f8a70b
Apply clang-tidy
2025-09-01 10:49:49 -07:00
Victor Zverovich
20e0d6d8dd
Update docs
2025-09-01 10:15:54 -07:00
Victor Zverovich
8ba99c0f05
Update docs
2025-09-01 10:04:54 -07:00
Victor Zverovich
656228fbee
Update docs
2025-09-01 09:50:45 -07:00
Victor Zverovich
02fb76d69b
Add FMT_STATIC_FORMAT
2025-09-01 09:15:32 -07:00
Victor Zverovich
a57f196cad
Apply coding conventions
2025-09-01 07:24:08 -07:00
Victor Zverovich
a75e8af487
Update docs
2025-08-31 10:51:29 -07:00
Victor Zverovich
e129591f02
Update changelog
2025-08-31 10:24:40 -07:00
Victor Zverovich
13d4f8469e
Remove deprecated vformat_to
2025-08-31 10:02:36 -07:00
Victor Zverovich
e2f89e6d21
Remove deprecated aliases
2025-08-31 09:40:11 -07:00
Victor Zverovich
489fd7ca4b
Simplify locale handling
2025-08-31 09:33:43 -07:00
Victor Zverovich
69324379f2
Mark detail::assert_fail as deprecated
2025-08-31 08:11:57 -07:00
Björn Schäpers
ff1caa58c9
Use FMT_THROW in report_error ( #4521 )
...
With exceptions: No change (if FMT_THROW is not user provided)
Without exceptions: Now also states where it comes from (report_error)
and uses fprintf instead of fputs.
My motivation is, now that I have my own fmt::assert_failed, also to get
rid of fputs for my embedded build.
2025-08-31 08:05:54 -07:00
Björn Schäpers
e181e94140
Add FMT_CUSTOM_ASSERT_FAIL ( #4505 )
...
That way one can provide ones own implementation for assert_fail, which
is moved out of the detail namespace. For binary compatibility the
detail version stays to call the outer version.
2025-08-25 09:02:00 -07:00
Victor Zverovich
43c88d00ae
Update changelog
2025-08-24 10:08:53 -07:00
Victor Zverovich
33a7d55c9b
Update changelog
2025-08-24 10:04:00 -07:00
Victor Zverovich
8e4676e4a5
Remove deprecated template parameter
2025-08-24 09:52:17 -07:00
Victor Zverovich
b5c4d25cd1
Rename is_char to is_code_unit
2025-08-24 09:30:50 -07:00
Victor Zverovich
a77efa4b4a
Move is_*char to detail
2025-08-24 09:16:18 -07:00
Victor Zverovich
e7e71009c7
Make FP formatting compatible with exotic chars
2025-08-24 08:49:54 -07:00
Victor Zverovich
b7b261977e
Simplify report_error
2025-08-24 08:30:17 -07:00
Victor Zverovich
61e0503daf
Merge workarounds for bogus MSVC warnings
2025-08-24 08:18:47 -07:00
Victor Zverovich
72c82296d6
Put FMT_END_* together
2025-08-17 12:25:40 -07:00
Victor Zverovich
a402614e8c
Remove deprecated aliases
2025-08-17 11:52:00 -07:00
Victor Zverovich
e719c43cc6
Apply coding conventions
2025-08-17 10:59:16 -07:00
Victor Zverovich
8a8ff6177c
Remove deprecated and undocumented has_formatter
2025-08-17 10:52:45 -07:00
Victor Zverovich
5b99b334f0
Remove redundant else
2025-08-17 10:03:01 -07:00
Mattias Ljungström
9588458917
Silence unreachable code warnings in MSVC when FMT_USE_EXCEPTIONS are disabled. ( #4515 )
2025-08-17 09:35:28 -07:00
Victor Zverovich
f91dc80f4c
Minor cleanup
2025-08-16 14:49:26 -07:00
Victor Zverovich
4120581167
Minor cleanup
2025-08-16 14:20:06 -07:00
Victor Zverovich
7ffc3ca15b
Minor cleanup
2025-08-16 12:20:02 -07:00
Victor Zverovich
e9ddc97b9a
Remove unnecesary constexpr and inline more
2025-08-10 08:40:35 -07:00
Murat Toprak
0d145936ec
Handle allocator propagation in basic_memory_buffer::move, Fix #4487 ( #4490 )
...
* Handle allocator propagation in basic_memory_buffer::move
Update `basic_memory_buffer::move` to respect `propagate_on_container_move_assignment`allocator trait.
If the allocator should not propagate and differs from the target's allocator,
fallback to copying the buffer instead of transferring ownership.
This avoids potential allocator mismatch issues and ensures exception safety.
* Add test cases for the updated move ctor
- Added two test cases `move_ctor_inline_buffer_non_propagating` and `move_ctor_dynamic_buffer_non_propagating`
- Added `PropageteOnMove` template parameter to `allocator_ref` class to be compatible with the old test cases
- `allocator_ref` now implements `!=` and `==` operators
2025-08-09 08:14:15 -07:00
Victor Chernyakin
8f3a965186
Refactor ansi_color_escape to track size instead of using a null terminator ( #4511 )
2025-08-09 08:08:41 -07:00
Victor Chernyakin
ae8cb1e8e6
Ignore some more files in .gitignore ( #4512 )
2025-08-05 13:41:50 -07:00
Victor Zverovich
add164f6b3
Optimize the default FP formatting
2025-08-03 12:46:38 -07:00
Victor Zverovich
23059d558e
Fix exponent size computation
2025-08-03 10:00:24 -07:00
Victor Zverovich
505cc3d0c2
Simplify remove_trailing_zeros
2025-08-03 08:45:48 -07:00
Victor Zverovich
b8a502615d
Revert "Optimize the default FP formatting"
...
This reverts commit 93f03953af6b0268e1a29bb5b23d50f72b87a151.
2025-08-03 07:40:13 -07:00
dependabot[bot]
814f51eab6
Bump github/codeql-action from 3.28.16 to 3.29.5 ( #4510 )
...
Bumps [github/codeql-action](https://github.com/github/codeql-action ) from 3.28.16 to 3.29.5.
- [Release notes](https://github.com/github/codeql-action/releases )
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md )
- [Commits](28deaeda66...51f77329af )
---
updated-dependencies:
- dependency-name: github/codeql-action
dependency-version: 3.29.5
dependency-type: direct:production
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-01 11:52:42 -07:00
Victor Zverovich
93f03953af
Optimize the default FP formatting
2025-07-27 08:56:07 -07:00
Dominic Pöschko
35dcc58263
fix buffer overflow on all emphasis flags set ( #4498 )
2025-07-20 10:43:33 -07:00
Catherine
553ec11ec0
Make compatible with WASI ( #4497 )
...
WASI is a POSIX subset that doesn't have `dup`, `dup2`, or `pipe` system calls.
Fixes #4496 .
2025-07-14 15:51:04 -07:00
autoantwort
a0ecfe3e1c
msvc + ninja + modules: Fix build when consuming fmtlib while using a Ninja generator ( #4495 )
...
Co-authored-by: Leander Schulten <Leander.Schulten@tetys.de>
2025-07-13 10:28:00 -07:00
Victor Zverovich
127413ddaa
Add OpenSSF Best Practices badge
2025-07-12 07:12:18 -07:00
Victor Zverovich
7d29ebe4af
Minor cleanup
2025-07-12 07:09:38 -07:00
anonymous
20c8fdad06
Fix import std in clang++ ( #4488 )
...
fix module-compilation error when defined `FMT_IMPORT_STD`
2025-07-07 11:47:48 -07:00
Victor Zverovich
300ce75ca6
Handle invalid glibc FILE buffer
2025-07-06 11:17:16 -07:00
Victor Zverovich
513f978241
Cleanup os-test
2025-07-04 10:52:59 -07:00
Victor Zverovich
6a3b40524c
Use actual example code and move safe_fopen to os-test
2025-07-04 09:50:55 -07:00
Victor Chernyakin
2fa3e1a1bb
Fix interaction between debug presentation, precision, and width for strings ( #4478 )
2025-07-04 07:33:47 -07:00
dependabot[bot]
fc8d07cfe5
Bump msys2/setup-msys2 from 2.27.0 to 2.28.0 ( #4485 )
...
Bumps [msys2/setup-msys2](https://github.com/msys2/setup-msys2 ) from 2.27.0 to 2.28.0.
- [Release notes](https://github.com/msys2/setup-msys2/releases )
- [Changelog](https://github.com/msys2/setup-msys2/blob/main/CHANGELOG.md )
- [Commits](61f9e5e925...40677d36a5 )
---
updated-dependencies:
- dependency-name: msys2/setup-msys2
dependency-version: 2.28.0
dependency-type: direct:production
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-07-01 08:42:01 -07:00
Miuna
27c5aab349
Fix unwanted char promotion in decimal writer with wchar_t ( #4483 )
2025-07-01 07:03:57 -07:00
Victor Zverovich
bc0193535a
Update image
2025-06-29 07:50:09 -07:00
Miuna
353bd895a2
Add FMT_EXPORT on ranges.h customization points ( #4476 )
2025-06-24 10:30:44 -07:00
Tomek-Stolarczyk
953cffa701
Replace memset with constexpr fill_n in bigint::align ( #4471 )
...
Use fill_n in place of memset in bigint::align to respect constexpr.
2025-06-23 16:18:16 -07:00
Vladislav Shchapov
571c02d475
Add xchar support for std::byte formatter ( #4480 )
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2025-06-23 14:02:11 -07:00
Remy Jette
f4345467fc
Fix compilation on clang-21 / libc++-21 ( #4477 )
...
`<cstdlib>` was not being included, so malloc and free were only declared
via transitive includes. Some includes changed in the latest libc++-21
build which broke fmt.
Also changed `malloc`/`free` to `std::malloc` and `std::free`, as
putting those symbols in the global namespace is optional for the
implementation when including `<cstdlib>`.
2025-06-21 07:28:14 -07:00
Victor Chernyakin
1ef8348070
Properly constrain detail::copy optimization ( #4474 )
2025-06-21 06:59:35 -07:00
Sahil Sinha
a5dccffa56
Add double and float support to scan test
...
- Add double_type and float_type to scan_type enum
- Add double* and float* pointers to scan_arg union
- Add constructors for double and float scan arguments
- Add switch cases for double and float types in visit()
- Implement basic read() functions for floating-point parsing
This partially resolves the TODO comment 'more types' in scan.h by adding
support for the two most commonly needed floating-point types.
2025-06-21 06:57:20 -07:00
Victor Zverovich
4a149f513f
Test non-SSO constexpr string formatting
2025-06-20 07:10:12 -07:00
Victor Chernyakin
067bc479b4
Avoid redundant work when processing UTF-8 strings ( #4475 )
2025-06-20 06:39:06 -07:00
Victor Zverovich
730fd4d9a7
Remove redundant tests
2025-06-08 08:46:22 -07:00
Mikhail Svetkin
5860688d7e
Enable constexpr support for fmt::format (fmtlib#3403) ( #4456 )
2025-06-07 07:16:49 -07:00
Victor Zverovich
46be88bc1e
Cleanup FP formatting
2025-06-01 09:15:20 -07:00
Thomas Khyn
cc88914904
Export fmt::dynamic_format_arg_store in fmt module ( #4459 )
2025-06-01 08:50:14 -07:00
Victor Zverovich
fc0c76a075
Handle large precision
2025-06-01 08:49:41 -07:00
dependabot[bot]
6332a38529
Bump ossf/scorecard-action from 2.4.0 to 2.4.2 ( #4462 )
...
Bumps [ossf/scorecard-action](https://github.com/ossf/scorecard-action ) from 2.4.0 to 2.4.2.
- [Release notes](https://github.com/ossf/scorecard-action/releases )
- [Changelog](https://github.com/ossf/scorecard-action/blob/main/RELEASE.md )
- [Commits](62b2cac7ed...05b42c6244 )
---
updated-dependencies:
- dependency-name: ossf/scorecard-action
dependency-version: 2.4.2
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-06-01 08:48:36 -07:00
Victor Zverovich
02de29e003
Remove a reference to a compromised account
2025-05-30 18:24:56 -07:00
Victor Zverovich
6d51c78c1e
Cleanup FP formatting
2025-05-30 16:45:21 -07:00
Victor Zverovich
0f4e9d0bde
Cleanup FP formatting
2025-05-30 16:05:57 -07:00
Victor Zverovich
d9d50495ac
Optimize the default FP formatting
2025-05-30 13:45:04 -07:00
Victor Zverovich
befbc5fdb8
Fix ADL lookup for memory_buffer
2025-05-26 09:44:35 -07:00
Victor Zverovich
8aa1d6a9fb
Minor cleanup
2025-05-25 10:14:24 -07:00
Nikhil
6d79757a38
Interpret precision as display width ( #4443 )
2025-05-25 08:42:47 -07:00
Victor Zverovich
1ff0b7f5e1
Cleanup warning suppression
2025-05-24 09:37:01 -07:00
Edoardo Morandi
ea985e84f8
Remove some implicit conversions ( #4447 )
...
* fix: avoid an implicit cast
The "1" used for the bitshift is treated as int, and this causes an
implicit conversion to `UInt` when performing the logical and.
Explicitly casting the number to `UInt` avoids the warning.
* fix: avoid implicit conversions for indices
Some indices in `include/fmt/base.h` are expressed as `int` types, which
causes an implicit conversion to a `size_t` when they are actually used
as index. Explicitly casting the value avoids the warning.
* fix: avoid an implicit conversion using size_t
The number of bits is used to express the size of a buffer. Using an
`int` causes an implicit conversion warning, let's use a `size_t` which
is the right type for the job.
2025-05-24 09:22:03 -07:00
Andreas Reischuck
f7033da09e
Avoid include locale inline if C++20 modules are enabled ( #4451 )
...
MSVC hints with:
```
fmt\include\fmt\format-inl.h(26): warning C5244: '#include <locale>' in the purview of module 'fmt' appears erroneous. Consider moving that directive before the module declaration, or replace the textual inclusion with 'import <locale>;'.
```
Then fails the build with `type redefinition`.
2025-05-21 17:18:18 -07:00
Tobias Schlüter
b723c021df
Give useful error when misusing fmt::ptr. ( #4453 )
...
static_assert(bla, "") prints an empty message but not the condition with at least MSVC. Add an informative message.
2025-05-20 12:21:06 -07:00
Victor Zverovich
3ba3c390fb
Clarify that formatting of pointers is disallowed
2025-05-17 10:16:58 -07:00
Kefu Chai
ab161a71c6
Fix some typos in comments ( #4448 )
...
- s/instantion/instantiation/
- s/uninitalized/uninitialized/
- s/costexpr/constexpr/
Signed-off-by: Kefu Chai <tchaikov@gmail.com>
2025-05-15 06:28:14 -07:00
Victor Chernyakin
b5266fd3b9
Remove some redundant consts ( #4445 )
...
`constexpr` variables are implicitly `const`.
2025-05-12 10:41:58 -07:00
Victor Zverovich
9b0ebd4435
Cleanup base-test
2025-05-11 15:42:08 -07:00
Victor Zverovich
7af94e5597
Remove old gcc workaround
2025-05-11 12:35:28 -07:00
Victor Zverovich
2924fcf8f6
Cleanup base-test
2025-05-11 10:36:42 -07:00
Victor Zverovich
102752ad45
Update docs
2025-05-11 09:13:12 -07:00
Victor Zverovich
a6cd72c9eb
Cleanup base-test
2025-05-11 09:01:28 -07:00
Victor Zverovich
07885271a1
Minor cleanup
2025-05-11 07:54:23 -07:00
Jeremy Rifkin
4999416e5c
Fix reference_wrapper ambiguity with format_as ( #4434 )
2025-05-10 11:15:45 -07:00
n-stein
55a8f6a4be
Change component prefix for NSIS compatibility ( #4442 )
2025-05-09 12:09:18 -07:00
Victor Zverovich
eb9a95d426
Clarify that formatting of pointers is disallowed
2025-05-05 10:55:59 -07:00
Victor Zverovich
d5c33e4f45
Make template parameter order consistent
2025-05-04 15:23:48 -07:00
Victor Zverovich
a2225f2887
Remove unused include
2025-05-04 15:16:38 -07:00
Victor Zverovich
b43b2f9537
Cleanup standard formatters
2025-05-04 13:04:06 -07:00
Victor Zverovich
1312b4a162
Cleanup standard formatters
2025-05-04 12:37:28 -07:00
Victor Zverovich
4404dc05dd
Consolidate implementation details
2025-05-04 10:48:47 -07:00
Victor Zverovich
7bb6fcb325
Bump version
2025-05-04 09:36:07 -07:00
Victor Zverovich
59259a5fde
Make a doc directory if it doesn't exist
2025-05-03 10:29:35 -07:00
Victor Zverovich
542ea7c40b
Clarify that Formatter parameter is deprecated
2025-05-03 10:28:46 -07:00
Victor Zverovich
40626af88b
Update version
2025-05-03 09:36:27 -07:00
Victor Zverovich
7fdd6846ba
Bump version
2025-05-03 09:02:35 -07:00
Victor Zverovich
6caff7ed9c
Cleanup test
2025-05-03 08:36:42 -07:00
Victor Zverovich
71a5483875
Update changelog
2025-05-03 07:29:31 -07:00
Victor Zverovich
448929d491
Update and apply clang-format
2025-05-03 07:29:31 -07:00
dependabot[bot]
26d87edab1
Bump github/codeql-action from 3.28.13 to 3.28.16 ( #4432 )
...
Bumps [github/codeql-action](https://github.com/github/codeql-action ) from 3.28.13 to 3.28.16.
- [Release notes](https://github.com/github/codeql-action/releases )
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md )
- [Commits](1b549b9259...28deaeda66 )
---
updated-dependencies:
- dependency-name: github/codeql-action
dependency-version: 3.28.16
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-05-03 06:59:36 -07:00
Victor Zverovich
505ee058f7
Update changelog
2025-04-27 11:57:40 -07:00
Victor Zverovich
ccab417195
Update changelog
2025-04-27 11:57:15 -07:00
Victor Zverovich
ec1349d348
Update changelog
2025-04-27 11:56:07 -07:00
Victor Zverovich
0ed2a65a8a
Clarify why we use __builtin_strlen instead of strlen
2025-04-27 11:08:27 -07:00
Victor Zverovich
e22c943070
Update changelog
2025-04-27 10:59:31 -07:00
Victor Zverovich
b252bad3c6
Update changelog
2025-04-27 10:29:56 -07:00
Victor Zverovich
2680831231
Cleanun string_view
2025-04-27 09:34:38 -07:00
Barry Revzin
8978ab09b2
Avoiding __builtin_strlen ( #4429 )
2025-04-27 09:32:10 -07:00
Victor Zverovich
c936e2e44e
Implement debug format for error_code
2025-04-27 09:06:17 -07:00
Victor Zverovich
a7d7b894cd
Implement the s specifier for error_code
2025-04-27 08:51:18 -07:00
Victor Zverovich
e98155a6fb
Remove redundant specializations
2025-04-26 10:41:03 -07:00
Victor Zverovich
41b3bed4d2
Clarify why we don't use qualified names
2025-04-26 10:12:06 -07:00
Victor Zverovich
67d9e49322
Update changelog
2025-04-26 09:15:47 -07:00
Victor Zverovich
9db5e4df22
Don't specialize std::is_floating_point
2025-04-26 08:17:05 -07:00
Victor Zverovich
906eaf2ddb
Make specifier order consistent
2025-04-25 12:10:21 -07:00
Victor Zverovich
9f6c12c3dc
Remove deprecated localtime from docs
2025-04-25 11:58:58 -07:00
rlalik
2d0518b5f7
Fix cmake error in pedantic mode ( #4426 )
...
Suppresses error:
CMake Error (dev) at build/coverage/_deps/fmt-src/CMakeLists.txt:208 (set):
uninitialized variable 'CMAKE_MODULE_PATH'
This error is for project developers. Use -Wno-error=dev to suppress it.
2025-04-24 11:41:33 -07:00
Victor Zverovich
c81cbed2b7
Simplify test
2025-04-23 12:32:26 -07:00
krzysztofkortas
c7925241c7
Remove core.h from README ( #4422 )
2025-04-21 11:27:40 -07:00
LocalSpook
c709138359
Add support for incomplete types
2025-04-20 10:16:11 -07:00
krzysztofkortas
db405954cd
Remove fmt/core.h from docs ( #4421 )
2025-04-20 07:40:18 -07:00
Victor Zverovich
0a917ee2f5
Minor comment tweak
2025-04-19 10:18:01 -07:00
Victor Zverovich
969d4aef60
Update doc image
2025-04-19 10:08:24 -07:00
Victor Zverovich
8061c7c8c4
Cleanup duration formatter
2025-04-19 10:08:24 -07:00
Victor Zverovich
7b59df4119
Remove redundant member
2025-04-19 10:08:23 -07:00
hirohira
b8192d233a
Fix build error with MSVC v141 ( #4413 )
2025-04-15 08:21:38 -07:00
Victor Zverovich
e814b5fabf
Reduce template parametrization
2025-04-13 10:17:17 -07:00
Victor Zverovich
ed0d216f7e
Fix localization and formatting of timezone names
2025-04-13 09:52:59 -07:00
Victor Zverovich
bd9554a29e
Fix formatting of timezone names
2025-04-13 08:52:26 -07:00
Victor Zverovich
f086dc0d27
Fix timezone handling in tm
2025-04-13 08:23:40 -07:00
Victor Zverovich
f10b6dd816
Improve chrono formatting
2025-04-12 09:59:06 -07:00
Victor Zverovich
f470b9c566
Cleanup chrono tests and set consistent TZ
2025-04-12 09:12:49 -07:00
Victor Zverovich
b28214487d
Fix handling of %Z
2025-04-12 08:51:22 -07:00
Victor Zverovich
6d69f0c5f2
Improve chorno tests
2025-04-12 08:24:49 -07:00
Victor Zverovich
da776c9a66
Test timezone
2025-04-12 07:53:58 -07:00
Mattes D
64db979e38
Added a missing FMT_STRING in fmt::println() ( #4407 )
2025-04-07 15:35:55 -07:00
Victor Zverovich
5f2e61fdd5
Cleanup chrono detail
2025-04-06 09:54:47 -07:00
Victor Zverovich
b3d45e1d3f
Remove fmt_detail
2025-04-06 09:24:20 -07:00
dependabot[bot]
5f6fb96df1
Bump github/codeql-action from 3.28.8 to 3.28.13 ( #4403 )
...
Bumps [github/codeql-action](https://github.com/github/codeql-action ) from 3.28.8 to 3.28.13.
- [Release notes](https://github.com/github/codeql-action/releases )
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md )
- [Commits](dd746615b3...1b549b9259 )
---
updated-dependencies:
- dependency-name: github/codeql-action
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-04-01 13:29:20 -07:00
Victor Zverovich
5199e0f885
Fix a flush issue on libstdc++
2025-03-30 10:54:14 -07:00
Victor Zverovich
2f58430573
Move buffering tests to os-test
2025-03-30 09:38:40 -07:00
Vertexwahn
d5d32c1e81
Bazel support: Update platforms to 0.0.11 ( #4400 )
2025-03-30 08:36:25 -07:00
Victor Zverovich
204661287b
Improve local_time test
2025-03-29 10:56:11 -07:00
Victor Zverovich
e1ab383361
Report an error when timezone is not available
2025-03-29 09:10:00 -07:00
Victor Zverovich
b9e0e94a01
Enable more chrono tests on Windows
2025-03-29 08:20:49 -07:00
Victor Zverovich
a81842428d
Update changelog
2025-03-29 08:14:25 -07:00
Victor Zverovich
f53055efe0
Revert "Workaround an ABI issue in spdlog"
...
This reverts commit 784eac839df77df1852dc1c50b17b76c3aec8f4a.
2025-03-29 07:48:20 -07:00
Victor Zverovich
b2dfcb2b80
Fix local_time test
2025-03-23 19:51:33 -07:00
Victor Zverovich
7ac97cbd1d
Enable some local_time tests and make them deterministic
2025-03-23 11:50:03 -07:00
Victor Zverovich
17898794a9
Use fmt::local_time
2025-03-23 11:18:14 -07:00
Victor Zverovich
443a8ef342
Deprecate fmt::localtime
2025-03-23 10:46:02 -07:00
Victor Zverovich
3607e92dc9
Bump version
2025-03-23 10:44:46 -07:00
Victor Zverovich
43e31614cc
Test ambiguous time
2025-03-23 10:34:37 -07:00
Victor Zverovich
989826ce50
Update changelog
2025-03-22 08:03:54 -07:00
Victor Zverovich
9d6e24c64e
Fix handling of long with FMT_BUILTIN_TYPES=0
2025-03-22 07:52:54 -07:00
Victor Zverovich
0843317e08
Update changelog
2025-03-22 07:25:46 -07:00
Victor Zverovich
784eac839d
Workaround an ABI issue in spdlog
2025-03-22 07:01:45 -07:00
Victor Zverovich
6fdf225a32
Always inline value ctors in optimized gcc mode only
...
This reverts commit 332da79bf37d06bb549810fd9420fd47407ebd89.
2025-03-16 10:03:53 -07:00
Victor Zverovich
332da79bf3
Always inline value ctors
2025-03-16 09:31:52 -07:00
Victor Zverovich
7b273fbb54
Minor cleanup
2025-03-16 08:58:44 -07:00
Victor Zverovich
191c504b10
Cleanup build config
2025-03-16 08:24:31 -07:00
Victor Zverovich
d13fb6092f
Cleanup build config
2025-03-15 12:45:36 -07:00
Victor Zverovich
dd780fde44
Add clang-3.4
2025-03-15 12:22:10 -07:00
Dean Glazeski
37e6474718
Fix dynamic named arg format spec handling ( #4361 )
...
When dealing with dynamic named format args, need to account for
nested named args when skipping the content of the replacement.
Fixes #4360
2025-03-15 09:34:11 -07:00
Victor Zverovich
77c0fc07d9
Switch to supported ubuntu image
2025-03-09 17:43:29 -07:00
Victor Zverovich
9212ff6ca1
Apply coding conventions and use constexpr
2025-03-02 09:03:06 -08:00
Dean Glazeski
864bdf9638
Report error on duplicate named arg names ( #4367 )
2025-03-02 07:47:03 -08:00
Victor Chernyakin
b776cf66fc
Optimize text_style using bit packing ( #4363 )
2025-03-01 11:18:19 -08:00
dependabot[bot]
bdbf957b9a
Bump msys2/setup-msys2 from 2.25.0 to 2.27.0
...
Bumps [msys2/setup-msys2](https://github.com/msys2/setup-msys2 ) from 2.25.0 to 2.27.0.
- [Release notes](https://github.com/msys2/setup-msys2/releases )
- [Changelog](https://github.com/msys2/setup-msys2/blob/main/CHANGELOG.md )
- [Commits](c52d1fa9c7...61f9e5e925 )
---
updated-dependencies:
- dependency-name: msys2/setup-msys2
dependency-type: direct:production
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com>
2025-03-01 07:56:45 -08:00
Thomas Khyn
577fd3be88
Fix TU-local entity exposition error in GCC 15
2025-02-26 11:14:15 -08:00
Thomas Khyn
faac8b1fa9
Remove exports in std.h
...
This fixes 'declaration of partial specialization in unbraced export-declaration' errors in GCC 15
2025-02-26 11:14:15 -08:00
Victor Zverovich
123913715a
Update version
2025-02-26 10:14:28 -08:00
Victor Zverovich
8c1059b92e
Update changelog
2025-02-25 17:32:17 -08:00
Victor Zverovich
4e5aafbf43
Bump version
2025-02-25 17:20:47 -08:00
Victor Zverovich
db30fb3b81
Update changelog
2025-02-25 17:20:29 -08:00
Victor Zverovich
3401ce2be2
Fix ABI compatibility
2025-02-25 13:32:24 -08:00
Dean
7f7695524a
Fix conflict with std::ignore ( #4356 )
...
In situations where `using namespace std;` is used, compiler warnings
can be generated because of local variables named `ignore`. This renames
those variables to something else to address the name conflict.
2025-02-19 23:08:21 -08:00
Dean
251320fcb7
Add .vs folder to .gitignore ( #4355 )
...
Opening the fmt folder as a CMake project with Visual Studio creates
this directory. The contents can be ignored.
2025-02-19 22:44:31 -08:00
Victor Chernyakin
94ab51cb8c
Simplify implementation of operator""_cf ( #4349 )
2025-02-14 02:02:09 -08:00
Victor Zverovich
0ca42e836e
Workaround an MSVC v140 bug
2025-02-13 14:12:16 +01:00
Thomas Khyn
ed27df5760
Replace forward slashes by backslashes in BMI path for MSVC. ( #4344 )
...
* Fix slashes in BMI path for MSVC builds
* Fix BMI path for MSVC builds when building with Ninja generator
2025-02-10 00:18:33 -08:00
Victor Zverovich
d42a068dbd
Apply coding conventions
2025-02-05 11:06:45 -08:00
Markus Kitsinger
f2cec917da
Move is_compiled_string to public API ( #4342 )
2025-02-04 16:20:27 -08:00
Sergiu Deitsch
d5b866e242
fix gcc 8.3 compile errors ( #4336 )
2025-02-03 08:51:58 -08:00
dependabot[bot]
5676e408f5
Bump github/codeql-action from 3.27.0 to 3.28.8 ( #4337 )
...
Bumps [github/codeql-action](https://github.com/github/codeql-action ) from 3.27.0 to 3.28.8.
- [Release notes](https://github.com/github/codeql-action/releases )
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md )
- [Commits](662472033e...dd746615b3 )
---
updated-dependencies:
- dependency-name: github/codeql-action
dependency-type: direct:production
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-02-01 12:08:34 -08:00
dependabot[bot]
71d24b564d
Bump actions/upload-artifact from 4.4.0 to 4.6.0 ( #4339 )
...
Bumps [actions/upload-artifact](https://github.com/actions/upload-artifact ) from 4.4.0 to 4.6.0.
- [Release notes](https://github.com/actions/upload-artifact/releases )
- [Commits](50769540e7...65c4c4a1dd )
---
updated-dependencies:
- dependency-name: actions/upload-artifact
dependency-type: direct:production
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-02-01 11:30:13 -08:00
LocalSpook
c9267da4df
Fix typo in FMT_HAS_BUILTIN check
2025-01-31 08:42:19 -08:00
Victor Zverovich
373855c1b0
Clarify difference in FP representation
2025-01-26 13:49:54 -08:00
Victor Zverovich
52eeeb52a6
Make exponent threshold depend on representation ( #3649 )
2025-01-26 12:10:48 -08:00
Victor Zverovich
9cf9f38ede
Update version
2025-01-25 10:08:57 -08:00
Victor Zverovich
4946bdb729
Update changelog
2025-01-25 08:53:02 -08:00
Rafał Lalik
01a5b56f0d
Fix error of unitialized variable FMT_HEADERS
...
This happens when using e.g. pedantic mode in cmake-init.
2025-01-25 08:41:49 -08:00
timsong-cpp
cb6fdf2191
Restore constraint on map formatter ( #4326 )
...
* Restore constraint on map formatter
* Remove unnecessary double parens
2025-01-25 08:31:07 -08:00
timsong-cpp
f841ae61e2
Fix #4303 : avoid instantiating formatter<const T> ( #4325 )
2025-01-24 10:53:10 -08:00
Matt
a3d05d70ce
Silence a constexpr warning when compiling with MSVC and /W4 ( #4322 )
2025-01-23 12:11:23 -08:00
Victor Zverovich
41539c29f3
Workaround a bug in gcc 6 ( #4318 )
2025-01-22 11:12:41 -08:00
Victor Zverovich
aabe63910c
Tweak changelog
2025-01-20 09:33:33 -08:00
Victor Zverovich
f90090be2c
Update changelog
2025-01-19 10:00:40 -08:00
Victor Zverovich
9ff9c695db
Bump version
2025-01-18 10:28:46 -08:00
Victor Zverovich
06ad1224eb
Update changelog
2025-01-18 10:05:40 -08:00
Victor Zverovich
5f0572acdc
Workaround a compilation error on gcc 9.4
2025-01-18 09:01:00 -08:00
Vladislav Shchapov
898d438571
Fix formatting into std::ostreambuf_iterator using a compiled format ( #4312 )
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2025-01-18 07:16:06 -08:00
Aaron Bishop
937b7c5c10
Add args() accessor back to fmt::format_context ( #4310 )
...
Add args() accessor back to fmt::format_context
Add test that would fail to compile if you can't create a fmt::format_context from another fmt::format_context
2025-01-17 10:28:34 -08:00
Victor Zverovich
01914f0389
Reduce size of basic_specs
2025-01-12 09:18:11 -08:00
Victor Zverovich
c43da35701
Workaround an ICE when using modules with gcc 14.2 and earlier
2025-01-12 08:57:43 -08:00
Victor Zverovich
8303d140a1
Update version
2025-01-12 08:15:44 -08:00
Victor Zverovich
b0b3dc5ff9
Bump version
2025-01-12 08:13:56 -08:00
Victor Zverovich
586ea06f02
Rename set_fill to copy_fill_from
2025-01-11 09:22:15 -08:00
Victor Zverovich
5750f434fa
Update changelog
2025-01-11 09:06:00 -08:00
Marcel Breyer
bfbdc2be9a
Add parameter to the fallback to_sys function.
2025-01-11 08:48:20 -08:00
Victor Zverovich
87e0072673
Update changelog
2025-01-11 07:21:28 -08:00
Victor Zverovich
d57040f949
Prefix components
2025-01-10 19:51:55 -08:00
Victor Zverovich
21aa0956d4
Restore ABI compatibility
2025-01-10 17:36:09 -08:00
Edoardo Lolletti
3f864a4505
Address MSVC C4127 warning when formatting non unicode tm ( #4299 )
...
Use `const_check` to silence visual studio's W4 level diagnostic regarding conditional expressions being constants, addresses https://github.com/fmtlib/fmt/issues/4294
2025-01-08 14:21:48 -08:00
Trim21
093b39ca5e
Update docs for meson ( #4291 )
2025-01-06 10:52:57 -08:00
Vladislav Shchapov
2c3a5698ef
Simplify a copying the fill from basic_specs
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2025-01-05 09:33:05 -08:00
Victor Zverovich
fc1b0f3486
Clarify use of FMT_THROW in a comment
2025-01-05 07:31:19 -10:00
GamesTrap
1d066890c7
Resolve C4702 unreachable code warnings
2025-01-03 16:39:11 -08:00
Vladislav Shchapov
dad3237514
Fix a bug when copying the fill from basic_specs
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2025-01-03 09:16:21 -08:00
Vladislav Shchapov
880e1494dc
Improve xchar support for std::bitset formatter
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2025-01-03 09:16:21 -08:00
Victor Zverovich
e3ddede6c4
Update version
2024-12-27 08:41:16 -08:00
Victor Zverovich
e9ec4fdc88
Bump version
2024-12-27 08:41:06 -08:00
Victor Zverovich
feb72126b4
Readd FMT_NO_UNIQUE_ADDRESS
2024-12-26 13:54:06 -08:00
Victor Zverovich
8d517e54c9
Update changelog
2024-12-26 13:50:13 -08:00
Victor Zverovich
563fc74ae4
Update changelog
2024-12-26 10:59:56 -08:00
Victor Zverovich
3e04222d53
Restore ABI compatibility with 11.0.2
2024-12-26 10:45:15 -08:00
Victor Zverovich
853df39d0a
Mention compile-time formatting
2024-12-26 09:48:10 -08:00
Victor Zverovich
11742a09c7
Clarify that format_string should be used instead of fstring
2024-12-26 09:39:01 -08:00
Victor Zverovich
da24fac101
Document fstring
2024-12-26 09:19:31 -08:00
Carl Smedstad
5fa4bdd758
Define CMake components to allow docs to be installed separately ( #4276 )
...
Define two components, core and doc, which can be installed separately.
This facilitates packagers who want to package docs in a separate
package.
After this change it's possible to install only core files with:
cmake --install build --component core
And only install documentation with:
cmake --install build --component doc
When no component is specified, the behaviour is unchanged, i.e. if
documentation was built, it will be installed.
2024-12-26 07:13:01 -08:00
Victor Zverovich
3c8aad8df7
Update the release script
2024-12-26 07:03:15 -08:00
Victor Zverovich
0e8aad961d
Update version
2024-12-25 08:46:43 -08:00
Victor Zverovich
debe784aab
Update changelog
2024-12-25 08:44:54 -08:00
Victor Zverovich
f6d1125676
Update changelog
2024-12-25 08:40:19 -08:00
Victor Zverovich
73d0d3f75d
Fix github API call
2024-12-25 08:27:59 -08:00
Victor Zverovich
08f60f1efc
Update changelog
2024-12-25 08:27:33 -08:00
Victor Zverovich
faf3f84085
Bump version
2024-12-25 08:18:51 -08:00
Victor Zverovich
f3a41441df
Replace requests with urllib
2024-12-25 08:16:09 -08:00
Victor Zverovich
3f33cb21d2
Update changelog
2024-12-25 07:54:45 -08:00
Victor Zverovich
b07a90386e
Update changelog
2024-12-25 07:52:52 -08:00
Victor Zverovich
a6fba51773
Update changelog
2024-12-25 07:49:56 -08:00
Victor Zverovich
25e2929988
Update changelog
2024-12-25 07:44:58 -08:00
Victor Zverovich
00ab2e98b5
Update changelog
2024-12-25 07:38:42 -08:00
Victor Zverovich
a3ef285aec
Always inline const_check to improve debug codegen in clang
2024-12-24 12:54:44 -08:00
Victor Zverovich
28d1abc9d2
Update changelog
2024-12-24 09:12:32 -08:00
Victor Zverovich
90704b9efd
Update changelog
2024-12-23 14:55:33 -08:00
YexuanXiao
86dae01c23
Fix compatibility with older versions of VS ( #4271 )
2024-12-23 07:26:11 -08:00
Victor Zverovich
d8a79eafdc
Document formatting of bit-fields and fields of packed structs
2024-12-21 11:06:11 -08:00
YexuanXiao
7c3d0152e5
Use the _MSVC_STL_UPDATE macro to detect STL ( #4267 )
2024-12-19 06:47:13 -08:00
Hannes Harnisch
7c50da5385
Allow getting size of dynamic format arg store ( #4270 )
2024-12-18 19:54:35 -08:00
Sascha Hestermann
873670ba3f
Make parameter basic_memory_buffer<char, SIZE>& buf of to_string const
2024-12-11 12:19:20 -08:00
Victor Zverovich
735d4cc05e
Update changelog
2024-12-11 12:17:40 -08:00
Vladislav Shchapov
141380172f
Allow disabling <filesystem> by define FMT_CPP_LIB_FILESYSTEM=0 ( #4259 )
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2024-12-09 07:13:24 -08:00
Victor Zverovich
4302d74293
Update changelog
2024-12-08 07:20:31 -08:00
Victor Zverovich
0f51ea79d3
Update changelog
2024-12-07 11:05:40 -08:00
Alex Hirsch
9600fee020
Include <filesystem> only if FMT_CPP_LIB_FILESYSTEM is set ( #4258 )
...
This change results out of necessity since the Nintendo Switch console
SDK does not support `std::filesystem`. The SDK still provides the
`<filesystem>` header, but with an `#error` directive, effectively
breaking any build that includes `<filesystem>`
Because `<filesystem>` is present, `FMT_HAS_INCLUDE` is insufficient
here. With this change and `FMT_CPP_LIB_FILESYSTEM` in place, one can
define `FMT_CPP_LIB_FILESYSTEM=0` to work around this issue.
This assumes that `<filesystem>` can be included (without warnings) if
`FMT_CPP_LIB_FILESYSTEM` is set. If this is not the case, fmt would be
broken even before this change as `std::filesystem::path` is used
without the accompanying header.
2024-12-07 06:45:54 -08:00
dependabot[bot]
47a66c5ecc
Bump msys2/setup-msys2 from 2.24.0 to 2.25.0 ( #4250 )
...
Bumps [msys2/setup-msys2](https://github.com/msys2/setup-msys2 ) from 2.24.0 to 2.25.0.
- [Release notes](https://github.com/msys2/setup-msys2/releases )
- [Changelog](https://github.com/msys2/setup-msys2/blob/main/CHANGELOG.md )
- [Commits](5df0ca6cbf...c52d1fa9c7 )
---
updated-dependencies:
- dependency-name: msys2/setup-msys2
dependency-type: direct:production
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-12-02 09:24:57 -08:00
jsirpoma
385c01dc7b
Allow bit_cast to work for 80bit long double ( #4246 )
2024-11-29 01:25:21 -08:00
Victor Zverovich
df249d8ad3
Remove an old workaround
2024-11-19 14:28:39 +01:00
Victor Zverovich
dfad80d1c5
Remove an old workaround
2024-11-19 14:22:44 +01:00
Justin Riddell
536cabd562
Export all range join overloads ( #4239 )
2024-11-15 13:01:59 -08:00
Victor Zverovich
b1a054706e
Remove more MSVC 2015 workarounds and fix string_view checks
2024-11-15 08:33:30 -08:00
Victor Zverovich
bfd95392c7
Remove MSVC 2015 workaround
2024-11-15 08:19:01 -08:00
Justin Riddell
9ced61bca4
Replace std::forward for clang-tidy ( #4236 )
...
Should fix #4231
2024-11-14 09:06:30 -08:00
Victor Zverovich
75e5be6adc
Sort specifiers
2024-11-13 13:01:13 -08:00
nikola-sh
a169d7fa46
Fix chrono formatting syntax doc ( #4235 )
2024-11-13 12:57:22 -08:00
Victor Zverovich
a6c45dfea8
Fix modular build
2024-11-10 09:06:50 -08:00
Victor Zverovich
a35389b3c2
Corrently handle buffer flush
2024-11-09 10:56:31 -08:00
Vladislav Shchapov
5a3576acc8
Implement fmt::join for tuple-like objects ( #4230 )
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2024-11-09 08:28:46 -08:00
Vladislav Shchapov
542600013f
Suppress MSVC warnings "C4127: conditional expression is constant" by used const_check ( #4233 )
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2024-11-09 07:43:46 -08:00
Victor Zverovich
720da57bab
Remove reference to unused intrinsic
2024-11-03 17:18:33 -08:00
Victor Zverovich
680db66c3a
Explicitly export symbols from detail
2024-11-03 09:13:17 -08:00
Victor Zverovich
56ce41ef63
Remove initializer_list dependency
2024-11-03 08:26:25 -08:00
Victor Zverovich
cf50e4d6a4
Fix const[expr] in context API
2024-11-03 07:25:52 -08:00
Victor Zverovich
6580d7b808
Cleanup the format API
2024-11-03 06:57:36 -08:00
Victor Zverovich
7e73566ce7
Minor cleanup
2024-11-02 11:24:24 -07:00
Victor Zverovich
8523dba2dc
Make constexpr precede explicit consistently
2024-11-02 11:03:03 -07:00
Victor Zverovich
e3d3b24fc1
Minor cleanup
2024-11-02 10:46:58 -07:00
Victor Zverovich
1521bba701
Use consistent types for argument count
2024-11-02 08:08:36 -07:00
dependabot[bot]
00649552a8
Bump github/codeql-action from 3.26.6 to 3.27.0 ( #4223 )
...
Bumps [github/codeql-action](https://github.com/github/codeql-action ) from 3.26.6 to 3.27.0.
- [Release notes](https://github.com/github/codeql-action/releases )
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md )
- [Commits](4dd16135b6...662472033e )
---
updated-dependencies:
- dependency-name: github/codeql-action
dependency-type: direct:production
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-11-01 09:13:46 -07:00
Victor Zverovich
4b8e2838f0
More cleanup
2024-10-27 10:56:52 -07:00
Victor Zverovich
7d4662f7ab
Remove FMT_BUILTIN_CTZ
2024-10-27 10:22:43 -07:00
Victor Zverovich
27110bc474
Minor cleanup
2024-10-27 09:44:25 -07:00
Sergey
68f3153762
Fix narrowing conversion warning in struct fstring ( #4210 )
...
Warning C4267: 'initializing': conversion from 'size_t' to 'const int', possible loss of data.
2024-10-27 06:41:20 -07:00
Vladislav Shchapov
168df9a064
Implement fmt::format_to into std::vector<char> ( #4211 )
...
* Implement fmt::format_to into std::vector<char>
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
* Move get_container to the trait
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
---------
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2024-10-26 09:23:59 -07:00
Sergey
4daa3d591f
Fix error: cannot use 'try' with exceptions disabled in Win LLVM Clang ( #4208 )
...
Fixes #4207 .
LLVM Clang on Windows does not define `__GNUC__`. The preprocessor falls
to `#elif FMT_MSC_VERSION && !_HAS_EXCEPTIONS` with `_HAS_EXCEPTIONS 1`
defined in vcruntime.h:104.
2024-10-23 10:43:55 -07:00
Victor Zverovich
e9eaa27e5a
Add std::exception to the docs
2024-10-20 09:42:29 -07:00
Victor Zverovich
2b6a786e35
Use standard context in print
2024-10-20 09:08:24 -07:00
Victor Zverovich
a16ff5787b
Add support for code units > 0xFFFF in fill
2024-10-20 07:59:58 -07:00
Victor Zverovich
601be1cbe7
Add support for code units > 0xFFFF in fill
2024-10-19 08:15:50 -07:00
Vinay Yadav
58c185b634
Changing type of data_ to size_t to avoid compilation warnings ( #4200 )
...
Changing type data_ to size_t because
1. If lib is cross-compiled for win32 using MXE environment it cause
compilation warning -Wconversion on line 730 as sizeof(unsigned long)
= 4 and sizeof(size_t) = 8
2. When lib is compiled on Unix like compiler generate warning
-Wuseless-cast if static_cast is used to fix issue in 1
2024-10-19 06:59:21 -07:00
Victor Zverovich
a0a9ba2afc
Fix hashes
2024-10-18 12:33:42 -07:00
Victor Zverovich
cc2ba8f9ed
Cleanup cifuzz action
2024-10-13 11:16:31 -07:00
Victor Zverovich
a18d42b208
Simplify lint ( #4197 )
2024-10-13 09:28:38 -07:00
Yi Kong
4046f97278
Fix -Wmissing-noreturn warning ( #4194 )
...
Fixes warning reported by top of trunk Clang:
include/fmt/chrono.h:447:36: error: function 'throw_duration_error' could be declared with attribute 'noreturn'
2024-10-10 08:59:56 -07:00
Victor Zverovich
6bdc12a199
detail_exported -> detail
2024-10-09 11:04:55 -07:00
Victor Zverovich
786a4b0968
Cleanup fixed_string
2024-10-09 08:42:49 -07:00
Victor Zverovich
2cb3b7c64b
Update README.md
2024-10-06 07:39:03 -07:00
Victor Zverovich
e9cba69057
Update README.md
2024-10-06 07:38:41 -07:00
Victor Zverovich
02537548f3
Cleanup an example
2024-10-04 17:15:07 -07:00
Victor Zverovich
c68c5fa7c7
Test FMT_BUILTIN_TYPES
2024-10-04 16:08:46 -07:00
Haowei
22701d5f63
Address build failures when using Tip-of-Tree clang. ( #4187 )
...
When using ToT clang to build fmtlib, it complains 'sv' is not
initialized by a constant expression. This patch addresses this
issue.
2024-10-04 06:45:29 -07:00
Casey Carter
e62c41ffb0
Conform std::iterator_traits<fmt::appender> to [iterator.traits]/1 ( #4185 )
...
* Conform `std::iterator_traits<fmt::appender>` to [iterator.traits]/1
> In addition, the types
> ```c++
> iterator_traits<I>::pointer
> iterator_traits<I>::reference
> ```
> shall be defined as the iterator’s pointer and reference types; that is, for an iterator object `a` of class type, the same type as `decltype(a.operator->())` and `decltype(*a)`, respectively. The type `iterator_traits<I>::pointer` shall be void for an iterator of class type `I` that does not support `operator->`. Additionally, in the case of an output iterator, the types
> ```c++
> iterator_traits<I>::value_type
> iterator_traits<I>::difference_type
> iterator_traits<I>::reference
> ```
> may be defined as `void`.
* Remove unnecessary member types from basic_appender
This reverts commit 1accf6c0a043fb445cbbfeefdbc1f91a08e3099f.
* Address clang-format issue
2024-10-03 09:05:14 -07:00
Francesco Cavaliere
18792893d8
Silencing Wextra-semi warning ( #4188 )
2024-10-03 09:00:55 -07:00
dependabot[bot]
c90bc91862
Bump actions/checkout from 4.1.6 to 4.2.0 ( #4182 )
...
Bumps [actions/checkout](https://github.com/actions/checkout ) from 4.1.6 to 4.2.0.
- [Release notes](https://github.com/actions/checkout/releases )
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md )
- [Commits](a5ac7e51b4...d632683dd7 )
---
updated-dependencies:
- dependency-name: actions/checkout
dependency-type: direct:production
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-10-01 13:39:00 -07:00
Victor Zverovich
c95722ad62
Improve naming consistency
2024-09-29 18:17:44 -07:00
Victor Zverovich
db06b0df87
Use countl_zero in bigint
2024-09-29 17:11:22 -07:00
Victor Zverovich
b9ec48d9ca
Cleanup bigint
2024-09-29 12:03:07 -07:00
Victor Zverovich
3faf6f181e
Add min_of/max_of
2024-09-29 10:24:39 -07:00
Victor Zverovich
d64b100a30
Relax constexpr
2024-09-29 10:04:57 -07:00
Victor Zverovich
ff9ee0461a
Fix handling FMT_BUILTIN_TYPES
2024-09-28 09:23:48 -07:00
Victor Zverovich
1c5883bef0
Test nondeterministic conversion to format string
2024-09-28 09:16:28 -07:00
Victor Zverovich
cacc3108c5
Don't assume repeated evaluation of string literal produce the same pointer
...
Patch by @zygoloid (#4177 ).
2024-09-28 08:09:33 -07:00
Justin Riddell
fade652ade
Require clang >=15 for _BitInt support ( #4176 )
...
For appleclang, fixes issue #4173
2024-09-26 16:10:51 -07:00
Cameron Angus
96dca569a1
Module linkage fixes for shared build ( #4169 )
...
* Mark some in-class defined member functions as explicitly inline/constexpr, to avoid missing external symbols when using fmt module with shared build due to modules not defaulting to implicit inline.
* Switch constexpr to inline for context::arg(string_view).
NOTE: Looks as if basic_format_args::get(string_view) could probably be made constexpr instead, but sticking with minimal change approach.
* Work around apparent non-conformance of older MSVC compilers.
* Switch format_int::str() from constexpr to inline to satisfy libstdc++ std::string constexpr limitations.
* Replace usages of macros for constexpr/inline with keywords.
* Fix for locations requiring C++14 constexpr.
* Further minor constexpr tweaks.
* Apply clang format
2024-09-26 07:53:55 -07:00
Victor Zverovich
891c9a73ae
Cleanup format API
2024-09-22 15:52:55 -07:00
Victor Zverovich
9282222b7d
Export more
2024-09-22 15:10:58 -07:00
Victor Zverovich
e5b20ff0d0
Deprecate detail::locale_ref
2024-09-22 10:44:38 -07:00
Victor Zverovich
ff92223549
Simplify locale handling
2024-09-22 10:21:19 -07:00
Victor Zverovich
80c4d42c66
Cleanup format.h
2024-09-22 08:20:26 -07:00
Victor Zverovich
3b70966df5
Add width and alignment support to error_code
2024-09-21 07:58:03 -07:00
Victor Zverovich
05226c4bd9
Remove type_identity
2024-09-20 19:13:09 -07:00
Victor Zverovich
c283b458a5
Cleanup format.h
2024-09-20 19:00:23 -07:00
Paulo Assis
fe79932c26
Fix conversion warning on chrono.h ( #4170 )
...
* Fix conversion warning on chrono.h
warning: conversion from 'time_t' {aka 'long long int'} to 'long int' may change value [-Wconversion]
* Changing write_utc_offset to accept a long long instead of the static_cast as requested..
2024-09-20 16:47:27 -07:00
Victor Zverovich
23fcf1942a
Apply clang-format
2024-09-20 09:34:10 -07:00
Victor Zverovich
3f296e3d4a
Workaround clang-format nonsense
2024-09-20 09:05:59 -07:00
Victor Zverovich
a197a994c5
Add member format_as for std
2024-09-20 08:49:49 -07:00
Victor Zverovich
6d43c755bc
Fix a typo
2024-09-19 10:49:11 -07:00
Vladislav Shchapov
1f87b1c58d
Use fmt::formatter specialization for std::reference_wrapper to avoid undefined behavior ( #4164 )
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2024-09-19 10:34:33 -07:00
Khanh H
ed8f8be70d
More chrono padding ( #4161 )
...
* Add padding modifier to day of year, duration's remains unpadded
* Add padding modifier for %m, %Y
2024-09-18 09:27:45 -07:00
Victor Zverovich
55a0a9cd62
Cleanup pragma detection
2024-09-17 19:46:30 -07:00
Victor Zverovich
5c926d9ff9
Remove FMT_UNCHECKED_ITERATOR
2024-09-17 19:40:29 -07:00
Victor Zverovich
8b024662d4
Remove unnecessary inheritance
2024-09-17 19:31:55 -07:00
Victor Zverovich
2f1424be90
Simplify handling of arrays
2024-09-17 19:05:43 -07:00
Victor Zverovich
239aa6911b
Remove unwrap_named_arg
2024-09-16 20:46:47 -07:00
Victor Zverovich
497df6db61
Remove formattable
2024-09-16 20:32:27 -07:00
Victor Zverovich
a25e594f6a
Remove range_mapper
2024-09-16 20:24:30 -07:00
Victor Zverovich
503dff93ec
Simplify has_formatter
2024-09-16 20:15:54 -07:00
Victor Zverovich
3374a95b50
Simplify has_formatter
2024-09-16 20:08:52 -07:00
Victor Zverovich
0e62e5dc7c
Simplify has_formatter
2024-09-16 19:53:31 -07:00
Victor Zverovich
7ce013971b
Sync value ctors and type mapper
2024-09-16 19:23:08 -07:00
Yedidya Feldblum
07e70151d5
format std::reference_wrapper
2024-09-16 19:05:18 -07:00
Victor Zverovich
4197727712
Improve handling of unformattable args
2024-09-16 18:52:18 -07:00
Victor Zverovich
527e98e3f8
Remove unformattable
2024-09-15 17:28:27 -07:00
Victor Zverovich
8a19b2db77
arg_mapper -> type_mapper
2024-09-15 17:09:49 -07:00
Victor Zverovich
e97df46ae1
Cleanup type mapping
2024-09-15 16:18:21 -07:00
Victor Zverovich
39f1e0903a
Remove FMT_MAP_API
2024-09-15 10:52:36 -07:00
Victor Zverovich
d832830f60
Cleanup type mapping
2024-09-15 09:58:09 -07:00
Victor Zverovich
b329ff194f
Always detect encoding on Windows
2024-09-15 08:52:33 -07:00
Victor Zverovich
2af403ce64
Simplify type mapping
2024-09-14 21:21:49 -07:00
Victor Zverovich
b7513b1d00
Simplify type mapping
2024-09-14 20:23:42 -07:00
Victor Zverovich
761d35f763
Cleanup format_as handling
2024-09-14 19:34:58 -07:00
Victor Zverovich
545dc4148a
Add value ctor taking name_arg
2024-09-14 10:33:15 -07:00
Victor Zverovich
3f5e45dd33
Simplify handling of _BitInt
2024-09-14 10:15:36 -07:00
Victor Zverovich
2e3b6fbd9f
Remove redundant check
2024-09-14 09:48:33 -07:00
Victor Zverovich
a0328e1f9f
Improve error reporting
2024-09-14 09:39:41 -07:00
Victor Zverovich
de28ef5f86
Remove make_arg
2024-09-14 09:18:47 -07:00
Victor Zverovich
2d5e561a6b
Cleanup argument handling
2024-09-14 08:56:04 -07:00
Victor Zverovich
6537fb439c
Update changelog
2024-09-14 08:14:22 -07:00
Victor Zverovich
50aac2ac92
Add reference to iterator_traits
2024-09-14 08:07:39 -07:00
Victor Zverovich
538d8777e5
Workaround a bug in libstdc++
2024-09-14 07:49:10 -07:00
Victor Zverovich
0335312320
Demacrify UTF-8 check
2024-09-13 18:41:10 -07:00
Victor Zverovich
463fe65f17
Cleanup FMT_COMPILE_STRING
2024-09-12 19:57:50 -07:00
Victor Zverovich
1782a6eac0
Rename pragma macros
2024-09-12 19:20:32 -07:00
Victor Zverovich
b52fb98846
Fix no locale build
2024-09-11 20:37:44 -07:00
Victor Zverovich
b6a6ec7f1c
FMT_EXCEPTIONS -> FMT_USE_EXCEPTIONS
2024-09-11 19:34:12 -07:00
Victor Zverovich
89999f1672
Simplify pragma
2024-09-11 18:52:56 -07:00
Victor Zverovich
b90b4bc981
Remove FMT_STATIC_THOUSANDS_SEPARATOR in favor of FMT_USE_LOCALE
2024-09-11 18:30:05 -07:00
Victor Zverovich
a1d6f9a973
Minor cleanup
2024-09-11 17:20:20 -07:00
Victor Zverovich
689ec7a087
Cleanup
2024-09-11 16:05:34 -07:00
Victor Zverovich
28143dc99d
Cleanup chrono
2024-09-11 15:41:51 -07:00
Victor Zverovich
1bde49e545
Remove FMT_USE_USER_LITERALS
2024-09-11 11:27:27 -07:00
Amin Yahyaabadi
f924d16e47
fix: pass /utf-8 only if the compiler is MSVC at build time
2024-09-11 08:21:07 -07:00
Victor Zverovich
ab8f9d5b08
Cleanup format API
2024-09-11 07:52:19 -07:00
Victor Zverovich
6f62db098a
Cleanup format API
2024-09-11 07:26:11 -07:00
Victor Zverovich
ab44ee7521
Avoid shadowing
2024-09-11 07:05:45 -07:00
Victor Zverovich
0d4e7e3fee
Remove old workaround
2024-09-11 06:17:47 -07:00
Victor Zverovich
8ee89546ff
Remove old workaround
2024-09-10 21:06:25 -07:00
Victor Zverovich
a5deb96bf5
Update gcc version
2024-09-10 20:52:35 -07:00
Victor Zverovich
61a241f03f
Cleanup
2024-09-10 20:24:57 -07:00
Victor Zverovich
ff82d8d2b5
Cleanup visit
2024-09-10 20:09:44 -07:00
Victor Zverovich
0cc20f5639
Remove iterator_t
2024-09-10 19:51:57 -07:00
Victor Zverovich
2ba6785d8f
Remove unused type
2024-09-10 19:00:08 -07:00
Victor Zverovich
5644e7507c
Remove unnecessary forwarding
2024-09-10 18:35:32 -07:00
Victor Zverovich
5345cfe6b3
Adjust clang-format
2024-09-10 18:24:35 -07:00
Victor Zverovich
3e9fdb3a1f
Cleanup
2024-09-10 17:27:49 -07:00
Victor Zverovich
3ada4aed20
Optionally exclude Unicode data
2024-09-08 16:52:01 -07:00
Victor Zverovich
b37be85bf1
Optionally disable named arguments
2024-09-08 16:25:33 -07:00
Victor Zverovich
70643b2511
Don't use format_error if exceptions disabled
2024-09-08 15:56:36 -07:00
Victor Zverovich
967e2d177d
Cleanup
2024-09-08 15:43:11 -07:00
Victor Zverovich
02c5d637c5
Cleanup
2024-09-08 11:13:44 -07:00
Victor Zverovich
047bf75c24
Cleanup
2024-09-08 10:00:25 -07:00
Victor Zverovich
2d3ba32e79
Improve debug codegen
2024-09-08 09:17:59 -07:00
Victor Zverovich
6c90b31fbd
Improve debug codegen
2024-09-08 07:49:02 -07:00
Victor Zverovich
9408c2ae8c
Readd support for FMT_BUILTIN_TYPES
2024-09-07 08:12:03 -07:00
Victor Zverovich
cc3ff1529d
Cleanup
2024-09-06 17:05:48 -07:00
Victor Zverovich
158893b384
Cleanup
2024-09-06 13:39:03 -07:00
Victor Zverovich
f5a16a484b
Cleanup
2024-09-06 12:41:53 -07:00
Victor Zverovich
cad876be4c
Switch to vargs
2024-09-06 12:12:39 -07:00
Victor Zverovich
debf6f8285
Switch to vargs
2024-09-06 09:10:39 -07:00
Victor Zverovich
35f4fab4c4
Simplify value ctor
2024-09-06 08:59:43 -07:00
Victor Zverovich
ff8f324786
Minor cleanup
2024-09-06 08:47:24 -07:00
Victor Zverovich
bd48715d81
Simplify make_format_args
2024-09-06 08:15:33 -07:00
Victor Zverovich
57d6df62f7
Simplify make_format_args
2024-09-06 08:07:22 -07:00
Victor Zverovich
8ed4a9dcc1
Improve debug codegen
2024-09-06 07:51:22 -07:00
Victor Zverovich
f288f45e46
Prepare for arg_store unification
2024-09-05 19:17:18 -07:00
Vladislav Shchapov
5bf577ca58
Backport from GoogleTest: "Work around a maybe-uninitialized warning under GCC 12" ( 0320f517fd)
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2024-09-05 09:40:55 -07:00
Vladislav Shchapov
b6de66819e
Backport from GoogleTest: "Always initialize fields in MatcherBase constructors" ( https://github.com/google/googletest/pull/3797 )
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2024-09-05 09:40:55 -07:00
Vladislav Shchapov
6870e4b06b
Workaround for GCC regression: false positive null-dereference in vector.resize
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2024-09-05 09:40:55 -07:00
Vladislav Shchapov
5cdef76034
Switch to gcc-13 for C++23 tests
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2024-09-05 09:40:55 -07:00
Victor Zverovich
a2c290bc34
Suppress a bogus MSVC warning
2024-09-04 17:20:30 -07:00
Victor Zverovich
f1e3016c13
Optimize debug codegen
2024-09-04 17:10:52 -07:00
Victor Zverovich
106dc8fd64
Reduce usage of type_identity
2024-09-04 16:23:51 -07:00
Victor Zverovich
c3344e21e2
Cleanup base API
2024-09-04 15:50:53 -07:00
Victor Zverovich
5f438c967e
Remove make_arg
2024-09-04 14:52:14 -07:00
Victor Zverovich
2a257798d4
Reenable FMT_BUILTIN_TYPES
2024-09-04 14:10:40 -07:00
Vladislav Shchapov
22d50c1a9c
Add support formatting std::expected<void, E>
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2024-09-04 12:31:44 -07:00
Vladislav Shchapov
1cc10ab68f
Make is_formattable work with const/volatile void
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2024-09-04 12:31:44 -07:00
Victor Zverovich
6aaf7f4b79
Suppress a gcc 13 warning
2024-09-04 11:43:12 -07:00
Victor Zverovich
b4d1d7f8e6
Improve debug codegen
2024-09-04 08:56:25 -07:00
Vladislav Shchapov
1e0771c70a
Fix broken CI for shared library on macos and linux ( #4151 )
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2024-09-04 08:53:50 -07:00
Victor Zverovich
3df47a4677
Make is_formattable work with void
2024-09-04 07:33:56 -07:00
Cameron Angus
b4aea98b55
Small fixes for some issues with modules builds ( #4152 )
...
* Avoid module export of member function definitions.
* Do not #include intrinsics header into module purview.
2024-09-04 07:29:41 -07:00
Victor Zverovich
565461a0d3
Update MSVC workaround in compile-test
2024-09-04 06:43:05 -07:00
Victor Zverovich
e2b7238707
Cleanup format string API
2024-09-03 21:30:57 -07:00
Victor Zverovich
1e0c6cdc3b
Make symbol sizes shorter
2024-09-03 20:44:37 -07:00
Victor Zverovich
a8bcf81f72
Minor cleanup
2024-09-03 18:39:46 -07:00
Victor Zverovich
15694c9a84
Workaround an MSVC bug
2024-09-03 16:12:29 -07:00
Victor Zverovich
4cae2da0d0
Workaround a clang 17 bug
2024-09-03 15:58:33 -07:00
Victor Zverovich
79e5ae919c
Fix locale tests on FreeBSD
2024-09-03 12:50:03 -07:00
Victor Zverovich
894b71da85
Fix handling of _BitInt
2024-09-03 11:32:31 -07:00
Victor Zverovich
7a6a2a79ed
Improve debug codegen
2024-09-02 20:29:24 -07:00
Victor Zverovich
387395fc7c
Cleanup base API
2024-09-02 15:15:38 -07:00
Victor Zverovich
6a88415499
Add FMT_APPLY_VARIADIC
2024-09-02 13:59:41 -07:00
Victor Zverovich
9a2aae37d4
Cleanup base API
2024-09-02 10:01:14 -07:00
Victor Zverovich
8803768363
Cleanup base API
2024-09-02 09:11:33 -07:00
Victor Zverovich
4fa533c70e
Cleanup base API
2024-09-02 09:00:44 -07:00
Victor Zverovich
d980dd7171
Cleanup base API
2024-09-02 07:50:46 -07:00
Victor Zverovich
4eed488c66
Cleanup base API
2024-09-02 07:17:21 -07:00
Victor Zverovich
a6ecd25b80
Improve debug codegen
2024-09-02 06:54:45 -07:00
Victor Zverovich
9f29345ea0
Simplify mapped_type_constant
2024-09-02 06:41:44 -07:00
Victor Zverovich
4986b4c0ef
Simplify arg_mapper
2024-09-01 21:59:39 -07:00
Victor Zverovich
a5f4d9820c
Simplify arg_mapper
2024-09-01 21:47:41 -07:00
Victor Zverovich
bc3af51272
Reduce the number of instantiations
2024-09-01 19:54:09 -07:00
Victor Zverovich
60740b7c24
Cleanup base API
2024-09-01 19:35:00 -07:00
Victor Zverovich
9ef160d309
Cleanup base API
2024-09-01 19:02:47 -07:00
Victor Zverovich
0b80978c27
Cleanup base API
2024-09-01 18:31:41 -07:00
Victor Zverovich
4f39d88650
Cleanup base API
2024-09-01 18:24:24 -07:00
Victor Zverovich
a86b1acf6a
Add mapped_t
2024-09-01 17:48:29 -07:00
Victor Zverovich
c9ef07bc4e
Minor cleanup
2024-09-01 17:34:47 -07:00
Victor Zverovich
8c4cfab57a
Detemplatize parse
2024-09-01 14:32:55 -07:00
Victor Zverovich
7e3aa6d982
Minor cleanup
2024-09-01 14:17:38 -07:00
Victor Zverovich
7c66216008
Minor cleanup
2024-09-01 12:53:09 -07:00
Victor Zverovich
1416edabbb
Cleanup base API
2024-09-01 12:06:40 -07:00
dependabot[bot]
d4aeca9922
Bump actions/upload-artifact from 4.3.3 to 4.4.0 ( #4141 )
...
Bumps [actions/upload-artifact](https://github.com/actions/upload-artifact ) from 4.3.3 to 4.4.0.
- [Release notes](https://github.com/actions/upload-artifact/releases )
- [Commits](65462800fd...50769540e7 )
---
updated-dependencies:
- dependency-name: actions/upload-artifact
dependency-type: direct:production
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-09-01 11:15:43 -07:00
dependabot[bot]
eee93ddffa
Bump github/codeql-action from 3.25.11 to 3.26.6 ( #4142 )
...
Bumps [github/codeql-action](https://github.com/github/codeql-action ) from 3.25.11 to 3.26.6.
- [Release notes](https://github.com/github/codeql-action/releases )
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md )
- [Commits](b611370bb5...4dd16135b6 )
---
updated-dependencies:
- dependency-name: github/codeql-action
dependency-type: direct:production
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-09-01 11:15:36 -07:00
Victor Zverovich
b310a0d48b
Simplify parse_format_string
2024-09-01 11:09:26 -07:00
Victor Zverovich
985c3399d1
Make map static
2024-09-01 09:18:47 -07:00
Victor Zverovich
4a55b0d5fd
Remove duplicate error in compile-time checks
2024-09-01 09:03:34 -07:00
Victor Zverovich
64a6c84592
basic_format_parse_context -> parse_context
2024-09-01 08:09:37 -07:00
Victor Zverovich
66920feeee
Improve compile-time checks
2024-09-01 07:49:35 -07:00
Victor Zverovich
f4dad85c3a
Improve handling of named arguments in compile-time checks
2024-09-01 07:07:14 -07:00
Victor Zverovich
db4becabed
Reduce template instantiations
2024-08-31 20:29:58 -07:00
Victor Zverovich
fec2cc7af1
Improve handling of named arguments
2024-08-31 19:55:04 -07:00
Victor Zverovich
621e9c17c5
Clarify why we have TYPE in native_formatter
2024-08-31 17:50:21 -07:00
Victor Zverovich
bca7040556
Simplify compile-time checks
2024-08-31 15:01:25 -07:00
Victor Zverovich
8c4b17fe64
Simplify compile-time checks
2024-08-31 14:49:59 -07:00
Victor Zverovich
516a2e2049
Cleanup FMT_STRING
2024-08-31 14:13:57 -07:00
Victor Zverovich
6797f0c39a
Cleanup compile-time checks
2024-08-31 11:26:27 -07:00
Victor Zverovich
db496b47c1
Remove old gcc hack
2024-08-31 09:22:49 -07:00
Victor Zverovich
8eda3c8e90
Cleanup compile-time check
2024-08-31 08:38:53 -07:00
Victor Zverovich
53316903e6
Move string_literal to format.h
2024-08-31 07:08:35 -07:00
Victor Zverovich
8a484ad577
Minor cleanup
2024-08-30 20:53:54 -07:00
Victor Zverovich
b446cc9e67
fwrite_fully -> fwrite_all
2024-08-30 18:43:56 -07:00
Victor Zverovich
0204dd359d
Fix _BitInt formatter
2024-08-30 18:30:20 -07:00
Victor Zverovich
d8876b7787
Minor cleanup
2024-08-30 16:17:07 -07:00
Victor Zverovich
c0fab5e2f7
Reject modernity, embrace tradition
2024-08-30 11:26:29 -07:00
Victor Zverovich
64313e915c
Move redundant initialization to compile time
2024-08-30 10:51:35 -07:00
Victor Zverovich
8e3da9da2c
Improve binary size
2024-08-30 10:27:03 -07:00
Victor Zverovich
2a2f73f7c1
Improve binary size
2024-08-29 19:16:54 -07:00
Victor Zverovich
6dd9194abd
Simplify format_to_result
2024-08-29 18:35:42 -07:00
Victor Zverovich
a017bba062
Minor cleanup
2024-08-29 18:22:09 -07:00
Victor Zverovich
5eb023cd56
Improve binary size
2024-08-29 17:31:30 -07:00
Victor Zverovich
f213d83306
Disable locale more
2024-08-29 16:35:15 -07:00
Victor Zverovich
b3ccc2d210
Disable locale more
2024-08-29 15:08:43 -07:00
Victor Zverovich
7477dda28d
Simplify is_utf8_enabled
2024-08-29 14:39:26 -07:00
Victor Zverovich
e582d377c2
Simplify locale handling
2024-08-29 14:19:33 -07:00
Victor Zverovich
cd8d01d8cd
Minor cleanup
2024-08-29 11:41:43 -07:00
Victor Zverovich
377cf203e3
Add opt out for built-in types
2024-08-29 11:21:29 -07:00
Justin Riddell
5a0a37340c
Add support for _BitInt on clang ( #4072 )
...
Issue #4007
Make _BitInt up to 128bits formattable
Note, libstdc++ is_signed doesn't work with _BitInt (so use own)
2024-08-28 18:57:52 -07:00
torsten48
bbf8b3bd01
insert else branch to avoid unreachable code warning ( #4130 )
...
at least MSC caused warning C4702: unreachable code
2024-08-28 16:43:12 -07:00
Justin Riddell
a3f3f2ec9a
Fix gcc 8.1 - 8.3 bug and compilation ( #4131 )
...
Fixes issue #4129
2024-08-28 11:25:39 -07:00
Maxwell
e3676ca309
Change std::copy to detail::copy in chrono to fix MSVC compile errors ( #4132 )
2024-08-28 08:25:40 -07:00
Victor Zverovich
0379bf3a5d
Workaround -Wstringop-overflow
2024-08-24 07:56:09 -07:00
Anthony VH
c59ee969f3
Improve compile-time formatting ( #4127 )
2024-08-21 12:02:47 -07:00
Victor Zverovich
1a79bbfa83
Cleanup chrono formatting
2024-08-18 12:17:45 -07:00
Victor Zverovich
89af1ad77d
Cleanup chrono formatting
2024-08-18 11:55:33 -07:00
Victor Zverovich
0e741e0daa
Minor cleanup
2024-08-18 10:35:01 -07:00
Victor Zverovich
d1acc667c1
Minor cleanup
2024-08-18 09:33:29 -07:00
Victor Zverovich
4fb7008c90
Cleanup duration cast
2024-08-18 08:33:26 -07:00
Victor Zverovich
589898e28b
Fix %S doc
2024-08-18 07:40:28 -07:00
Victor Zverovich
62382e3650
Test full exponent range
2024-08-18 06:47:04 -07:00
Victor Zverovich
94b8bc8eae
Add an experimental writer API
2024-08-17 09:54:09 -07:00
Victor Zverovich
020af729dd
Simplify ostream
2024-08-17 08:38:10 -07:00
cdzhan
fb07b37c5b
Prioritize using the header files of self ( #4116 )
2024-08-13 10:50:49 -07:00
Victor Zverovich
3135421257
Minor cleanup
2024-08-12 07:59:42 -07:00
Victor Zverovich
993f56cff6
Make sign a proper enum class
2024-08-11 13:49:57 -07:00
Victor Zverovich
c6c830e203
Make align a proper enum class
2024-08-11 11:07:18 -07:00
Victor Zverovich
b906c321f0
Get rid of bit fields
2024-08-11 10:28:09 -07:00
Victor Zverovich
f8c0c8ee78
Cleanup public API
2024-08-11 07:29:17 -07:00
Roberto Turrado Camblor
c71d03fcb0
Make support/python/mkdocstrings_handlers/cxx/__init__.py PEP 8 compliant (2 of 2) ( #4115 )
...
* Change indents to 4 spaces.
* Run isort.
* Remove one extra space on the left hand side of each assignment at p.communicate's input.
* Remove 'from __future__ import annotations'.
This requires changing a 'list[]' into a 'List[]'.
We had previously added this import because the code was making use of operator '|'.
But that is no longer true, so the import shouldn't be needed.
2024-08-11 07:24:50 -07:00
Victor Zverovich
50a8c3e9bf
Reduce format specs size
2024-08-10 09:34:35 -07:00
Victor Zverovich
98314319ad
Fix ambiguous overload
2024-08-09 15:01:40 -07:00
Victor Zverovich
0ce49aeb4a
Add a test case
2024-08-09 10:18:11 -07:00
Victor Zverovich
bf870ae3d1
Fix back_inserter lookup for non-std containers
2024-08-09 07:10:15 -07:00
Roberto Turrado Camblor
c98518351e
Make support/python/mkdocstrings_handlers/cxx/__init__.py PEP 8 compliant (1 of 2) ( #4110 )
...
* Make support/python/mkdocstrings_handlers/cxx/__init__.py PEP compliant.
* Rollback minor change in __init__ signature.
* Rollback minor change in __init__ signature.
* Fix previous commit.
* Add 'from __future__ import annotations' to fix Python 3.8 error when using operator '|'.
* Change doxyxml2html([n]) to doxyxml2html(list(n)) as suggested by Victor.
Change convert_type return type to Optional[str].
2024-08-08 15:22:41 -07:00
Hugo Sales
9f0c0c468b
Add 'n' specifier for tuple and pair ( #4107 )
2024-08-05 14:56:44 -07:00
Victor Zverovich
9f269062a7
Simplify default formatter
2024-08-05 14:24:07 -07:00
Victor Zverovich
15f939c3de
Improve handling of dynamic specs
2024-08-04 09:25:50 -07:00
Victor Zverovich
928a07bb04
Simplify handling of dynamic specs
2024-08-04 09:09:01 -07:00
Victor Zverovich
7891699737
Simplify handling of dynamic specs
2024-08-04 08:47:07 -07:00
Victor Zverovich
58aba5a3de
Deprecate append instantiation
2024-08-03 11:55:25 -07:00
Vladislav Shchapov
5ee14d3508
Reintroduce constexpr fmt::formatted_size for C++20 ( #4103 )
...
* Reintroduce constexpr fmt::formatted_size for C++20
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
* Disable constexpr fmt::formatted_size on Visual Studio 2019
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
---------
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2024-08-03 07:13:32 -07:00
Victor Zverovich
b9c0e4dd82
Improve spec parsing
2024-08-02 11:57:02 -07:00
Victor Zverovich
8445327c84
Simplify spec handling
2024-08-01 19:59:21 -07:00
Victor Zverovich
8a06cee826
Optimize shortest float formatting
2024-08-01 18:54:56 -07:00
Victor Zverovich
1db2274966
Use us if Unicode is disabled
2024-08-01 10:24:43 -07:00
dependabot[bot]
34ead4b39e
Bump msys2/setup-msys2 from 2.23.0 to 2.24.0 ( #4098 )
...
Bumps [msys2/setup-msys2](https://github.com/msys2/setup-msys2 ) from 2.23.0 to 2.24.0.
- [Release notes](https://github.com/msys2/setup-msys2/releases )
- [Changelog](https://github.com/msys2/setup-msys2/blob/main/CHANGELOG.md )
- [Commits](d0e80f58df...5df0ca6cbf )
---
updated-dependencies:
- dependency-name: msys2/setup-msys2
dependency-type: direct:production
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-08-01 08:32:46 -07:00
dependabot[bot]
3bf26009e4
Bump ossf/scorecard-action from 2.3.3 to 2.4.0 ( #4099 )
...
Bumps [ossf/scorecard-action](https://github.com/ossf/scorecard-action ) from 2.3.3 to 2.4.0.
- [Release notes](https://github.com/ossf/scorecard-action/releases )
- [Changelog](https://github.com/ossf/scorecard-action/blob/main/RELEASE.md )
- [Commits](dc50aa9510...62b2cac7ed )
---
updated-dependencies:
- dependency-name: ossf/scorecard-action
dependency-type: direct:production
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-08-01 08:32:20 -07:00
Vladislav Shchapov
d326c7298a
Fix conversion a surrogate pair ( #4095 )
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2024-07-30 07:27:11 -07:00
Victor Zverovich
6e462b89aa
Get rid of std::copy
2024-07-29 15:58:05 -07:00
Vladislav Shchapov
aff640c32f
Make fmt::appender implement std::output_iterator concept ( #4093 )
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2024-07-29 09:18:20 -07:00
Victor Zverovich
e23fb6a8b4
Apply clang-format
2024-07-29 08:20:58 -07:00
Victor Zverovich
16b3542f7e
Remove float_specs
2024-07-27 12:28:21 -07:00
Victor Zverovich
29d7e58059
Remove float_format
2024-07-27 12:07:19 -07:00
Victor Zverovich
919f7c5e7f
Reduce float_specs usage
2024-07-27 11:38:55 -07:00
Victor Zverovich
a80d668a52
Diagnose invalid precision
2024-07-27 10:41:54 -07:00
Victor Zverovich
707d7d923a
Apply coding conventions
2024-07-27 09:00:25 -07:00
Victor Zverovich
de6ed8df8b
Test alignment
2024-07-26 12:09:47 -07:00
Victor Zverovich
ffdc3fdbd9
Align digits table
2024-07-24 18:43:37 -07:00
Victor Zverovich
0c02813791
Fix doc build
2024-07-24 13:40:54 -07:00
Victor Zverovich
f8581bcecf
Add redirect page
2024-07-24 12:21:44 -07:00
Cameron Angus
31b3c325f6
Mark namespace scope constexpr variable 'buffer_size' inline. ( #4084 )
...
* Mark namespace scope constexpr variable 'buffer_size' inline.
* Use provided macro for inline variable.
2024-07-24 09:58:38 -07:00
Cameron Angus
52b32081f9
Wrap private module fragment content within conditional extern "C++", to match declarations. ( #4083 )
2024-07-24 06:25:23 -07:00
Victor Zverovich
0b0b09f401
Constrain format_uint
2024-07-23 06:30:35 -07:00
Victor Zverovich
4173a6315a
Improve format_decimal
2024-07-22 17:24:56 -07:00
Victor Zverovich
4239dfe081
Simplify format_decimal
2024-07-22 17:00:16 -07:00
Victor Zverovich
ba36a04811
Remove counting_iterator
2024-07-22 16:24:13 -07:00
Victor Zverovich
f6b4a23b83
Unbloat chrono
2024-07-22 15:46:58 -07:00
Victor Zverovich
42d3d703b5
Remove the commenting attempt
2024-07-22 13:48:56 -07:00
Victor Zverovich
9fcd9c4c12
Remove all warning suppressions
2024-07-22 12:41:12 -07:00
Victor Zverovich
7f157dca0a
Workaround gcc stringop-overflow bug
2024-07-22 11:31:35 -07:00
Victor Zverovich
524ca1c715
Improve parsing
2024-07-21 09:57:18 -07:00
Victor Zverovich
bdc45eef76
Simplify on_text
2024-07-21 08:31:03 -07:00
Victor Zverovich
439b6d7212
Reenable print optimization
2024-07-21 08:05:07 -07:00
Victor Zverovich
3cc32fdc8b
Mark more formatters nonlocking
2024-07-21 08:00:34 -07:00
Victor Zverovich
0c9fce2ffe
Update version
2024-07-20 07:17:38 -07:00
Victor Zverovich
b47d662e71
Update changelog
2024-07-20 07:14:03 -07:00
Victor Zverovich
e84297f255
Bump version
2024-07-20 07:00:12 -07:00
Victor Zverovich
0ad234ad13
Update changelog
2024-07-20 06:57:55 -07:00
Victor Zverovich
de684ef776
Make appender compatible with fill
2024-07-19 15:21:57 -07:00
Victor Zverovich
447c6cbf44
Update changelog
2024-07-19 13:38:27 -07:00
Victor Zverovich
bc8d32e964
Update changelog
2024-07-18 06:37:02 -07:00
Victor Zverovich
0f87d6ffa6
Improve sign processing
2024-07-17 16:13:27 -07:00
Victor Zverovich
808ea0191a
Cleanup test
2024-07-17 06:59:24 -07:00
Victor Zverovich
55e76e6c20
Update check-commits script
2024-07-17 06:58:37 -07:00
Victor Zverovich
8757f1f8d6
Add a script to test multiple commits
2024-07-16 06:27:01 -07:00
Victor Zverovich
9228f349a5
Inline visit
2024-07-14 15:34:53 -07:00
Victor Zverovich
e10643add2
Add a perf-sanity test
2024-07-14 14:17:39 -07:00
Victor Zverovich
f29a7e7970
Don't use memcpy in append
2024-07-14 13:02:21 -07:00
Victor Zverovich
f97deb0d7d
Minor cleanup
2024-07-14 11:14:49 -07:00
Victor Zverovich
3541353512
Apply minor optimization
2024-07-14 09:52:44 -07:00
Justin Riddell
5ef93a9f80
Expand FMT_FORMAT_AS to include implicit conversions ( #4055 )
...
Allows (for example) types convertible to std::string_view to inherit
from the fmt::formatter<fmt::string_view> to work etc.
2024-07-14 09:51:49 -07:00
Victor Zverovich
c9102619da
Avoid extra reserve
2024-07-14 08:41:35 -07:00
Victor Zverovich
58d792b6d3
Apply minor optimizations
2024-07-14 07:05:18 -07:00
Victor Zverovich
25adca5666
Remove redundant overload
2024-07-13 13:07:57 -07:00
Victor Zverovich
1408f1824d
Simplify iterator detection
2024-07-13 11:11:47 -07:00
Tor Shepherd
3fe4641d3a
Add 2 more constexprs to fix compile error ( #4065 )
2024-07-13 08:23:49 -07:00
Victor Zverovich
33e7ed1eb5
Improve handling of back_insert_iterator that writes into a buffer
2024-07-13 07:56:11 -07:00
zyctree
6a192f8d34
Fix broken links in README.md ( #4066 )
2024-07-12 11:21:35 -07:00
Victor Zverovich
92cdbbae06
Update api.md
2024-07-10 15:50:10 -07:00
Justin Riddell
13038f37e8
Support printing (const) volatile void* ( #4056 )
...
Fixes #4049
2024-07-10 08:35:06 -07:00
Victor Zverovich
6725225750
Update changelog
2024-07-09 13:22:56 -07:00
Justin Riddell
e60ff504ea
Fix usage with std::generator ( #4057 )
...
Fixes #4053
2024-07-09 08:46:34 -07:00
Victor Zverovich
ccea338070
Update lint.yml
2024-07-08 15:19:57 -07:00
Victor Zverovich
92227c77a4
Improve support for non-POSIX platforms more
2024-07-08 14:00:00 -07:00
Victor Zverovich
486838f26f
Improve support for non-POSIX platforms
2024-07-08 11:18:44 -07:00
Victor Zverovich
a43391199f
Update changelog
2024-07-07 10:05:03 -07:00
Victor Zverovich
7a8b54a0ef
Don't confuse Glib::ustring with std::string
2024-07-06 13:27:06 -07:00
Victor Zverovich
b50e685db9
Update version
2024-07-05 08:25:31 -07:00
Victor Zverovich
e314776c2e
Fix version check
2024-07-05 08:25:10 -07:00
Victor Zverovich
2208143acc
Update changelog
2024-07-05 08:20:52 -07:00
Vladislav Shchapov
a96259701e
Improve std::complex formatter ( #4050 )
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2024-07-04 17:24:01 -07:00
Victor Zverovich
232c6bc481
Update changelog
2024-07-04 08:02:45 -07:00
Victor Zverovich
503e183b9e
Bump version and add version validation
2024-07-04 07:49:58 -07:00
Victor Zverovich
e50c8b6bd8
Fix disabling Unicode support
2024-07-04 07:27:22 -07:00
toge
9d946a2fc4
Fix compilation errors due to make_format_args in gcc 14.1.1 with c++20 ( #4042 )
2024-07-03 12:41:08 -07:00
Nebojša Cvetković
c4f6fa7135
fix: Make basic_format_arg::visit() const ( #4043 )
2024-07-01 14:43:52 -07:00
dependabot[bot]
10f12fd3d2
Bump github/codeql-action from 3.25.3 to 3.25.11 ( #4041 )
...
Bumps [github/codeql-action](https://github.com/github/codeql-action ) from 3.25.3 to 3.25.11.
- [Release notes](https://github.com/github/codeql-action/releases )
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md )
- [Commits](d39d31e687...b611370bb5 )
---
updated-dependencies:
- dependency-name: github/codeql-action
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-07-01 12:16:55 -07:00
Vladislav Shchapov
24c1f886af
Remove double has_value check ( #4040 )
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2024-07-01 09:24:33 -07:00
Victor Zverovich
0041a40c13
Update version
2024-07-01 06:02:59 -07:00
Victor Zverovich
686339f7c1
Minor cleanup
2024-06-30 10:29:50 -07:00
Victor Zverovich
e355c116f9
Tweak wording in the changelog
2024-06-30 09:22:44 -07:00
Victor Zverovich
707bb5b369
Fix grammar
2024-06-30 08:54:56 -07:00
Victor Zverovich
6f68c62cb5
Ignore doxygen files
2024-06-30 08:42:34 -07:00
Victor Zverovich
d059fe42a8
Ignore vagrant files
2024-06-30 08:33:37 -07:00
Victor Zverovich
43c5b34749
Fix package build
2024-06-30 08:23:25 -07:00
Victor Zverovich
e89568e6cb
Update vagrant config
2024-06-30 07:56:35 -07:00
Victor Zverovich
f5bf6f7781
Update build script
2024-06-30 07:55:57 -07:00
Victor Zverovich
bd9af9a9f1
Update changelog
2024-06-30 07:49:55 -07:00
Victor Zverovich
1652108905
Fix typo
2024-06-29 09:38:40 -07:00
Victor Zverovich
84f6131825
Fix formatting of release notes
2024-06-29 09:36:35 -07:00
Victor Zverovich
dedc17c1c9
Fix handling of tables, take 3
2024-06-29 09:31:32 -07:00
Victor Zverovich
5d0adb6d74
Fix handling of tables, take 2
2024-06-29 09:29:06 -07:00
Victor Zverovich
3f251fc9c9
Fix handling of tables
2024-06-29 09:23:02 -07:00
Victor Zverovich
1930ed4bfa
Fix release script
2024-06-29 09:09:55 -07:00
Victor Zverovich
26d07e49b2
Fix formatting
2024-06-29 09:06:49 -07:00
Victor Zverovich
949d5d1795
Fix build script
2024-06-29 08:59:54 -07:00
Victor Zverovich
53186535d5
Bump version
2024-06-29 08:54:52 -07:00
Victor Zverovich
602e3c3d11
Update build script
2024-06-29 08:54:03 -07:00
Victor Zverovich
2952130cbc
Fix doc build
2024-06-29 08:50:16 -07:00
Victor Zverovich
1e94a463ed
Create build dir
2024-06-29 08:49:01 -07:00
Victor Zverovich
a34120329a
Update doc script
2024-06-29 08:38:16 -07:00
Victor Zverovich
0fae326c42
Update site dir
2024-06-29 08:32:24 -07:00
Victor Zverovich
8b1fcf5cc1
Update doc dir
2024-06-29 08:18:24 -07:00
Victor Zverovich
ec46c3de97
Update build script
2024-06-29 08:05:52 -07:00
Victor Zverovich
2d9d32c62b
Update build script
2024-06-29 07:25:35 -07:00
Victor Zverovich
4703ade76d
Update build script
2024-06-29 07:22:57 -07:00
Victor Zverovich
52e7b25f95
Update changelog
2024-06-29 07:07:39 -07:00
Vertexwahn
b61c8c3d23
Change actions/github-script from e69ef54 -> 60a0d83 ( #4038 )
...
* Change actions/github-script from e69ef54 -> 60a0d83
* Change google/oss-fuzz action from 32f1d4d to 9218255
2024-06-27 12:34:07 -07:00
Matthias Moulin
bbf44cc000
Defines are still needed for FMT_MODULE as well ( #4027 )
2024-06-24 07:11:35 -07:00
Victor Zverovich
06948fa710
Pin deps
2024-06-23 07:27:58 -07:00
Victor Zverovich
d9899492c1
Simplify deps
2024-06-23 07:22:45 -07:00
Victor Zverovich
ff72f553e3
Update changelog
2024-06-23 06:58:05 -07:00
Victor Zverovich
7f951f2502
Optimize range formatter
2024-06-23 06:51:46 -07:00
Dix Lorenz
7ae102bd66
make format_int constexpr ( #4032 )
...
* make format_int constexpr
* format_int can only be constexpr in C++20
* apply clang-format
* drop constexpr for str()
2024-06-23 06:28:39 -07:00
Victor Zverovich
edde973126
Update test names
2024-06-22 11:10:54 -07:00
Victor Zverovich
b1efe8516e
Prevent silent data loss
2024-06-22 07:46:16 -07:00
Matt Stafford
2c0d9e9409
Add a define to force the use of fallback_file
2024-06-21 09:42:02 -07:00
Victor Zverovich
18a9676d95
Add an experimental path
2024-06-21 08:14:20 -07:00
Matthias Moulin
af8cd4e404
Module purview can only contain direct preprocessor code ( #4029 )
...
Resolved MSVC Warning C5202: a global module fragment can only contain preprocessor directives
2024-06-19 13:00:29 -07:00
Vladislav Shchapov
514b6955d2
Suppress a bogus warning in MSVC ( #4023 )
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2024-06-19 08:49:43 -07:00
Matthias Moulin
ac96773230
Added missing std::declval for non-default-constructible types ( #4024 )
2024-06-18 11:27:40 -07:00
Victor Zverovich
c00149f5e2
Fix a typo
2024-06-17 06:58:33 -07:00
Victor Zverovich
71244e07de
Cleanup includes
2024-06-16 11:10:38 -07:00
Victor Zverovich
a57b0194a6
Correct comments
2024-06-16 11:05:38 -07:00
Victor Zverovich
febd8ed5fe
Cleanup includes
2024-06-16 10:59:06 -07:00
Victor Zverovich
0434026a95
Remove build-docs.py
2024-06-16 08:28:23 -07:00
Victor Zverovich
0882bfef2a
Don't deploy docs from a PR
2024-06-15 09:58:01 -07:00
Victor Zverovich
2a2048a785
Don't pass seconds as a double in examples
2024-06-15 09:26:49 -07:00
Victor Zverovich
ea1187f4c8
Generate doxyxml in build
2024-06-15 09:15:30 -07:00
Victor Zverovich
1334eedaf5
Improve docs
2024-06-15 09:07:04 -07:00
Victor Zverovich
709169a4d8
Set the anchors
2024-06-15 08:55:22 -07:00
Victor Zverovich
2bf1b3004e
Update changelog
2024-06-15 08:16:42 -07:00
LoveSy
8687315e86
Guard more system headers by FMT_MODULE ( #4006 )
...
* Guard more system headers by `FMT_MODULE`
* Merge FMT_MODULE and FMT_IMPORT_STD
2024-06-14 10:53:51 -07:00
Victor Zverovich
98dd673cf8
Cleanup cmake
2024-06-14 08:04:11 -07:00
Victor Zverovich
a245a8d4b9
Update changelog
2024-06-13 21:14:31 -07:00
Victor Zverovich
e0b66e8f83
Remove dependency on <ranges>
2024-06-13 15:57:01 -07:00
Matthias Moulin
794df69c8c
Added range_format::(debug_)string formatter ( #3973 )
2024-06-13 15:43:29 -07:00
Victor Zverovich
1d9df9ce1c
Remove a redundant comment
2024-06-13 15:41:35 -07:00
LoveSy
c4ea903250
Only install FILE_SET when needed ( #4013 )
2024-06-13 12:17:46 -07:00
Vladislav Shchapov
3e3062c13b
Update msys2/setup-msys2 to v2.23.0 ( #4012 )
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2024-06-13 06:14:27 -07:00
Victor Zverovich
b998b47116
Update changelog
2024-06-12 20:27:27 -07:00
Vladislav Shchapov
bff1de15e7
Fix deploy docs ( #4010 )
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2024-06-12 10:27:12 -07:00
Victor Zverovich
90932dd20d
Update doc.yml
2024-06-11 15:31:05 -07:00
Victor Zverovich
232c5e8547
Update doc.yml
2024-06-11 15:24:18 -07:00
Victor Zverovich
26cdd1cb30
Update doc.yml
2024-06-11 15:15:56 -07:00
Victor Zverovich
ad34d4df95
Update doc.yml
2024-06-11 15:12:47 -07:00
Victor Zverovich
f796264449
Fix doc workflow
2024-06-11 13:43:31 -07:00
Victor Zverovich
28673d9699
Update api.md
2024-06-11 12:27:12 -07:00
Victor Zverovich
a5c1b5d440
Update changelog
2024-06-10 11:30:21 -07:00
Kefu Chai
cc4d1245b8
README.md: update to remove "not yet release" remarks on clang-tidy
...
clang v18 was released, see
https://github.com/llvm/llvm-project/releases/tag/llvmorg-18.1.6
so let's drop the remarks of "not yet released", and encourage user
to the latest stable release of clang-tidy.
Signed-off-by: Kefu Chai <tchaikov@gmail.com>
2024-06-10 23:18:02 +08:00
Victor Zverovich
18a325f370
Disable footer
2024-06-09 19:02:34 -07:00
Victor Zverovich
a1337aa8aa
Merge literal-based API doc into the parent section
2024-06-09 18:16:56 -07:00
LoveSy
51a690ab15
Check if .cc exists in fmt.cc ( #4005 )
...
After installation, these files no longer exist and cause errors.
2024-06-09 18:01:44 -07:00
Victor Zverovich
f332a81b72
Remove unnecessary build step
2024-06-09 17:32:13 -07:00
Victor Zverovich
33a1de57af
Deploy docs, take 3
2024-06-09 17:26:37 -07:00
Victor Zverovich
c7252b3344
Deploy docs, take 2
2024-06-09 17:19:06 -07:00
Victor Zverovich
3f71b60668
Deploy docs
2024-06-09 17:16:59 -07:00
Victor Zverovich
215ce4d979
Fix error getting config 'user.email'
2024-06-09 17:07:23 -07:00
Victor Zverovich
89f3a810ec
Fix error getting config 'user.name'
2024-06-09 17:04:19 -07:00
Victor Zverovich
1f170d3fe0
Install mike
2024-06-09 16:54:53 -07:00
Victor Zverovich
d175db8f5b
Fix doc CI and clean workflows
2024-06-09 16:51:19 -07:00
Victor Zverovich
a8cfc0cc2c
Deploy dev docs
2024-06-09 16:34:50 -07:00
Victor Zverovich
65e278b286
Don't pollute the source directory
2024-06-09 16:20:54 -07:00
Victor Zverovich
3620c174a6
Fix doc build
2024-06-09 16:10:26 -07:00
Victor Zverovich
702b6f3788
Update docs
2024-06-09 15:59:35 -07:00
Victor Zverovich
ed21034a10
Implement deployment
2024-06-09 15:53:16 -07:00
Victor Zverovich
76d57f93db
Remove old script
2024-06-09 13:40:33 -07:00
Victor Zverovich
6ceef04dfe
Merge branch 'master' of github.com:fmtlib/fmt
2024-06-09 13:17:31 -07:00
Victor Zverovich
ab6b257a39
Implement doc building
2024-06-09 13:17:13 -07:00
ChristianGebhardt
077e4ae746
Added generator expression to /utf-8 compile option ( #3995 )
...
Do not pass the compile options in the project to other compilers such as nvcc
2024-06-09 13:05:17 -07:00
Victor Zverovich
d4a8d26c55
Temporarily disable doc build in CI
2024-06-09 11:47:09 -07:00
Victor Zverovich
b5c8fd783c
Fix doc build
2024-06-09 11:37:18 -07:00
Victor Zverovich
735a613821
Build docs
2024-06-09 11:26:25 -07:00
Victor Zverovich
a6e6e9c3c9
Fix a link
2024-06-09 11:22:57 -07:00
Victor Zverovich
e6d4f927cc
Improve docs
2024-06-09 11:17:32 -07:00
Victor Zverovich
8de3e87da1
Add a CMake option to control Unicode support
2024-06-09 11:16:13 -07:00
LoveSy
46d2acb3ba
Don't add os.cc to sources with FMT_MODULE ( #4004 )
...
It will be included by `fmt.cc`
2024-06-09 11:00:12 -07:00
LoveSy
fad0222a0c
Export compiled_string so that user can customize one ( #3999 )
2024-06-09 10:58:58 -07:00
Victor Zverovich
d1cab6a9ae
Drop parentheses
2024-06-09 10:58:02 -07:00
Victor Zverovich
fcb6a452d6
Improve docs
2024-06-09 10:47:32 -07:00
Victor Zverovich
72928661ed
Improve docs
2024-06-09 10:33:34 -07:00
Victor Zverovich
d6ec6b7e27
Update docs
2024-06-09 10:16:19 -07:00
Victor Zverovich
e845fc572e
Ignore old changelog
2024-06-09 07:40:02 -07:00
LoveSy
2bf811b1d9
Also allow compiled format for clang >= 12 ( #4001 )
2024-06-09 06:43:39 -07:00
Victor Zverovich
9653eed8e7
Don't hide the navbar
2024-06-09 06:36:11 -07:00
Victor Zverovich
9b5d1826d4
Update changelog
2024-06-08 18:45:18 -07:00
LoveSy
fe741daaab
Mention namespace fmt::literals in the document ( #4002 )
2024-06-08 14:31:51 -07:00
LoveSy
0f6e716548
Fix missing includes in fmt.cc ( #3994 )
...
This causes duplicated std definitions in the fmt module
2024-06-08 13:50:29 -07:00
Victor Zverovich
a3d95971be
Update changelog
2024-06-08 08:52:16 -07:00
Victor Zverovich
7bd11b5cdf
Remove a redundant extension to reduce divergence from std::format
2024-06-08 08:29:34 -07:00
Victor Zverovich
21372bc0b2
Update cmake config
2024-06-08 08:21:18 -07:00
Victor Zverovich
a0495e3eb5
Update changelog
2024-06-08 08:17:15 -07:00
Victor Zverovich
cba5e8615a
Update changelog
2024-06-08 08:15:40 -07:00
Victor Zverovich
e9609dec1a
Update changelog
2024-06-08 08:13:08 -07:00
Victor Zverovich
6ebbaf4b4d
Split changelog
2024-06-08 08:11:19 -07:00
Victor Zverovich
4e31d2dc61
Update changelog
2024-06-08 08:01:19 -07:00
LoveSy
fcc0b49978
Fix FMT_INSTALL with FMT_MODULE ( #3998 )
2024-06-08 07:26:53 -07:00
LoveSy
0560c334fb
Fix build with FMT_MODULE=OFF ( #3997 )
2024-06-07 06:25:07 -07:00
Victor Zverovich
db9365a11b
Update lint.yml
2024-06-05 21:04:46 -07:00
LoveSy
5c445bc42c
Reverting check to make shorter branch comes first
2024-06-05 21:01:42 -07:00
LoveSy
94f96d112d
Fix undefined reference when compiling with FMT_STATIC_THOUSANDS_SEPARATOR and chrono.h
2024-06-05 21:01:42 -07:00
LoveSy
6abc1204f3
Check if the generator is ninja
2024-06-05 21:01:42 -07:00
LoveSy
a9b8517638
Use native c++ module support from CMake
...
also fix some clang compilation issues when using c++ modules
2024-06-05 21:01:42 -07:00
Victor Zverovich
fba06f0ee1
Update changelog
2024-06-05 20:38:44 -07:00
Victor Zverovich
598e518085
Remove redundant tests
2024-06-05 08:38:00 -07:00
Victor Zverovich
0a555818d7
Usage -> Get Started
2024-06-05 07:59:06 -07:00
Victor Zverovich
966a1b3d44
Update docs
2024-06-05 07:19:14 -07:00
Victor Zverovich
adb8e27db0
Fix rendering of template parameters
2024-06-05 07:08:21 -07:00
Victor Zverovich
2c84fa9ac9
Update docs
2024-06-05 06:19:40 -07:00
Victor Zverovich
8da0240dbc
Improve docs
2024-06-04 19:46:45 -07:00
Victor Zverovich
83bf142378
Update changelog
2024-06-04 17:09:58 -07:00
Victor Zverovich
595e54919b
Cleanup docs
2024-06-04 17:01:04 -07:00
Victor Zverovich
c636967c5c
Improve docs
2024-06-04 15:26:38 -07:00
Victor Zverovich
2392367efc
Set primary color
2024-06-04 11:20:59 -07:00
Victor Zverovich
06f8e02fb3
Remove rtd compat
2024-06-04 10:43:55 -07:00
Kefu Chai
c71d08fc22
github: update lint.yml to post details on formatting issue ( #3988 )
...
before this change, user need to click into the details for more
details on the formatting issue identified by the lint workflow.
after this change, the workflow pastes the details with a comment,
to provide more specific details on the formatting issue if any.
Signed-off-by: Kefu Chai <tchaikov@gmail.com>
2024-06-03 06:34:44 -07:00
Victor Zverovich
d9b90029bf
Update docs
2024-06-03 06:25:14 -07:00
Victor Zverovich
c0029b9847
Update docs
2024-06-02 21:16:04 -07:00
Victor Zverovich
1ac9b317f2
New landing page
2024-06-02 20:46:16 -07:00
Victor Zverovich
f68dee5351
Fix syntax highlighting
2024-06-02 15:10:10 -07:00
Victor Zverovich
fb9ee2ed65
Simplify doxygen config
2024-06-02 14:27:12 -07:00
Victor Zverovich
d29ceaf915
Update .gitignore
2024-06-02 14:21:46 -07:00
Victor Zverovich
9b12491c19
Migrate docs
2024-06-02 14:20:41 -07:00
Victor Zverovich
ab29ef37d9
Migrate docs and cleanup
2024-06-02 13:17:04 -07:00
Victor Zverovich
97117cbb51
Migrate to mkdocs
2024-06-02 12:21:11 -07:00
Victor Zverovich
886237ae7b
Emit anchors
2024-06-02 10:32:53 -07:00
Victor Zverovich
904f2a5c20
Remove a non-pinned dependency
2024-06-02 10:00:24 -07:00
Victor Zverovich
dab1a65d2c
Sort out directory URI config
2024-06-02 09:47:52 -07:00
Victor Zverovich
509d018101
Fix a link
2024-06-02 09:29:33 -07:00
Victor Zverovich
75ab3bc2a0
Add a script to invoke mkdocs
2024-06-02 09:29:07 -07:00
Victor Zverovich
871538d3ab
Fix install dir
2024-06-02 09:05:32 -07:00
Victor Zverovich
250456d5a3
Migrate to mkdocs
2024-06-02 09:00:40 -07:00
Victor Zverovich
38ba3d3993
Migrate to mkdocs
2024-06-02 08:26:56 -07:00
Victor Zverovich
0714113974
Add macro support to api doc extraction
2024-06-02 08:06:52 -07:00
Victor Zverovich
dd3b3f937b
Merge branch 'master' of github.com:fmtlib/fmt
2024-06-02 07:02:05 -07:00
Victor Zverovich
03d14c3beb
Add support for multiple namespaces
2024-06-02 07:01:40 -07:00
dependabot[bot]
416ac0fc7b
Bump actions/checkout from 4.1.0 to 4.1.6 ( #3986 )
...
Bumps [actions/checkout](https://github.com/actions/checkout ) from 4.1.0 to 4.1.6.
- [Release notes](https://github.com/actions/checkout/releases )
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md )
- [Commits](8ade135a41...a5ac7e51b4 )
---
updated-dependencies:
- dependency-name: actions/checkout
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-06-02 06:22:27 -07:00
dependabot[bot]
596add8993
Bump ossf/scorecard-action from 2.3.1 to 2.3.3 ( #3984 )
...
Bumps [ossf/scorecard-action](https://github.com/ossf/scorecard-action ) from 2.3.1 to 2.3.3.
- [Release notes](https://github.com/ossf/scorecard-action/releases )
- [Changelog](https://github.com/ossf/scorecard-action/blob/main/RELEASE.md )
- [Commits](0864cf1902...dc50aa9510 )
---
updated-dependencies:
- dependency-name: ossf/scorecard-action
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-06-02 06:22:07 -07:00
Victor Zverovich
a10e032148
Improve docs
2024-06-01 20:08:41 -07:00
Victor Zverovich
febeb51bde
Documentation improvements
2024-06-01 17:45:06 -07:00
Victor Zverovich
f18c2b65c4
Fix rendering of aliases
2024-06-01 14:40:39 -07:00
Victor Zverovich
e3910b8a9c
Improve apidoc rendering
2024-06-01 10:24:46 -07:00
Victor Zverovich
34b85678f9
Render members
2024-06-01 10:07:33 -07:00
Victor Zverovich
e5c07c8356
Improve apidoc formatting
2024-06-01 09:37:32 -07:00
Victor Zverovich
933d8ba352
Improve apidoc formatting
2024-06-01 09:24:32 -07:00
Victor Zverovich
e7ba467e9b
Improve apidoc formatting
2024-06-01 09:05:17 -07:00
Victor Zverovich
91a859ee4a
Switch to markdown
2024-06-01 08:56:26 -07:00
Victor Zverovich
6180442ed8
Render template parameters
2024-06-01 08:30:25 -07:00
Victor Zverovich
418c5d0949
Render template params
2024-06-01 08:25:14 -07:00
Victor Zverovich
aafdde7ef8
Switch to JavaScript syntax highlighter
2024-06-01 08:04:55 -07:00
Victor Zverovich
d2ecfcfc45
Fix rendering on github
2024-06-01 07:33:57 -07:00
Victor Zverovich
26b249435e
Improve doc presentation
2024-06-01 07:32:43 -07:00
Victor Zverovich
4f330567e1
Improve apidoc generation
2024-06-01 07:02:45 -07:00
Victor Zverovich
1992746249
Convert API doc to Markdown
2024-06-01 07:02:03 -07:00
Victor Zverovich
a4d42c44f4
Cleanup comments
2024-06-01 07:00:56 -07:00
Victor Zverovich
ddd8a54230
Add mkdocs config
2024-06-01 06:50:57 -07:00
Eric Bryant
fcd3e1e19c
is_convertible_v -> is_convertible::value ( #3983 )
2024-05-31 10:02:59 -07:00
Victor Zverovich
dc401b1c28
Move handlers outside of the docs
2024-05-31 07:22:22 -07:00
Victor Zverovich
f7c5588c46
Cleanup syntax doc
2024-05-31 06:57:10 -07:00
Victor Zverovich
a4e40677af
Fix markdown
2024-05-30 21:14:06 -07:00
Victor Zverovich
3479828e1d
Fix markdown
2024-05-30 20:27:21 -07:00
Victor Zverovich
191b0cb486
Fix markdown
2024-05-30 20:26:19 -07:00
Victor Zverovich
e80f4a9b72
Cleanup syntax doc
2024-05-30 12:44:56 -07:00
Victor Zverovich
022d8efec9
Update doc.yml
...
Temporarily disable doc build
2024-05-30 11:57:02 -07:00
ZaheenJ
ca8eeb09ee
Add glibc ext for day of month and week of year ( #3976 )
2024-05-30 10:20:56 -07:00
Victor Zverovich
cddb41f633
Fix markdown
2024-05-30 06:38:40 -07:00
Victor Zverovich
0b0a05770f
Remove old contents
2024-05-29 21:47:45 -07:00
Victor Zverovich
caa97da1f5
Add a word joiner to prevent line break
2024-05-29 21:40:58 -07:00
Victor Zverovich
cf9833f40b
Cleanup apidoc comments
2024-05-29 20:30:19 -07:00
Victor Zverovich
b6638f9c29
Convert usage to Markdown
2024-05-29 20:14:23 -07:00
Victor Zverovich
d903460137
Fix markdown
2024-05-29 20:13:11 -07:00
Victor Zverovich
ba2fbf6e1f
Fix markdown
2024-05-29 19:43:52 -07:00
Victor Zverovich
6e49bb887a
Remove CSS
2024-05-29 19:10:27 -07:00
Victor Zverovich
e0f3e85076
Fix markdown
2024-05-29 19:09:54 -07:00
Victor Zverovich
4fc3fce9cb
Improve syntax markdown
2024-05-29 19:01:09 -07:00
Victor Zverovich
d6427ae7b2
Improve syntax markdown
2024-05-29 18:41:25 -07:00
Victor Zverovich
3d6869065b
Improve syntax markdown
2024-05-29 18:32:33 -07:00
Victor Zverovich
551aa8d510
Add CSS
2024-05-29 18:10:55 -07:00
Victor Zverovich
9e07045f50
Fix links
2024-05-29 17:29:41 -07:00
Victor Zverovich
5735048b2d
Improve mkdocstrings handler
2024-05-29 17:29:25 -07:00
Victor Zverovich
33eba1049d
Minor comment fix
2024-05-28 11:39:49 -07:00
Matthias Moulin
43ab964c47
MSVC 17.10.0 + modules cannot find definition ( #3972 )
...
MSVC regressed since the new 17.10.0 compiler update. node<> cannot be found for detail::dynamic_arg_list::typed_node.
2024-05-28 11:34:44 -07:00
Matthias Moulin
728f9bc388
Added std::type_info formatter ( #3978 )
...
* Added std::type_info formatter;
* Reused std::type_info formatter in std::exception formatters;
* Updated MSVC std::type_info outputting to exclude all class, struct and enum occurences.
2024-05-28 10:57:08 -07:00
Victor Zverovich
e721046e27
Convert index to Markdown
2024-05-27 20:03:30 -07:00
Victor Zverovich
552842c4ff
Convert syntax to Markdown
2024-05-27 20:01:33 -07:00
Victor Zverovich
2c38766fd5
Add a mkdocsstrings handler
2024-05-27 19:59:45 -07:00
Bruce Mitchener
c8f1b4e744
ci: Remove macos-11 runners, add macos-14 ( #3980 )
...
On June 28, 2024, macos-11 runners will be removed.
2024-05-27 10:58:57 -07:00
Victor Zverovich
529dcd11fe
Fix workflow, take 2
2024-05-27 08:08:07 -07:00
Victor Zverovich
1441c660bf
Fix workflow
2024-05-27 07:07:54 -07:00
Victor Zverovich
ecd1559732
Improve styles
2024-05-27 07:05:53 -07:00
Victor Zverovich
a57a63dc0f
Fix styles
2024-05-27 06:39:54 -07:00
Victor Zverovich
8691f21b45
Fix styles
2024-05-27 06:32:28 -07:00
Victor Zverovich
7e4fac3f4f
Improve styles
2024-05-26 20:08:42 -07:00
Victor Zverovich
4a368625e8
Replace less with sass
2024-05-26 19:59:42 -07:00
Victor Zverovich
f4e1ec81e2
Cleanup html
2024-05-26 19:23:26 -07:00
Victor Zverovich
89c0d10105
Update description
2024-05-26 13:23:04 -07:00
Victor Zverovich
12ef9e09d1
Fix class conflict
2024-05-26 13:18:43 -07:00
Victor Zverovich
5afa681388
Remove redundant github button
2024-05-26 12:56:29 -07:00
Victor Zverovich
cc13102031
Fix navbar style
2024-05-26 12:35:25 -07:00
Vladislav Shchapov
8ee6c94014
Reintroduce GCC-11 C++20 into CI ( #3979 )
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2024-05-26 10:58:26 -07:00
Victor Zverovich
766300b3c6
Update html
2024-05-26 10:25:14 -07:00
Victor Zverovich
4115219ede
Fix CSS path
2024-05-26 09:17:33 -07:00
Victor Zverovich
95076981f7
Update documentation deps
2024-05-26 09:11:43 -07:00
Matthias Moulin
1752d7fbbb
Added formattable concept ( #3974 )
2024-05-26 07:47:56 -07:00
Matthias Moulin
1768bf9714
Added FMT_EXPORT for fmt::range_format and fmt::range_format_kind ( #3970 )
2024-05-24 07:08:07 -07:00
Justin Riddell
fc723fd6c7
Fix regression in #3710 ( #3968 )
...
Regression introduced in 11f2f30
Already have a test for this, but needed to make __cpp_lib_ranges
smaller to enable it
2024-05-23 12:39:11 -07:00
Justin Riddell
b81761068b
Check range_begin is dereferenceable ( #3964 )
...
Fixes issue #3839
An Eigen 3.4 2x2 matrix has a begin member function that returns void
Be more strict checking that the result of calling *begin() is valid
See input_or_output_iterator concept notes about void
2024-05-20 16:11:07 -07:00
Matthias Moulin
706eabd5e5
Resolved warning C4127: conditional expression is constant ( #3967 )
2024-05-20 11:59:19 -07:00
Edoardo Lolletti
028bffa083
Update checks for dynamic_cast usage when compiled with no rtti ( #3963 )
...
* Rename FMT_USE_TYPEID to FMT_HAS_RTTI and use it as check to enable dynamic_cast usage
* FMT_HAS_RTTI->FMT_USE_RTTI
2024-05-19 11:21:55 -07:00
Vertexwahn
86741b3e1c
Bazel support: Add missing platform dependency ( #3965 )
2024-05-19 06:33:50 -07:00
Victor Zverovich
75e892420e
Minor cleanup
2024-05-16 10:45:23 -07:00
Victor Zverovich
0b5287f8b7
Remove unused function
2024-05-15 16:47:35 -07:00
Vertexwahn
a4715c48b4
Bazel support: Add utf-8 to Windows build ( #3962 )
2024-05-15 06:33:27 -07:00
Justin Riddell
8e728044f6
Fix format_as for non-const begin/end views ( #3955 )
...
base::format does not accept rvalues, using the result of format_as
directly means it is passed one. Doesn't matter for ranges with a const
begin and end, but filter_view caches, so it only has mutable begin/end.
Use auto&& to avoid copy if format_as returns const ref
2024-05-13 09:35:55 -07:00
Victor Zverovich
1f436c646e
Cleanup locking/buffering
2024-05-12 09:34:17 -07:00
Victor Zverovich
db1ee420e0
Cleanup unicode check more
2024-05-11 20:02:22 -07:00
Victor Zverovich
7d6ae972b9
Cleanup unicode checks
2024-05-11 19:43:46 -07:00
Victor Zverovich
3460b30fd5
Improve utf-8 detection
2024-05-11 18:58:40 -07:00
Victor Zverovich
b7809f91e2
Enable Unicode support by default
2024-05-11 15:11:23 -07:00
Victor Zverovich
1dc71f21ea
Enable Unicode by default
2024-05-10 18:27:45 -07:00
Victor Zverovich
8db8f22490
Optimize join_view
2024-05-09 17:26:26 -07:00
Victor Zverovich
d2473b7b73
Simplify join_view formatter
2024-05-08 15:42:49 -07:00
Victor Zverovich
328d256c60
Apply coding conventions
2024-05-06 15:10:29 -07:00
Victor Zverovich
57593a123b
Simplify map formatter
2024-05-06 15:09:31 -07:00
Justin Riddell
10508a30ec
Enable fmt::join for uncopyable iterators ( #3946 )
...
If iterator not copyable mutate the underlying iterator
Notably std::ranges::basic_istream_view::__iterator
Addresses issue (#3802 )
2024-05-05 15:44:23 -07:00
Victor Zverovich
16cec4f591
Make the map formatter correctly handle elements with custom formatters
2024-05-04 10:59:16 -07:00
Victor Zverovich
77bfd8499a
Split range and map formatters
2024-05-04 09:41:02 -07:00
Victor Zverovich
3af8ac7a06
Privatize write_debug_string
2024-05-04 07:38:58 -07:00
Victor Zverovich
ceb406d06c
Remove range_default_formatter
2024-05-04 07:20:40 -07:00
Victor Zverovich
19afc9c3bb
Update README.md
2024-05-03 17:32:54 -07:00
Victor Zverovich
6ff593b027
Update README.md
2024-05-03 09:30:44 -07:00
Victor Zverovich
78420beddd
Update README.md
2024-05-03 09:21:05 -07:00
Victor Zverovich
a21bc7b869
Update doc.yml
2024-05-03 09:01:35 -07:00
Victor Zverovich
97d0613ba9
Update doc.yml
2024-05-03 08:47:00 -07:00
Victor Zverovich
04b0ae418b
Update doc.yml
2024-05-03 08:32:02 -07:00
Victor Zverovich
27dd1dcf08
Update lint.yml
2024-05-03 08:18:33 -07:00
Victor Zverovich
3649c3954f
Update lint.yml
2024-05-03 07:59:52 -07:00
Victor Zverovich
7650ed04a3
Fix to_nonnegative_int
2024-05-03 07:49:16 -07:00
Alex Dewar
9234fe83f9
Add tests to check that isnan doesn't cause FP errors
2024-05-02 09:36:21 -07:00
Alex Dewar
8a8f4825a3
Fix: isnan() shouldn't cause FP exceptions
...
Fixes #3948 .
2024-05-02 09:36:21 -07:00
dependabot[bot]
17062a0c9b
Bump actions/upload-artifact from 4.3.1 to 4.3.3 ( #3950 )
...
Bumps [actions/upload-artifact](https://github.com/actions/upload-artifact ) from 4.3.1 to 4.3.3.
- [Release notes](https://github.com/actions/upload-artifact/releases )
- [Commits](5d5d22a312...65462800fd )
---
updated-dependencies:
- dependency-name: actions/upload-artifact
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-05-01 11:39:32 -07:00
dependabot[bot]
88d3997f5e
Bump github/codeql-action from 3.24.9 to 3.25.3 ( #3949 )
...
Bumps [github/codeql-action](https://github.com/github/codeql-action ) from 3.24.9 to 3.25.3.
- [Release notes](https://github.com/github/codeql-action/releases )
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md )
- [Commits](1b1aada464...d39d31e687 )
---
updated-dependencies:
- dependency-name: github/codeql-action
dependency-type: direct:production
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-05-01 08:42:46 -07:00
Marlene Cota
48c908453d
Fix CodeQL alert ( #3945 )
2024-04-30 12:41:29 -07:00
Diego Ramírez
cf1f55f798
Specialize formatter for all std::basic_string types ( #3943 )
...
* Specialize `formatter` for all `std::basic_string` types
* mock-allocator: add member types to make GCC 4.8 happy
2024-04-23 08:44:41 -07:00
Victor Zverovich
400f6a8ee2
Dedup ADL begin/end lookup
2024-04-22 16:09:07 -07:00
Victor Zverovich
a3e0931ea2
Update signature in the doc
2024-04-22 15:26:09 -07:00
Victor Zverovich
51eeccd0fb
const void* is neither a fundamental nor string type
2024-04-22 13:59:26 -07:00
Victor Zverovich
f30f1fd514
Document formatter specializations provided by base.h
2024-04-22 13:39:14 -07:00
Jiwoo Park
f4b256c667
Fix warning C26439
2024-04-19 09:06:46 -07:00
Victor Zverovich
f746a59a5c
Cleanup FMT_ASSERT
2024-04-19 08:36:16 -07:00
Hans-Martin B. Jensen
ee0c3351a4
Fix format_to + FMT_STRING for wide character type ( #3931 )
...
Added overload that takes a wformat_string.
Fixes issue #3925 .
2024-04-17 08:30:48 -07:00
Justin Riddell
99735764ea
Fix FMT_USE_NONTYPE_TEMPLATE_ARGS define back ( #3937 )
...
Broken in refactor f1924d3
2024-04-16 13:29:30 -07:00
Matthias Moulin
aa52eb765d
Resolved warning C4996: 'fileno': The POSIX name for this item is deprecated. Instead, use the ISO C and C++ conformant name: _fileno. ( #3930 )
2024-04-11 11:13:57 -07:00
Matthias Moulin
116a9ce488
Added FMT_IMPORT_STD feature macro ( #3928 )
2024-04-10 11:48:32 -07:00
ShifftC
5eb68c0ef2
Fix mix-up of 'FMT_BEGIN_EXPORT' and 'namespace detail'. ( #3924 )
2024-04-08 09:46:20 -07:00
Matthias Moulin
550437b29e
Resolved warning C4127: conditional expression is constant ( #3923 )
2024-04-07 11:01:26 -07:00
Philippe Proulx
4e8640ed90
Fix: enable FMT_NORETURN without exception support too ( #3917 )
...
When building `format.cc` as such with GCC 13.2.1:
$ g++ -c format.cc -DFMT_EXCEPTIONS=0 -Wmissing-noreturn -Werror
I get:
In file included from format.cc:8:
fmt/format-inl.h: In function ‘void fmt::v10::detail::assert_fail(const char*, int, const char*)’:
fmt/format-inl.h:30:15: error: function might be candidate for attribute ‘noreturn’ [-Werror=suggest-attribute=noreturn]
30 | FMT_FUNC void assert_fail(const char* file, int line, const char* message) {
| ^~~~~~~~~~~
fmt/format-inl.h: In function ‘void fmt::v10::report_error(const char*)’:
fmt/format-inl.h:129:15: error: function might be candidate for attribute ‘noreturn’ [-Werror=suggest-attribute=noreturn]
129 | FMT_FUNC void report_error(const char* message) {
| ^~~~~~~~~~~~
cc1plus: all warnings being treated as errors
Note that, with `FMT_EXCEPTIONS` defined to 0:
‣ report_error(const char *) uses FMT_THROW() which expands to calling
assert_fail().
‣ assert_fail() calls std::terminate() which has the `[[noreturn]]`
attribute since C++11 [1].
Therefore, with `FMT_EXCEPTIONS` defined to 0, both assert_fail() and
report_error() need to have the `[[noreturn]]` attribute too (if
available). In other words, `FMT_NORETURN` doesn't depend on
`FMT_EXCEPTIONS`.
Also adding `FMT_NORETURN` to two on_error() functions which call
report_error(const char *).
Other report_error() overloads eventually return, therefore they don't
need `FMT_NORETURN`.
[1]: https://en.cppreference.com/w/cpp/error/terminate
Signed-off-by: Philippe Proulx <eeppeliteloop@gmail.com>
2024-04-04 17:15:18 -07:00
Victor Zverovich
c70e7b7473
Coding conventions and minor fixes
2024-04-05 08:36:45 +09:00
zivshek
71144eeaff
implement year_month_day ( #3913 )
...
* implement year_month_day, also changed weekday, day, month, year's formatter to use formatter<std::tm, Char> so they all support the format strings
* support ":L" for month and weekday
2024-04-03 15:35:53 -07:00
dependabot[bot]
843e293564
Bump github/codeql-action from 3.24.6 to 3.24.9 ( #3915 )
...
Bumps [github/codeql-action](https://github.com/github/codeql-action ) from 3.24.6 to 3.24.9.
- [Release notes](https://github.com/github/codeql-action/releases )
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md )
- [Commits](8a470fddaf...1b1aada464 )
---
updated-dependencies:
- dependency-name: github/codeql-action
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-04-03 15:21:30 -07:00
Victor Zverovich
f5ec5ada2b
Update syntax.rst
2024-03-30 15:54:39 -07:00
Damian Andrei
3b5f3de3b5
Make CMake version message less confusing ( #3907 )
2024-03-28 18:23:26 -07:00
Vladislav Shchapov
ca9193983b
Replace std::fill_n with fmt::detail::fill_n ( #3909 )
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2024-03-28 17:26:18 -07:00
zivshek
74a187288b
Implemented fmt::day, fmt::month, fmt::year and related unit tests ( #3906 )
2024-03-27 17:10:30 -07:00
js324
88620e53a4
Range formatting documentation ( #3905 )
2024-03-24 14:39:16 -07:00
Victor Zverovich
5d63e87d23
Add a formatter for float128
2024-03-22 15:41:50 +09:00
Victor Zverovich
aecec01b34
Initial support for extended FP types
2024-03-22 15:08:25 +09:00
Victor Zverovich
5af88653eb
Cleanup
2024-03-22 13:46:03 +09:00
Vladislav Shchapov
45b772f85c
Improve std::complex formatter to be compatible with P2197R0 ( #3900 )
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2024-03-20 13:31:32 -07:00
Victor Zverovich
53347891cf
Make line buffering test less flaky
2024-03-20 16:45:50 +09:00
Victor Zverovich
38881e5acf
Fix handling of the fileno macro
2024-03-20 05:06:36 +09:00
Vladislav Shchapov
6c7cc6a06f
Fix group_digits for negative integers ( #3901 )
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2024-03-19 13:03:57 -07:00
Victor Zverovich
365c3fbd25
Bump timeout
2024-03-19 10:49:02 +09:00
Victor Zverovich
c0dac83982
Use p2197 format for complex by default
2024-03-19 07:55:45 +09:00
Victor Zverovich
bb882c03bc
Simplify path formatting
2024-03-19 07:47:42 +09:00
Vladislav Shchapov
12acd7988b
Fix ambiguous call
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2024-03-17 17:16:53 -07:00
Vladislav Shchapov
c710bfa10c
Apply clang-format
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2024-03-17 15:26:18 -07:00
Vladislav Shchapov
73f2b344b2
Add std::complex formatter
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2024-03-17 15:26:18 -07:00
Vladislav Shchapov
9f3fc6e38b
Add XChar support into nested_formatter
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2024-03-17 15:26:18 -07:00
Vladislav Shchapov
c17816cb4a
Fix invalid fmt::formatter<>::format return type ( #3895 )
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2024-03-15 06:25:42 -07:00
Tobias Hermann
df6e7b22f7
Fix relative path for cmake in usage doc ( #3890 )
2024-03-12 06:56:12 -07:00
Victor Zverovich
c816fa6751
Fix a warning
2024-03-10 10:27:42 -07:00
Victor Zverovich
e281749c5d
Simplify range formatter
2024-03-10 08:19:26 -07:00
Victor Zverovich
11f2f30f0b
Simplify range formatter
2024-03-09 08:23:12 -08:00
mtillmann0
13cfaa2ab0
Guard against usage of _isatty when header was not included ( #3880 )
...
* Guard against usage of _isatty when header was not included
* Rename FMT_WINDOWS_NO_WCHAR macro to FMT_USE_WRITE_CONSOLE
2024-03-08 13:34:46 -08:00
js324
0861db500f
Support character range formatting ( #3863 )
2024-03-07 10:51:46 -08:00
vgorrX
dfe5b12c08
Update os-test.cc ( #3883 )
...
uniq test file names for the os-test suite (#3878 issue).
2024-03-06 06:37:57 -08:00
dependabot[bot]
09935d8239
Bump github/codeql-action from 3.23.2 to 3.24.6 ( #3876 )
...
Bumps [github/codeql-action](https://github.com/github/codeql-action ) from 3.23.2 to 3.24.6.
- [Release notes](https://github.com/github/codeql-action/releases )
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md )
- [Commits](b7bf0a3ed3...8a470fddaf )
---
updated-dependencies:
- dependency-name: github/codeql-action
dependency-type: direct:production
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-03-03 06:46:32 -08:00
Victor Zverovich
3bc6cc1e63
Protect against locking formatters
2024-03-02 17:23:02 -08:00
dependabot[bot]
4fcc317dc9
Bump actions/upload-artifact from 4.3.0 to 4.3.1 ( #3875 )
...
Bumps [actions/upload-artifact](https://github.com/actions/upload-artifact ) from 4.3.0 to 4.3.1.
- [Release notes](https://github.com/actions/upload-artifact/releases )
- [Commits](26f96dfa69...5d5d22a312 )
---
updated-dependencies:
- dependency-name: actions/upload-artifact
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-03-01 12:20:00 -08:00
Baardi
ae1e93d34d
Fix warning C4702 emitted from format.h (MSVC) ( #3866 )
2024-02-28 07:47:13 -08:00
Victor Zverovich
f68f452dea
Workaround an ld warning on macOS
2024-02-25 11:41:52 -08:00
Gao Mingfei
ebea5736a2
Fix chrono locale format bug for RHEL gcc ( #3859 )
2024-02-25 07:09:33 -08:00
Baardi
ddf0b7d2b5
Fix warning C4365 emitted from printf.h ( #3865 )
2024-02-23 16:33:21 -08:00
prlw1
0166f455f6
std.h c++23 build fix ( #3856 )
...
Add ::value to is_formattable<...> as per suggestion by @vitaut in
https://github.com/fmtlib/fmt/issues/3854
2024-02-19 10:19:39 -08:00
Victor Zverovich
8e42eef495
Don't error on min time_point
2024-02-10 17:50:42 -08:00
Victor Zverovich
91b30e5b4e
More API details
2024-02-10 08:10:59 -08:00
Victor Zverovich
7a63e233d2
Readd core.h to headers
2024-02-10 07:10:28 -08:00
Victor Zverovich
44c3fe1ebb
Fix handling of static separator
2024-02-09 15:58:56 -08:00
Anders Dalvander
ae181cc93d
C++23 compatibility: basic_string_view cannot be constructed from nullptr ( #3846 )
...
Co-authored-by: Anders Dalvander <anders.dalvander@sartorius.com>
2024-02-09 07:39:43 -08:00
Bruce Mitchener
3a6fb2fcaf
Fix some typos. ( #3843 )
2024-02-08 10:59:52 -08:00
Bruce Mitchener
0879504796
Fix typo in typename. containter_type -> container_type. ( #3844 )
2024-02-08 06:24:55 -08:00
js324
34f415b56e
Fix %S formatting for chrono durations with leading zeroes ( #3814 )
2024-02-07 09:47:32 -08:00
Victor Zverovich
e17bc67547
Make scan variadic
2024-02-04 08:07:00 -08:00
Victor Zverovich
06311ed1ce
Fix fixed rounding around zero in Dragon
2024-02-03 10:13:58 -08:00
Dominic Pöschko
e5bab8dab4
added formatter for std::expected ( #3834 )
2024-02-03 09:06:15 -08:00
dependabot[bot]
9f5f39cb50
Bump actions/upload-artifact from 4.0.0 to 4.3.0 ( #3837 )
...
Bumps [actions/upload-artifact](https://github.com/actions/upload-artifact ) from 4.0.0 to 4.3.0.
- [Release notes](https://github.com/actions/upload-artifact/releases )
- [Commits](c7d193f32e...26f96dfa69 )
---
updated-dependencies:
- dependency-name: actions/upload-artifact
dependency-type: direct:production
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-02-01 09:05:12 -08:00
dependabot[bot]
ea581437e5
Bump github/codeql-action from 2.22.5 to 3.23.2 ( #3836 )
...
Bumps [github/codeql-action](https://github.com/github/codeql-action ) from 2.22.5 to 3.23.2.
- [Release notes](https://github.com/github/codeql-action/releases )
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md )
- [Commits](74483a38d3...b7bf0a3ed3 )
---
updated-dependencies:
- dependency-name: github/codeql-action
dependency-type: direct:production
update-type: version-update:semver-major
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-02-01 09:04:58 -08:00
Victor Zverovich
6321a97d6b
Simplify color formatting
2024-01-31 18:30:23 -08:00
Victor Zverovich
4b6b32f388
Deprecate wide stream function
2024-01-31 18:10:52 -08:00
Afanasyev Ivan
1b54ba4b9d
Fix UB in format_arg_store implementation. ( #3833 )
2024-01-31 10:08:29 -08:00
Frank Richter
71a4a8d479
Really fix MSVC warning about <bit> only being available in C++20. ( #3832 )
...
* Really fix MSVC warning about <bit> only being available in C++20.
The warning states "The contents of <bit> are available only with C++20 or later.",
but the check was for C++17 and later.
* Change <bit> inclusion check per https://github.com/fmtlib/fmt/pull/3832#discussion_r1471144867
2024-01-30 10:42:35 -08:00
Victor Zverovich
8e62172ab6
Fix a warning
2024-01-29 07:48:48 -08:00
Victor Zverovich
28afff363c
Improve buffering
2024-01-27 16:20:34 -08:00
Victor Zverovich
af44c29744
Separate buffer initialization from flush
2024-01-27 15:39:36 -08:00
Victor Zverovich
a1e1eedbb5
Minor cleanup
2024-01-27 14:00:13 -08:00
Victor Zverovich
ffce3632b7
Add glibc stream support
2024-01-27 11:00:45 -08:00
Victor Zverovich
b5669512b1
Don't hang on test failure
2024-01-27 09:41:33 -08:00
Victor Zverovich
6435b169ec
Add support for line buffering
2024-01-27 08:57:21 -08:00
Victor Zverovich
6f260455aa
Add scan_data::make_args
2024-01-23 08:17:06 -08:00
Beat Bolli
e1832bcf00
Consider ADL begin() and end() when joining ranges ( #3824 )
...
Closes #3813
Signed-off-by: Beat Bolli <dev@drbeat.li>
2024-01-22 07:39:33 -08:00
Victor Zverovich
2caf1b3b91
scan more
2024-01-21 08:02:54 -08:00
Beat Bolli
668fe2653c
doc: fix the chrono %C example value ( #3822 )
...
Assuming that the example date is always "Sat Nov 12 22:04:00 1955", the
result of the `%C` format string should be "19", not "55".
Signed-off-by: Beat Bolli <dev@drbeat.li>
2024-01-21 06:31:15 -08:00
Edoardo Lolletti
06fc25f266
Don't always enable typeid usage under msvc ( #3821 )
2024-01-21 06:28:22 -08:00
Victor Zverovich
11ba1270ab
Fix flush
2024-01-20 07:58:56 -08:00
Victor Zverovich
4c5b4af04d
Improve name argument validation
2024-01-19 16:13:43 -08:00
frank-weinberg
2eb363297b
Fix custom formatter example ( #3820 )
...
Add a return type declaration so the example builds when the formatter is used in a different compilation unit than it's implemented.
2024-01-19 08:14:48 -08:00
Victor Zverovich
0147e08225
Document println
2024-01-18 19:42:33 -08:00
Victor Zverovich
6b68dff901
Write directly to a stream buffer
2024-01-18 16:27:12 -08:00
Victor Zverovich
b2cde48de5
Reduce usage of float_specs
2024-01-17 08:27:03 -08:00
Victor Zverovich
8510838db1
Make format_specs not depend on code unit type
2024-01-17 07:50:52 -08:00
Victor Zverovich
090ee13595
Pass char type to write
2024-01-17 06:07:29 -08:00
Vladislav Shchapov
470c4e6ca8
Fix scope for glibc ext for sec, min, and hour ( #3812 )
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2024-01-16 13:54:19 -08:00
The Phantom Derpstorm
13ec66bf78
🛠 Add basic array safety functions and backwards-compatible result type ( #3805 )
2024-01-16 07:01:15 -08:00
Victor Zverovich
64091b7a25
Fix naming
2024-01-15 15:17:46 -08:00
Victor Zverovich
e954823531
Make fill independent on code unit type
2024-01-15 15:00:28 -08:00
Victor Zverovich
f80a2bee1c
Update README.md
2024-01-15 11:40:20 -08:00
Victor Zverovich
83652dfee7
Restrict always inlining to the top-level API
2024-01-15 10:09:01 -08:00
Vladislav Shchapov
d249fd9f84
Workaround for gcc 6 ( #3810 )
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2024-01-15 08:58:19 -08:00
Bruce Mitchener
73d91351b4
Mark iterator_buffer move constructors as noexcept. ( #3808 )
2024-01-15 08:46:35 -08:00
Victor Zverovich
fe0d910a7d
Replace multiple error reporting mechanisms with report_error
2024-01-15 07:23:06 -08:00
Victor Zverovich
f9294f0e60
Improve handling of format specs
2024-01-15 06:31:24 -08:00
Victor Zverovich
c98a5a599f
Remove unnecessary checks
2024-01-14 17:41:49 -08:00
Victor Zverovich
5f30d37102
Update README.md
2024-01-14 17:25:43 -08:00
Victor Zverovich
3647feaad5
Improve scan
2024-01-14 09:30:45 -08:00
Victor Zverovich
e420a58f24
Improve scan prototype
2024-01-14 08:51:33 -08:00
Victor Zverovich
ca37503f93
scan -> scan_to
2024-01-14 08:30:42 -08:00
Victor Zverovich
123e058eb3
Improve scan prototype
2024-01-14 08:11:13 -08:00
Victor Zverovich
f924d20dbd
core-test -> base-test
2024-01-14 06:57:01 -08:00
Victor Zverovich
d70729215f
Fix constness
2024-01-14 06:44:38 -08:00
Victor Zverovich
362b40c1a3
Fix docs
2024-01-13 19:21:27 -08:00
Victor Zverovich
56fa4d61f6
Fix docs
2024-01-13 19:03:23 -08:00
Victor Zverovich
cacdf1439f
Remove nonstandard alias
2024-01-13 15:56:16 -08:00
Victor Zverovich
4d766b1670
Invert dependencies
2024-01-13 10:30:44 -08:00
Victor Zverovich
c10859f15c
Remove deprecated options
2024-01-13 10:25:11 -08:00
Victor Zverovich
d0963d4823
Make ranges only depend on fmt/base.h
2024-01-13 09:54:19 -08:00
Victor Zverovich
da0f84c42c
Cleanup copy functions and move to base.h
2024-01-13 09:31:20 -08:00
Victor Zverovich
59baac522e
Remove unused functions
2024-01-13 09:03:35 -08:00
Vladislav Shchapov
21b0458291
Use std::allocator_traits ( #3804 )
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2024-01-13 08:48:37 -08:00
Vladislav Shchapov
df6a3564b0
Fix MSVC warning: "The contents of <bit> are available only with C++20 or later." ( #3807 )
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2024-01-13 08:26:44 -08:00
Hans-Martin B. Jensen
7c163acfda
Fix conversion warning in filesystem::path formatter ( #3806 )
...
* Fix conversion warning in filesystem::path formatter
Use template character type to eliminate MSVC conversion warning when
formatting a wide chararacter path:
fmt\std.h(140,49): warning C4244: '=': conversion from 'const Char' to 'char', possible loss of data
* Review: use to_ascii instead
---------
Co-authored-by: Hans-Martin B. Jensen <haje@eposaudio.com>
2024-01-13 08:02:31 -08:00
Victor Zverovich
1b55d10305
Update api.rst
2024-01-12 16:48:20 -08:00
Victor Zverovich
5d9d376d49
Update api.rst
2024-01-12 15:17:52 -08:00
Victor Zverovich
6064b85c10
Update api.rst
2024-01-12 13:57:44 -08:00
Victor Zverovich
deb584c0e1
Update build.py
2024-01-12 13:56:00 -08:00
Victor Zverovich
297b22f585
Remove <memory> dependency
2024-01-12 09:09:19 -08:00
Victor Zverovich
3c9608416a
Remove redundant detection of experimental string_view
2024-01-12 07:45:07 -08:00
Victor Zverovich
0cdee904a4
Add a missing num_bits specialization
2024-01-12 07:20:12 -08:00
Victor Zverovich
7e58af4eaf
Fix an ICE on clang <= 15
2024-01-12 06:48:03 -08:00
Victor Zverovich
f1924d3269
Cleanup macros
2024-01-12 06:35:25 -08:00
Victor Zverovich
52174953bc
Cleanup conseval detection
2024-01-12 05:59:22 -08:00
Victor Zverovich
b71d98774b
Reduce usage of FMT_COSTEXPR20
2024-01-11 21:27:00 -08:00
Victor Zverovich
810d1750f1
Cleanup constexpr detection
2024-01-11 21:08:01 -08:00
Victor Zverovich
170ffb1ff8
Simplify constexpr checks
2024-01-11 20:26:52 -08:00
Victor Zverovich
e470ba8b7b
Simplify exception detection
2024-01-11 19:42:06 -08:00
Victor Zverovich
bf98e3e4c6
Cleanup macros
2024-01-11 19:16:35 -08:00
Victor Zverovich
fd87a23d34
Reduce memory dependency
2024-01-10 20:00:15 -08:00
Victor Zverovich
b71ef65b6e
Remove iterator dependency
2024-01-10 18:52:53 -08:00
Victor Zverovich
c5340539f9
Remove unnecessary trait specialization
2024-01-10 18:11:37 -08:00
Victor Zverovich
971f7ae768
Minor cleanup
2024-01-10 16:43:00 -08:00
Vertexwahn
6159e2b0ab
Bazel support: Switch to globbing to collect header files
2024-01-10 15:52:54 -08:00
Victor Zverovich
da7a232b9e
Cleanup contexts
2024-01-10 13:09:55 -08:00
Tristan Brindle
2595bf57b3
Fix formatting of ranges with begin()&/end()&
...
C++20 allows ranges to have lvalue-qualified begin() and end() member functions. fmt correctly handles this if begin() and end() are additionally const-qualifed (i.e. begin() const&), but not in the non-const case. For example:
https://godbolt.org/z/YfxaYz5r7
This patch fixes fmt's range detection to handle this case by testing calls to detail::ranges_begin()/end() with an lvalue T&, matching the behaviour in the const case.
2024-01-10 12:22:53 -08:00
Vladislav Shchapov
6f5d53ce08
Add fmt::is_contiguous<std::basic_string<Char, Traits, Allocator>>
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2024-01-10 10:47:39 -08:00
Vladislav Shchapov
961df829b9
Fix buffer overflow if output iterator is std::back_insert_iterator and value is escaped (debug format)
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2024-01-10 09:15:16 -08:00
Victor Zverovich
401f087394
Fix write_uintptr_fallback
2024-01-10 09:09:57 -08:00
Victor Zverovich
725992928b
Update build.py
2024-01-10 07:44:24 -08:00
Victor Zverovich
3d84b45a22
Update core.h
2024-01-10 06:57:22 -08:00
Victor Zverovich
4331abed26
Move fmt::format to fmt/format.h
2024-01-10 06:43:12 -08:00
Victor Zverovich
fc8f6ba934
Separate compilation for println
2024-01-10 05:55:26 -08:00
Victor Zverovich
58a6bd48a8
Add core.h for compatibility
2024-01-09 20:10:30 -08:00
Victor Zverovich
79f1506fe3
Add base.h
2024-01-09 19:36:12 -08:00
Victor Zverovich
4d616479b5
Simplify make_format_args
2024-01-09 19:18:35 -08:00
Tulio Leao
cf8426cf8c
Sort links on fmt/std.h section
2024-01-09 15:43:18 -08:00
Tulio Leao
e915d52162
Update api.rst with support provided by std.h
2024-01-09 15:43:18 -08:00
Victor Zverovich
7ba6420540
Optimize debug codegen
2024-01-09 11:44:57 -08:00
Vertexwahn
97867e279a
Extend Bazel build support to bzlmod ( #3792 )
2024-01-09 11:27:44 -08:00
Vertexwahn
8875cf96c2
Fix spelling: othewise ==> otherwise ( #3791 )
2024-01-09 10:32:46 -08:00
Victor Zverovich
f7ed65fa4a
Simplify format_arg_store
2024-01-09 06:29:16 -08:00
Victor Zverovich
f34f31b321
Move format_arg_store to detail
2024-01-08 21:44:56 -08:00
Victor Zverovich
fb66131efa
Improve arg storage
2024-01-08 21:25:41 -08:00
Victor Zverovich
6af30d8f75
Remove legacy workaround
2024-01-08 20:13:50 -08:00
Victor Zverovich
c177324ba9
Simplify basic_format_args
2024-01-08 18:42:53 -08:00
Victor Zverovich
545d37a8b0
Remove extra level of indirection when building args
2024-01-08 17:58:07 -08:00
Victor Zverovich
9f73e45ca0
Update README.md
2024-01-08 12:51:59 -08:00
Victor Zverovich
a5ae9ae19d
Split standard context into a separate class and optimize
2024-01-08 07:08:49 -08:00
Victor Zverovich
23e8109d8d
Remove buffer_appender
2024-01-07 22:03:02 -08:00
Victor Zverovich
679af1f5cc
Remove redundant get_container
2024-01-07 19:31:26 -08:00
Victor Zverovich
48d7fb265b
Merge back_insert_iterator and appender
2024-01-07 18:43:27 -08:00
Victor Zverovich
f348d1a211
Reintroduce back_insert_iterator detection
2024-01-07 17:44:40 -08:00
Victor Zverovich
df67df7b4c
Add is_back_insert_iterator
2024-01-07 16:44:42 -08:00
Victor Zverovich
17f79ac6cf
Minor cleanup
2024-01-07 15:04:38 -08:00
Victor Zverovich
dbdfc99fa1
Don't crash if flush fails during unwinding
2024-01-07 14:55:16 -08:00
Victor Zverovich
c1d9e88402
Remove unnecessary final and apply clang-format
2024-01-07 13:08:17 -08:00
Victor Zverovich
7d73ef85f7
Cleanup ranges
2024-01-06 19:37:14 -08:00
Victor Zverovich
ae9b0b521b
Disable transitive includes
2024-01-06 15:22:13 -08:00
Victor Zverovich
f73388f1ad
Update README.md
2024-01-06 13:26:17 -08:00
Victor Zverovich
08878044c6
Update readme
2024-01-06 13:24:51 -08:00
Victor Zverovich
1b7d9db0ce
Remove string dependency
2024-01-06 06:25:34 -08:00
Victor Zverovich
0641b844ac
Cleanup string traits
2024-01-05 19:31:04 -08:00
Victor Zverovich
1e938dda20
Simplify char_t
2024-01-05 15:32:59 -08:00
Victor Zverovich
2e5b14bf60
Add compile-time checks to color formatting
2024-01-05 09:51:52 -08:00
Victor Zverovich
e0b604beb1
Remove a redundant function
2024-01-04 15:59:33 -08:00
Eicke Herbertz
6c617c9670
Update documentation ( #3789 )
...
Add a note about the numerical zero being ignored when an alignment flag is
present in the format specifier.
This change was introduced in a585571e90e7f5645bcf6548cef42078db940f49 to
be compatible with std::format, but misses documentation.
2024-01-04 10:35:55 -08:00
Victor Zverovich
bee495c97f
Remove dead code
2024-01-04 09:40:30 -08:00
Victor Zverovich
794e1b6145
Remove redundant overload
2024-01-04 09:21:19 -08:00
Victor Zverovich
c7061776ab
Bump version
2024-01-04 05:50:54 -08:00
Victor Zverovich
dc52d176de
Cleanup dependencies
2024-01-03 20:52:45 -08:00
Victor Zverovich
0e3e61cc0a
Remove limits dependency
2024-01-03 19:14:30 -08:00
Victor Zverovich
800a0bb23f
Remove dependency on string_view
2024-01-03 18:49:45 -08:00
Victor Zverovich
f2e43f967c
Remove char_traits dependency
2024-01-03 13:16:28 -08:00
Victor Zverovich
c9287eb9f7
Reduce char_traits usage
2024-01-03 10:02:16 -08:00
Victor Zverovich
61f144bd61
Move copy_str for format.h
2024-01-03 09:05:09 -08:00
Victor Zverovich
4687f8e37e
Remove dependency on <iterator>
2024-01-03 08:20:04 -08:00
Victor Zverovich
f2c55f6bb8
Remove dependency on back_insert_iterator
2024-01-03 06:16:00 -08:00
Victor Zverovich
c9d233c0a4
Decouple appender from back_insert_iterator
2024-01-03 06:16:00 -08:00
Kasra Hashemi
242bcaec04
Update README.md ( #3784 )
2024-01-03 05:35:38 -08:00
Victor Zverovich
4e43a46993
Clarify why we can't have nice things
2024-01-02 19:14:32 -08:00
Victor Zverovich
c36ed77ff0
Get rid of addressof
2024-01-02 18:44:27 -08:00
Victor Zverovich
e2ab9ab22b
Add FMT_GLIBCXX_RELEASE
2024-01-02 16:15:23 -08:00
Victor Zverovich
0378d171f9
Replace remove_cvref_t with remove_const_t
2024-01-02 12:46:09 -08:00
Victor Zverovich
baea8f6906
Update docs
2024-01-02 08:52:07 -08:00
Victor Zverovich
eedfdb4c5c
Fix docs
2024-01-02 08:44:15 -08:00
Victor Zverovich
5dbd7fd770
Switch to bootstrap 4 because 5 breaks menus
2024-01-02 07:39:28 -08:00
Vladislav Shchapov
7fd1802686
Fix FMT_OS definition ( #3783 )
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2024-01-02 07:20:09 -08:00
Victor Zverovich
63ce170853
Replace virtual dispatch with normal functions in buffers
2024-01-02 07:02:20 -08:00
Victor Zverovich
74ffea0dcf
Simplify to_ascii
2024-01-01 20:09:47 -08:00
Victor Zverovich
6c3b2d491e
Fix constness
2024-01-01 19:50:36 -08:00
Victor Zverovich
4ec9c2906b
Apply coding conventions
2024-01-01 19:04:25 -08:00
Victor Zverovich
f4a7d40dca
Dedup throw_format_error
2024-01-01 18:42:23 -08:00
Victor Zverovich
9659f22d36
Don't include os.cc in the module if it is disabled via FMT_OS
2024-01-01 18:32:53 -08:00
Victor Zverovich
068bf9bad8
Make visitation compatible with std::format
2024-01-01 17:31:36 -08:00
Victor Zverovich
50565f9853
Move misplaced join overloads to fmt/ranges.h
2024-01-01 16:28:59 -08:00
Victor Zverovich
0b39d67103
Remove detail::error_handler
2024-01-01 16:10:13 -08:00
Victor Zverovich
c142385033
Improve the pipe API
2024-01-01 15:55:37 -08:00
Victor Zverovich
398ddb8fec
Don't include fmt/os.h in the module if it is disabled via FMT_OS
2024-01-01 12:21:28 -08:00
Victor Zverovich
583729493c
Remove duplicate version
2024-01-01 11:50:43 -08:00
Victor Zverovich
6c5bcca819
Fix the release script
2024-01-01 11:26:19 -08:00
Victor Zverovich
67c0c0c09c
Update version
2024-01-01 11:10:16 -08:00
Victor Zverovich
051b31531c
Fix changelog update
2024-01-01 11:06:44 -08:00
Victor Zverovich
b0569451a7
Bump version
2024-01-01 10:06:52 -08:00
Victor Zverovich
ce3161887a
Add overflow check
2024-01-01 09:17:10 -08:00
Victor Zverovich
1a95e5d1b4
Update changelog
2024-01-01 09:03:46 -08:00
Victor Zverovich
e1aac42663
Implement hex specifier
2024-01-01 09:03:46 -08:00
Victor Zverovich
1705600be3
Remove optional
2024-01-01 09:03:46 -08:00
dependabot[bot]
0c345dccd2
Bump actions/upload-artifact from 3.1.2 to 4.0.0 ( #3782 )
...
Bumps [actions/upload-artifact](https://github.com/actions/upload-artifact ) from 3.1.2 to 4.0.0.
- [Release notes](https://github.com/actions/upload-artifact/releases )
- [Commits](0b7f8abb15...c7d193f32e )
---
updated-dependencies:
- dependency-name: actions/upload-artifact
dependency-type: direct:production
update-type: version-update:semver-major
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-01-01 08:10:18 -08:00
Victor Zverovich
d33731d202
Implement empty format specs
2024-01-01 07:54:02 -08:00
Victor Zverovich
c068c7c622
Add sentinel support
2024-01-01 07:25:01 -08:00
Victor Zverovich
13fa26745d
Update changelog
2024-01-01 06:58:46 -08:00
Bruce Mitchener
ebd5c8f994
Consistently use fmt:: when invoking format_to. ( #3779 )
...
This has been done partially in previous commits:
* 2ac6c5ca8b3dfbcb1cc5cf49a8cc121e3984559c
* 258000064d71a7d228d608a2e3d43bde3e32a658
* ba50c19e827383bd5dacb74189fb4852c8dcbdae
* 5ab9d39253b8bcb85a475dc058955b3916f3410a
A patch that includes the `std::error_code` changes here is
upstream in vcpkg, so that will be able to be removed when
updating to the next release.
2024-01-01 06:57:03 -08:00
Victor Zverovich
f5ca178c12
Complete scan_handler
2023-12-31 18:00:14 -08:00
Victor Zverovich
138a64bfb1
Privatization
2023-12-31 15:06:17 -08:00
Victor Zverovich
a5bacf3fef
Remove custom_formatter
2023-12-31 12:34:18 -08:00
Victor Zverovich
4aa24f54cd
Implement visitor for scan
2023-12-31 09:53:24 -08:00
Victor Zverovich
e33c1568c3
Implement scan argument access
2023-12-31 08:49:29 -08:00
Victor Zverovich
23826669cf
Cleanup error handling
2023-12-31 07:51:57 -08:00
Victor Zverovich
8e6b2541a6
Apply coding conventions
2023-12-30 16:07:35 -08:00
Victor Zverovich
4939d67a83
Cleanup scripts
2023-12-30 15:08:27 -08:00
Victor Zverovich
bd3273021b
Update release script
2023-12-30 14:29:31 -08:00
Victor Zverovich
5f9058dbd4
Improve scripts
2023-12-30 11:23:08 -08:00
Victor Zverovich
28576b0600
Workaround github markdown mess
2023-12-30 09:57:31 -08:00
Victor Zverovich
5ddd0cad15
Add a visitor for scan arguments
2023-12-30 07:43:21 -08:00
Victor Zverovich
41d31512b7
Remove unused import
2023-12-30 07:11:32 -08:00
Victor Zverovich
44b76d88f4
Fix docs
2023-12-30 07:11:13 -08:00
Victor Zverovich
3324152db4
Update the release script
2023-12-30 06:53:20 -08:00
Victor Zverovich
55190dadb5
Cleanup chrono test
2023-12-29 16:34:42 -08:00
Victor Zverovich
63e4b93cfc
Update changelog
2023-12-29 15:54:50 -08:00
Victor Zverovich
c64edcd325
Fix grammar
2023-12-29 15:51:16 -08:00
Victor Zverovich
8c520b4fdc
Fix comment
2023-12-29 15:48:25 -08:00
Victor Zverovich
2e6bb706bf
Update changelog
2023-12-29 15:48:09 -08:00
Victor Zverovich
a13d1b12e5
Update changelog and docs
2023-12-29 13:00:12 -08:00
Victor Zverovich
47a0eec2e8
Remove unnecessary alias
2023-12-29 09:59:55 -08:00
Victor Zverovich
a8bed38952
Update changelog
2023-12-29 09:57:29 -08:00
Victor Zverovich
e206043d2b
Update changelog
2023-12-29 09:00:05 -08:00
Victor Zverovich
4a6f0be5b6
Improve scan test
2023-12-29 08:32:38 -08:00
Victor Zverovich
662d784157
Fix scan test
2023-12-29 08:21:10 -08:00
Victor Zverovich
d5823aae36
Ceci n'est pas une pipe
2023-12-29 08:11:29 -08:00
Victor Zverovich
d83c1b8d4a
Add initial specifier support to scan
2023-12-29 07:30:56 -08:00
Victor Zverovich
bfba2f9e92
Improve iterator handling in scan
2023-12-29 06:34:49 -08:00
Victor Zverovich
a3bf40838f
Initial range support in scan
2023-12-29 06:25:57 -08:00
Victor Zverovich
ea1066bbe3
Cleanup test
2023-12-28 16:56:42 -08:00
Victor Zverovich
be57ec7ec0
Fix chrono-test on platforms with 32-bit time_t
2023-12-28 16:36:18 -08:00
Victor Zverovich
305747d440
Update changelog
2023-12-28 08:01:56 -08:00
Victor Zverovich
47c8f63d02
Remove redundant specifier
2023-12-28 07:32:07 -08:00
Victor Zverovich
76e8f10403
Update changelog
2023-12-28 07:23:56 -08:00
Victor Zverovich
18ca2248df
Document '?'
2023-12-28 06:39:00 -08:00
Victor Zverovich
3a25a58482
Update README.md
2023-12-26 11:12:02 -08:00
Victor Zverovich
4cbf6182ea
Remove peek
2023-12-25 10:47:45 -08:00
Victor Zverovich
88d19f5de9
Cleanup scan
2023-12-25 10:28:50 -08:00
Victor Zverovich
62529aad19
Apply coding conventions
2023-12-25 10:20:00 -08:00
Victor Zverovich
df62c86783
Mark grow as deprecated
2023-12-25 10:11:22 -08:00
Victor Zverovich
eef6dbafbf
Refactor file layer in scan
2023-12-25 09:32:29 -08:00
Victor Zverovich
41c2433358
clang-format
2023-12-25 09:09:20 -08:00
Victor Zverovich
0a9d08fefd
Simplify fallback
2023-12-25 09:00:03 -08:00
Victor Zverovich
e450b7aeb3
Implement locking
2023-12-25 08:48:45 -08:00
Victor Zverovich
c5a85f8d7d
Handle end of input in scan
2023-12-25 07:18:23 -08:00
Victor Zverovich
1fd093add4
Update changelog
2023-12-25 06:41:37 -08:00
Victor Zverovich
c4f2de4933
Improve scan
2023-12-25 06:34:15 -08:00
Victor Zverovich
d06921d8d8
Update changelog
2023-12-23 15:30:26 -08:00
Victor Zverovich
fc0f84d290
Move formatbuf to ostream.h
2023-12-23 15:00:28 -08:00
Victor Zverovich
86f2ec5de7
Fix a warning
2023-12-23 14:51:43 -08:00
Victor Zverovich
a537c39fdf
Move conjunction to where it is used
2023-12-23 14:35:11 -08:00
Victor Zverovich
7c240d52c3
Remove unused symbol
2023-12-23 13:20:55 -08:00
Victor Zverovich
f64a6a2ecd
Update changelog
2023-12-23 12:20:14 -08:00
Victor Zverovich
6f9a816786
Enable test
2023-12-23 10:14:27 -08:00
Victor Zverovich
e7875ae0fa
Fix formatting of some nested ranges
2023-12-23 09:35:32 -08:00
Victor Zverovich
3eb3aef575
Fix handling of set_debug_format
2023-12-23 08:32:36 -08:00
Victor Zverovich
56d7a8c157
Simplify test
2023-12-23 07:02:58 -08:00
Victor Zverovich
968fb9d166
Update changelog
2023-12-22 20:42:20 -08:00
Victor Zverovich
b5f6b36b00
Update changelog
2023-12-22 16:55:02 -08:00
Victor Zverovich
44dd6c0e09
Add glibc support to scan
2023-12-22 13:43:20 -08:00
Victor Zverovich
3a0f4af4e9
Refactor file layer
2023-12-22 11:27:22 -08:00
Victor Zverovich
1ca1a4a7a9
Update scan test
2023-12-22 08:22:00 -08:00
Victor Zverovich
dbd9c89b3c
Fix URI
2023-12-20 14:59:29 -08:00
Vladislav Shchapov
9cd2b87e18
Fix wchar_t to char conversion warnings ( #3764 )
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2023-12-20 08:59:26 -08:00
Victor Zverovich
d5da9cc40e
Apply clang-tidy
2023-12-19 17:52:50 -08:00
Victor Zverovich
3a2c50d4ac
Cleanup test
2023-12-19 15:28:10 -08:00
Victor Zverovich
18c43a214c
Cleanup test
2023-12-19 13:46:48 -08:00
Vladislav Shchapov
6b07fff0d9
Make hex float test more stable on different libc ( #3762 )
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2023-12-19 11:03:06 -08:00
Vladislav Shchapov
9165434e5a
Enable consteval in MSVC VS2019 version 16.10 ( #3757 )
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2023-12-18 13:00:11 -08:00
StepSecurity Bot
b8f81dede5
[StepSecurity] ci: Harden GitHub Actions ( #3759 )
...
Signed-off-by: StepSecurity Bot <bot@stepsecurity.io>
2023-12-17 17:01:17 -08:00
Vladislav Shchapov
923005bd4f
Add stdlib version check for C++20 ( #3754 )
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2023-12-17 08:33:17 -08:00
Victor Zverovich
afa85e46c3
Apply clang-format
2023-12-17 07:32:22 -08:00
js324
6025bd7c37
Add localized formatting to non-decimal presentation types of ints ( #3750 )
2023-12-15 07:51:25 -08:00
Victor Zverovich
5471a2426c
Update README.md
2023-12-13 09:32:00 -08:00
Kefu Chai
7d757cba5d
CI: add lint github workflow for running clang-format ( #3749 )
...
so that we can identify changes which do not confirm to the
clang-format rules.
Signed-off-by: Kefu Chai <tchaikov@gmail.com>
2023-12-13 07:20:23 -08:00
Kefu Chai
6855bd532b
Apply clang-format
...
* use clang-format v17.0.6 to reformat the tree
* tweak some places so that clang-format does not mutate the layout
of code too much
Signed-off-by: Kefu Chai <tchaikov@gmail.com>
2023-12-13 07:18:37 -08:00
Victor Zverovich
bbee753579
Make clang-format happy
2023-12-13 06:54:51 -08:00
Mikael Simberg
89860eb901
Use void(*)(void*) instead of decltype(&std::free) to satisfy clang in CUDA mode ( #3751 )
...
clang can't resolve &std::free in decltype(&std::free) because std::free
is overloaded (for host and device).
2023-12-11 09:44:02 -08:00
Kefu Chai
274ba2645b
allow format_as() to format reference ( #3739 )
...
before this change, format_as() is unable to format a type which
has `auto format_as() -> const another_type&`, and `another_type`
is formattable. because `format_as_result` maps the result type
as it is, and the compiler refuses to compile
`static_cast<T*>(nullptr)`, where T is a reference type. but
it would be handy if we could use `format_as()` to format types
which, for instance, owns / inherit from a formattable type, and
delegate the formatter to these variables instead without creating
a copy of them.
in this change:
* instruct `format_as_result` to map the
result type to the decayed type, so that `type` can be the decayed
type of result type, and this also enables `type` to be formattable,
as long as the decayed type is formattable.
* corresponding test is added to format-test.cc
Signed-off-by: Kefu Chai <tchaikov@gmail.com>
2023-12-10 08:49:53 -08:00
Victor Zverovich
9048add999
Report out-of-range errors in chrono
2023-12-10 08:28:50 -08:00
Victor Zverovich
640e0c02d4
Update README.md
2023-12-09 17:37:07 -08:00
Vladislav Shchapov
6392dba21c
Fix warning: identifier '_a' preceded by whitespace in a literal operator declaration is deprecated ( #3748 )
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2023-12-09 08:16:57 -08:00
Ikko Eltociear Ashimine
9a6fd11a56
Fix typo in gmock-gtest-all.cc ( #3747 )
...
syntetic -> synthetic
2023-12-09 08:13:20 -08:00
Victor Zverovich
dee0dbf07f
Update README.md
2023-12-08 14:24:11 -08:00
George Liontos
2fabb43b93
Fix README file table ( #3744 )
...
Co-authored-by: George Liontos <george.liontos@forallsecure.com>
2023-12-08 10:26:52 -08:00
Albert Santoni
9c3c107c8c
Fix compile with GCC 6.3.0 (bug #3738 ) ( #3743 )
2023-12-08 09:36:33 -08:00
H1X4
4497a2d09a
fix cmake build
2023-12-08 08:33:16 -08:00
Victor Zverovich
81629e425c
Convert README to Markdown
2023-12-08 07:28:33 -08:00
reinhardt1053
6f95000b7a
Update README.rst ( #3737 )
...
Fix Celestia URL
2023-12-07 06:21:06 -08:00
js324
573d74395b
error on bool arg w/ char pres_type ( #3734 )
2023-12-05 13:45:10 -08:00
Victor Zverovich
5d55375a8a
Experiment with scan buffering
2023-12-03 08:09:36 -08:00
Ivan Shapovalov
71bd51e6c2
Implement %j specifier for std::chrono::duration ( #3732 )
...
This adds support for `%j` presentation type for duration types:
> "If the type being formatted is a specialization of duration, the decimal
number of days without padding."
Fixes #3643 .
2023-12-03 07:29:58 -08:00
Victor Zverovich
f575089243
Simplify test
2023-12-01 08:52:42 -08:00
Félix-Antoine Constantin
99b9fbf8ef
Add formatter for std::source_location ( #3730 )
2023-11-30 10:05:56 -08:00
Victor Zverovich
8f83ee2ad1
Apply coding conventions
2023-11-30 08:24:02 -08:00
Victor Zverovich
2a8a694466
Clarify that mixing code unit types is deprecated
2023-11-30 08:20:01 -08:00
Victor Zverovich
04718008ab
Minor cleanup
2023-11-30 07:43:31 -08:00
js324
b87ea22e29
Add native and generic representation for filesystem::path format spec ( #3729 )
2023-11-29 14:49:36 -08:00
Victor Zverovich
5cfd28d476
Experiment with FILE in scan
2023-11-26 10:01:42 -08:00
Victor Zverovich
73fae91e64
Cleanup .gitignore
2023-11-25 09:45:38 -08:00
Victor Zverovich
6988be3878
Bump version
2023-11-25 09:11:53 -08:00
Victor Zverovich
2d1e4bb35e
Remove a useless comment
2023-11-25 09:05:20 -08:00
Corentin Schreiber
7f8d419115
Fix overflow in time_point formatting with large dates ( #3727 )
...
* Fix #3725 and rename fmt_safe_duration_cast to fmt_duration_cast
The function is now more generic and will handle all casts. It also
takes care of toggling safe vs unsafe casts using
FMT_SAFE_DURATION_CAST.
* Refactor fmt_duration_cast to put #ifdef inside the function
* Fix compilation error with FMT_USE_LOCAL_TIME
2023-11-25 08:36:55 -08:00
Victor Zverovich
ccc9ab7bf9
Include correct header
2023-11-25 08:23:41 -08:00
Victor Zverovich
c4283ec471
Fix a libc++ warning and move the test to the right place
2023-11-25 08:20:53 -08:00
Victor Zverovich
c3f9a73445
Apply coding conventions
2023-11-25 07:43:44 -08:00
Victor Zverovich
06f1c0d725
Clarify that calling non-const format is deprecated
2023-11-24 10:21:57 -08:00
Victor Zverovich
ffa5b14fe3
Make gtest-extra-test more portable
2023-11-24 10:09:21 -08:00
Victor Zverovich
bea7ecc710
Disable locale-specific tests on OpenBSD
2023-11-24 09:45:56 -08:00
Victor Zverovich
8a39388516
Fix the default locale in ostream_formatter
2023-11-24 09:24:43 -08:00
Peter Johnson
dd6f657a79
Remove this-> from decltype ( #3723 )
...
* Remove this-> from decltype
The latest version of MSVC doesn't like it, and removing it doesn't seem to harm anything.
* Add ifdef for GCC < 5
2023-11-22 09:46:04 -08:00
Victor Zverovich
c13753a70c
Fix handling of invalid Unicode in precision
2023-11-18 08:36:11 -10:00
Ole Bøe
864a8b5f38
fix: support optional<T> with format_as(T) ( #3713 )
...
Formatting a std::optional<T> where T had a custom format_as(T) function failed to compile with clang,
due to set_debug_format being hidden by private inheritance. This fix makes the function available through a using clause.
2023-11-16 15:02:33 -08:00
Victor Zverovich
649fe0fc8b
Fix handling of null strings with the s specifier
2023-11-15 17:03:01 -10:00
Kai Aoki
45e124ee43
Added workaround for old xcode compiler bug ( #3716 )
...
* Added macros to disable std::filesystem and std::variant as a workaround for old xcode bugs
* Change macro to positive logic
2023-11-15 09:19:08 -08:00
Victor Zverovich
045b05d79e
Revert CMake changes
2023-11-14 06:48:16 -10:00
Victor Zverovich
ec628561c2
Fix formatting
2023-11-13 06:41:28 -10:00
Luis Caro Campos
cbb18c237a
Add support for CMake 3.28 C++ modules ( #3679 )
2023-11-13 08:34:42 -08:00
Victor Zverovich
6b0082e6c7
Improve OpenBSD workaround
2023-11-07 09:24:33 -10:00
Petr Klima
52a99a67f7
Set PDB path for Visual Studio ( #3702 )
...
Ensure the PDB files are output into the same directory and with the same name
as the static library when using Visual Studio.
Resolves fmtlib#3701.
2023-11-07 08:22:52 -08:00
Victor Zverovich
4548d1eae2
Make write_escaped_path more portable
2023-11-07 05:46:15 -10:00
Victor Zverovich
050d41e857
Make get_path_string more portable
2023-11-06 14:34:53 -10:00
Victor Zverovich
1c023c0087
Update bootstrap
2023-11-06 08:20:01 -10:00
hotwatermorning
b35d4e40fe
fix: use FMT_HAS_INCLUDE instead of __has_include
2023-11-03 15:10:40 -07:00
hotwatermorning
acaf83f40f
feat: enable building with gcc 4.8
2023-11-03 02:38:05 +09:00
hotwatermorning
05aa783779
feat: include xlocale.h only if exists
2023-11-03 02:38:05 +09:00
dependabot[bot]
05dda9490d
Bump ossf/scorecard-action from 2.2.0 to 2.3.1 ( #3697 )
...
Bumps [ossf/scorecard-action](https://github.com/ossf/scorecard-action ) from 2.2.0 to 2.3.1.
- [Release notes](https://github.com/ossf/scorecard-action/releases )
- [Changelog](https://github.com/ossf/scorecard-action/blob/main/RELEASE.md )
- [Commits](08b4669551...0864cf1902 )
---
updated-dependencies:
- dependency-name: ossf/scorecard-action
dependency-type: direct:production
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-11-01 12:38:06 -07:00
dependabot[bot]
caf4fcb207
Bump github/codeql-action from 2.21.5 to 2.22.5 ( #3696 )
...
Bumps [github/codeql-action](https://github.com/github/codeql-action ) from 2.21.5 to 2.22.5.
- [Release notes](https://github.com/github/codeql-action/releases )
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md )
- [Commits](00e563ead9...74483a38d3 )
---
updated-dependencies:
- dependency-name: github/codeql-action
dependency-type: direct:production
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-11-01 12:37:23 -07:00
Carl Smedstad
e0d3e346d2
Wrap Char in array to avoid pointer arithmetic ( #3695 )
...
This resolves the following finding reported by Coverity Static Analysis
v2023.6.1 on line 1964 of fmt/include/fmt/format.h:
ptr_arith: Using &v as an array. This might corrupt or misinterpret
adjacent memory locations.
2023-10-31 14:05:46 -07:00
Victor Zverovich
19276d7325
Fix an inconsistentcy between to_string and format
2023-10-28 08:05:11 -07:00
Dimitrij Mijoski
2a2c6e676f
Fix flushing C++ iostreams before calling write_console() ( #3689 )
...
This change correctly implements https://wg21.link/P2539/ for both
C streams and C++ iostreams.
Fixes #3688 .
2023-10-25 13:13:31 -07:00
Roman Koshelev
3b7f58a8b3
add buffer flush before direct write
2023-10-24 16:02:37 -07:00
Victor Zverovich
e9bbd4069e
Update README.rst
2023-10-22 09:13:14 -07:00
Victor Zverovich
857cce7a83
Update README.rst
2023-10-22 08:45:50 -07:00
Victor Zverovich
081d5b0d8b
Update README.rst
2023-10-22 08:30:04 -07:00
Carson Riker
baae1ed658
add meson instructions to usage docs ( #3677 )
2023-10-18 11:53:47 -07:00
June Liu
2ac6c5ca8b
Fix error C2668 on Windows with option /std:c++latest ( #3680 )
...
* Namespace-qualify to avoid ambiguity with std::format_to for format-test.cc
When build fmt with MSVC under option /std:c++latest, it failed due to `error 2668: 'std::format_to': ambiguous call to overloaded function`, so add namespace to qualify the call to format_to to avoid this issue.
2023-10-16 09:54:02 -07:00
Victor Zverovich
d9063baf22
Fix perf regression in ostream::print
2023-10-15 08:23:36 -07:00
Victor Zverovich
f7542c5761
Apply clang-format
2023-10-14 06:52:43 -07:00
Victor Zverovich
130cf54cbc
Use a more sensible locale in tests
2023-10-08 10:49:21 -07:00
Victor Zverovich
8e0ca0589f
Use a more sensible locale in tests
2023-10-08 09:21:02 -07:00
Victor Zverovich
bf497ac068
Cleanup test
2023-10-08 07:30:08 -07:00
Richard Kellnberger
bb8d50f04b
add a suffix for days and fix the one for minutes ( #3664 )
2023-10-07 12:45:34 -07:00
Giel van Schijndel
f76603f21e
fix: make std::bitset formattable again ( #3660 )
...
* fix: make std::bitset formattable again
It used to be formattable via operator<<(ostream&) implicitly. Make it
formattable again, but this time via formatter specialization.
* fix: make nested_formatter constexpr default constructible
2023-10-03 09:53:47 -07:00
dependabot[bot]
f918289363
Bump actions/checkout from 4.0.0 to 4.1.0 ( #3666 )
...
Bumps [actions/checkout](https://github.com/actions/checkout ) from 4.0.0 to 4.1.0.
- [Release notes](https://github.com/actions/checkout/releases )
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md )
- [Commits](3df4ab11eb...8ade135a41 )
---
updated-dependencies:
- dependency-name: actions/checkout
dependency-type: direct:production
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-10-01 09:49:05 -07:00
Victor Zverovich
72e883e163
Diagnose unsupported code unit types
2023-10-01 08:37:21 -07:00
Christoph Reiter
b3bf23f3c4
Remove leftover usage of the __std_stream header ( #3663 )
...
2dd4fa8742fdac36468f8d 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
Joyce
349e1c48d1
Update README.rst ( #3661 )
...
Signed-off-by: Joyce <joycebrum@google.com>
2023-09-30 07:16:04 -07:00
Joyce
79dbd3f192
feat: add security policy to readme ( #3655 )
...
Signed-off-by: Joyce <joycebrum@google.com>
2023-09-28 16:50:14 -07:00
Victor Zverovich
2dd4fa8742
Remove an ostream hack incompatible with libc++ 17
2023-09-26 12:42:37 -07:00
Per Lundberg
44f3d8a77c
README.rst: fix broken LICENSE link ( #3653 )
...
The `.rst` suffix was dropped for this file a while ago.
2023-09-22 15:54:40 -07:00
Victor Zverovich
06b20387ae
Optimize fractional_part_rounding_thresholds
2023-09-22 13:26:57 -07:00
Victor Zverovich
649f2460db
Apply clang-format
2023-09-22 09:07:43 -07:00
Greg Sjaardema
7529af8f99
Workaround intel bug ( #3652 )
...
* Workaround intel bug
Potential workaround / restructure for the intel bug that is the cause of #3645 .
Make the variable in the external struct instead an embedded static constexpr variable in the only function that uses the variable.
* Finish the proposed change -- remove struct accessor
* Refactor proposed intel fix.
Moved variable out of function to avoid specialization on Float. Made it a separate function that is called from format_float.
* Fix incorrect function name.
* Add missing inline.
2023-09-20 18:57:55 -07:00
Giel van Schijndel
a3a74fa7f3
fix: mark fmt::streamed() as constexpr ( #3650 )
...
Because it's just performing a very basic type conversion that can be
done at constexpr time.
My use case simultaneously creates a
`fmt::basic_format_string<some_type_conversion<Args...>>` instance and
performs `some_type_conversion<Args>(args)...`. `some_type_conversion`
optionally applies `fmt::streamed(arg)` to a subset of types. This needs
to be `constexpr` because `basic_format_string`'s constructor is
`consteval`.
2023-09-19 08:42:34 -07:00
Sascha Scandella
8ef4db4b96
Use datatype of underlying data ( #3647 )
2023-09-19 07:31:36 -07:00
Vladislav Shchapov
492a99c964
Fix error: 'char_traits<custom_char>' is deprecated: char_traits<T> for T not equal to char, wchar_t, char8_t, char16_t or char32_t is non-standard and is provided for a temporary period. It will be removed in LLVM 18, so please migrate off of it. [-Werror,-Wdeprecated-declarations] ( #3634 )
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2023-09-18 15:46:17 -07:00
Victor Zverovich
3baaa8d899
Update docs
2023-09-18 14:54:52 -07:00
Victor Zverovich
0e01e46c11
Implement nested formatter
2023-09-18 14:21:21 -07:00
Dana Jansens
f6ca4ea199
Avoid a space in the UDL definition ( #3610 )
...
* Avoid a space in the UDL definition except on GCC before 4.9
Clang 18 has grown a warning about the space being deprecated which
is enabled by default in their nightly binaries. However GCC before 4.9
will reject the UDL definition unless there is a space there, so we need
to keep the space conditionally for it.
* Remove UDLs on GCC before 4.9 to simplify things
GCC before 4.9 rejects the syntax that is now
rejected on more modern compilers.
* Disable compile-error-test on GCC < 4.9
This avoids the UDL tests failing as GCC < 4.9 can not parse UDLs
without a space, but the space is malformed in modern compilers.
2023-09-18 08:09:42 -07:00
Gleb Mazovetskiy
a8a73da7e4
Add an option to avoid wchar APIs on Windows ( #3636 )
...
With this, fmt can be used on Windows 98 and the Original Xbox with:
set(FMT_OS OFF)
It is not exposed as a CMake option but one can define it manually
in the fmt subproject, e.g.:
target_compile_definitions(fmt PUBLIC FMT_WINDOWS_NO_WCHAR)
Fixes #3631
2023-09-17 08:49:51 -07:00
Victor Zverovich
aa3c5a4127
Clarify I/O error handling
2023-09-16 08:20:27 -07:00
Victor Zverovich
bfdf50d183
Minor cleanup
2023-09-16 08:16:59 -07:00
Chloe
571a9b7b26
Replace usage of C++17 library feature with C++11 ( #3638 )
2023-09-16 08:07:03 -07:00
Victor Zverovich
6c088be8ec
Cleanup handling of visibility
2023-09-16 07:40:08 -07:00
Vladislav Shchapov
016b1faede
Fix symbol leak ( #3627 )
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2023-09-16 07:26:36 -07:00
Dzmitry Ivaniuk
e25370093a
Remove unnecessary spaces ( #3642 )
2023-09-16 06:55:22 -07:00
Victor Zverovich
d4987546a4
Add an experimental nested formatter
2023-09-10 11:56:55 -07:00
Victor Zverovich
5bdce181f1
Mark styled_arg as a view to prevent lifetime issues
2023-09-09 08:16:45 -07:00
cyy
a4b7b24b7b
fix redundant redeclaration of ‘constexpr’ static data member ( #3630 )
2023-09-08 16:20:32 -07:00
Vinay Yadav
fac60bd4f5
Remove type cast as mxe(mingw32) compiler complains about useless-cast ( #3624 )
...
Remove type cast as mxe(mingw32) compiler complains about useless-cast
when FMT_PEDANTIC && FMT_WERROR options are enabled
"""
error: useless cast to type 'class fmt::v10::basic_format_args<fmt::v10::basic_format_context<fmt::v10::appender, char> >' [-Werror=useless-cast]
1449 | basic_format_args<buffer_context<char>>(args));
"""
2023-09-05 07:37:27 -07:00
dependabot[bot]
f5be4a8a9a
Bump actions/checkout from 3.5.3 to 4.0.0 ( #3623 )
...
Bumps [actions/checkout](https://github.com/actions/checkout ) from 3.5.3 to 4.0.0.
- [Release notes](https://github.com/actions/checkout/releases )
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md )
- [Commits](c85c95e3d7...3df4ab11eb )
---
updated-dependencies:
- dependency-name: actions/checkout
dependency-type: direct:production
update-type: version-update:semver-major
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-09-04 11:24:28 -07:00
Victor Zverovich
84e6661517
Workaround a gcc 6.4 issue
2023-09-04 11:23:14 -07:00
Victor Zverovich
ac3240439c
Update dependabot.yml
2023-09-04 10:23:00 -07:00
dependabot[bot]
8894ae87fe
Bump github/codeql-action from 2.21.4 to 2.21.5 ( #3622 )
...
Bumps [github/codeql-action](https://github.com/github/codeql-action ) from 2.21.4 to 2.21.5.
- [Release notes](https://github.com/github/codeql-action/releases )
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md )
- [Commits](a09933a12a...00e563ead9 )
---
updated-dependencies:
- dependency-name: github/codeql-action
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-09-04 10:19:51 -07:00
Victor Zverovich
ca608547e5
Workaround a C++11 issue
2023-09-04 10:07:14 -07:00
Victor Zverovich
23cf4055a0
Simplify URLs
2023-09-04 10:00:13 -07:00
Victor Zverovich
46c8301ee9
Remove rst2md
2023-09-04 09:38:06 -07:00
Victor Zverovich
a79a979828
Cleanup ranges test
2023-09-04 09:19:40 -07:00
Victor Zverovich
457bb6a98f
Merge the copyright comment since there are many contributors
2023-09-04 09:09:01 -07:00
Victor Zverovich
61aef41110
Cleanup changelog
2023-09-04 09:05:07 -07:00
Victor Zverovich
2a45fd30fe
Drop the rst suffix from the license file
2023-09-04 08:18:03 -07:00
Victor Zverovich
24296cff1c
Update ChangeLog.md
2023-09-04 08:16:16 -07:00
Victor Zverovich
3d1d20a6ac
Update ChangeLog.md
2023-09-04 08:10:34 -07:00
Victor Zverovich
0302c527c6
Update ChangeLog.md
2023-09-04 07:59:30 -07:00
Victor Zverovich
154eccfeb1
Convert changelog to markdown for compatibility with release notes
2023-09-04 07:15:18 -07:00
Victor Zverovich
35dc5def30
Revert "Bump actions/checkout from 3.5.3 to 3.6.0 ( #3615 )"
...
This reverts commit e8259c5298513e8cdbff05ce01c46c684fe758d8.
2023-09-04 07:12:32 -07:00
Victor Zverovich
e1fc481d65
Merge the copyright comment since there are many contributors
2023-09-04 06:54:07 -07:00
dependabot[bot]
e8259c5298
Bump actions/checkout from 3.5.3 to 3.6.0 ( #3615 )
...
Bumps [actions/checkout](https://github.com/actions/checkout ) from 3.5.3 to 3.6.0.
- [Release notes](https://github.com/actions/checkout/releases )
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md )
- [Commits](c85c95e3d7...f43a0e5ff2 )
---
updated-dependencies:
- dependency-name: actions/checkout
dependency-type: direct:production
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-08-28 13:55:28 -07:00
Victor Zverovich
6379251554
Update version
2023-08-28 06:29:25 -07:00
Victor Zverovich
951fd9e66f
Update changelog
2023-08-28 06:28:15 -07:00
Victor Zverovich
be89b9a41e
Merge branch 'release' of github.com:fmtlib/fmt
2023-08-28 06:24:29 -07:00
Victor Zverovich
28e2d3b640
Bump version
2023-08-26 08:29:50 -07:00
Victor Zverovich
f5e54359df
Update version
2023-08-26 08:20:41 -07:00
Victor Zverovich
a003ab93cf
Update changelog
2023-08-26 08:18:55 -07:00
Alex Guteniev
9b74160817
atomic_flag formatting (#3594 )
2023-08-25 08:06:10 -07:00
Victor Zverovich
a21690bdfa
Coding conventions
2023-08-25 07:46:32 -07:00
Victor Zverovich
c9efd8968c
Merge branch 'MathewBensonCode-master'
2023-08-25 07:44:44 -07:00
Mathew Benson
e786824053
Refactor Improvement on umul128 function
...
- Removal of direct access to members of uint128_fallback and instead
create the values at the callsite and pass them via the constructor of
uint128_fallback on the return statement.
2023-08-25 13:21:52 +03:00
Mathew Benson
2b20d7be6f
Refactor To remove friend function private access
...
- Remove umul128 friend function from uint128_fallback class using
non-const member access functions instead.
2023-08-24 00:55:43 +03:00
Mathew Benson
1f38ebbdb1
Add condition to include friend function in win32
2023-08-22 23:07:04 +03:00
Mathew Benson
e418179694
Fix for FMT_MODULE not compiling on GCC
2023-08-22 21:11:53 +03:00
dependabot[bot]
0bffed8957
Bump actions/checkout from 3.1.0 to 3.5.3 ( #3602 )
...
Bumps [actions/checkout](https://github.com/actions/checkout ) from 3.1.0 to 3.5.3.
- [Release notes](https://github.com/actions/checkout/releases )
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md )
- [Commits](https://github.com/actions/checkout/compare/v3.1.0...c85c95e3d7251135ab7dc9ce3241c5835cc595a9 )
---
updated-dependencies:
- dependency-name: actions/checkout
dependency-type: direct:production
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-08-21 10:58:34 -07:00
lukester1975
cc077a5e3b
Fix FMT_NO_UNIQUE_ADDRESS warning with clang-cl. ( #3600 )
...
See https://reviews.llvm.org/D110485 for info.
2023-08-20 10:21:50 -07:00
Mathew Benson
a992b3d1fc
Fix for Compilation Error When Using FMT_MODULE ( #3597 )
...
* FMT_EXPORT reorganization to fix compile error
- When compiling with FMT_MODULE, an error was being generated due to
use of FMT_EXPORT on a declaration within FMT_BEGIN_EXPORT and
FMT_END_EXPORT on `include/core.h`
- On `include/format.h` had to exclude the function vformat_to by ending
the export block just before it and beginning a new one after it.
2023-08-20 07:32:36 -07:00
Victor Zverovich
af1b768cc7
Update changelog
2023-08-19 08:22:50 -07:00
Victor Zverovich
2a7c45b54e
Update changelog
2023-08-19 08:19:01 -07:00
YuHuanTin
bd868f3a51
Improve compatibility with GBK #3598 ( #3599 )
2023-08-19 08:13:20 -07:00
Victor Zverovich
bbb784fb1b
Fix a gcc error about partial specialization after instantiation
2023-08-19 07:22:40 -07:00
Ben Deane
6c845f57e5
Fix formatted_size with FMT_COMPILE and format specs ( #3588 )
...
Addresses issue #3586
2023-08-15 06:45:48 -07:00
dependabot[bot]
a379595c5f
Bump actions/upload-artifact from 3.1.0 to 3.1.2 ( #3593 )
...
Bumps [actions/upload-artifact](https://github.com/actions/upload-artifact ) from 3.1.0 to 3.1.2.
- [Release notes](https://github.com/actions/upload-artifact/releases )
- [Commits](https://github.com/actions/upload-artifact/compare/v3.1.0...0b7f8abb1508181956e8e162db84b466c27e18ce )
---
updated-dependencies:
- dependency-name: actions/upload-artifact
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-08-14 14:02:10 -07:00
dependabot[bot]
9dfde78714
Bump ossf/scorecard-action from 2.1.2 to 2.2.0 ( #3592 )
...
Bumps [ossf/scorecard-action](https://github.com/ossf/scorecard-action ) from 2.1.2 to 2.2.0.
- [Release notes](https://github.com/ossf/scorecard-action/releases )
- [Changelog](https://github.com/ossf/scorecard-action/blob/main/RELEASE.md )
- [Commits](e38b1902ae...08b4669551 )
---
updated-dependencies:
- dependency-name: ossf/scorecard-action
dependency-type: direct:production
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-08-14 13:43:25 -07:00
dependabot[bot]
e92a705bdc
Bump github/codeql-action from 2.2.4 to 2.21.4 ( #3591 )
...
Bumps [github/codeql-action](https://github.com/github/codeql-action ) from 2.2.4 to 2.21.4.
- [Release notes](https://github.com/github/codeql-action/releases )
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md )
- [Commits](17573ee1cc...a09933a12a )
---
updated-dependencies:
- dependency-name: github/codeql-action
dependency-type: direct:production
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-08-14 11:49:24 -07:00
Zhanwei Wang
5a866fe852
Add formatter for std::atomic ( #3574 )
2023-08-14 08:34:31 -07:00
Vladislav Shchapov
e150ea0cc2
to_string supports types with format_as
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2023-08-13 08:39:52 -07:00
Joyce
29ce2ff8a8
Update README.rst
...
Signed-off-by: Joyce <joycebrum@google.com>
2023-08-13 07:32:33 -07:00
Joyce
2e1362addb
Create scorecard.yml
...
Signed-off-by: Joyce <joycebrum@google.com>
2023-08-13 07:32:33 -07:00
Victor Zverovich
e57ca2e368
Update version
2023-08-12 07:18:59 -07:00
Victor Zverovich
4c56612c67
Update changelog
2023-08-12 07:18:12 -07:00
Victor Zverovich
e1acd5f4d9
Bump version
2023-08-12 06:52:15 -07:00
Victor Zverovich
6ffee2f752
Handle new rst nodes
2023-08-12 06:51:40 -07:00
Victor Zverovich
ee475d6409
Update changelog
2023-08-07 15:12:34 -07:00
Victor Zverovich
ecc9141259
Update changelog
2023-08-07 14:41:53 -07:00
Victor Zverovich
d424862319
Fix fixed precision handling during rounding in long double
2023-08-07 13:56:53 -07:00
Victor Zverovich
3c1b3337de
Update changelog
2023-08-07 11:39:30 -07:00
Victor Zverovich
35fb69ebe0
Update changelog
2023-08-07 10:30:52 -07:00
Victor Zverovich
f92be35c09
Update changelog
2023-08-07 09:44:43 -07:00
Victor Zverovich
7a2f6ac210
Fix a comment
2023-08-07 09:33:45 -07:00
Victor Zverovich
744ff55549
Fix docs
2023-08-07 08:40:41 -07:00
Victor Zverovich
70ae48b005
Update changelog
2023-08-07 08:38:17 -07:00
Victor Zverovich
ebb10347c4
Merge branch 'master' of github.com:fmtlib/fmt
2023-08-07 08:18:13 -07:00
Victor Zverovich
1005720169
Clarify that visit_format_arg is deprecated
2023-08-07 08:17:55 -07:00
Vladislav Shchapov
aeb6ad4dd0
Added formatter for bit_reference-like types ( #3570 )
...
* Add test for std::vector<bool>::reference
Co-authored-by: Felix <felix-antoine.constantin@polymtl.ca>
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
* Add test for std::bitset<N>::reference
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
* Add test for const std::bitset<N>::reference and const std::vector<bool>::reference
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
* Add bit_reference-like formatter
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
* Use std::addressof
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
---------
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
Co-authored-by: Felix <felix-antoine.constantin@polymtl.ca>
2023-08-06 11:36:30 -07:00
Victor Zverovich
96d1fa22d4
Update changelog
2023-08-05 10:00:27 -07:00
5chmidti
8a4bec5cf5
fix ambiguous formatter lookup for flat_set ( #3561 )
2023-07-31 09:26:33 -07:00
Alexandre Bouvier
eacd51c249
cmake: fix FMT_PKGCONFIG_DIR path ( #3563 )
2023-07-31 08:11:56 -07:00
razaqq
757564f5cd
add missing inline specifier ( #3552 )
2023-07-27 12:12:00 -07:00
Jürgen Hock
f4214ae8dd
Use the U literal for unsigned integer constants. ( #3549 )
...
Fix MSVC Error C2398 Element '1': conversion from 'int' to 'const uint32_t' requires a narrowing conversion.
2023-07-27 11:43:00 -07:00
Victor Zverovich
aecf80d304
Update a comment
2023-07-26 15:10:12 -07:00
Martin Jeřábek
503d49286d
expose detail::throw_format_error ( #3551 )
...
This enables to only #include <fmt/core.h> when defining formatters.
2023-07-26 13:21:38 -07:00
Ozomahtli
4f46cb82f3
Remove std::copy usage. ( #3550 )
2023-07-26 07:27:01 -07:00
Victor Zverovich
3dec65b7fd
Use replacement character in path
2023-07-22 09:07:28 -07:00
Dmitry Alexeev
dbabb305c3
Turn off error-producing NVCC workaround when using c++20 ( #3544 )
2023-07-21 11:29:15 -07:00
Victor Zverovich
ac0ab8eff3
Improve path formatter
2023-07-20 17:49:12 -07:00
Victor Zverovich
40f35d6f04
Cleanup std formatters
2023-07-20 16:26:27 -07:00
Victor Zverovich
31c2c5679e
Cleanup formatters
2023-07-20 15:57:43 -07:00
Victor Zverovich
b2728a3170
Improve path formatter
2023-07-20 15:25:35 -07:00
Victor Zverovich
77e0b0e228
Cleanup chrono formatter
2023-07-20 15:00:59 -07:00
Victor Zverovich
e475859042
Fix overspecified tests
2023-07-20 14:09:22 -07:00
Victor Zverovich
436c131d4c
Optimize compiled format_to_n
2023-07-20 12:35:01 -07:00
Victor Zverovich
388bc296b7
Fix fixed formatting of small long doubles
2023-07-20 12:06:05 -07:00
Victor Zverovich
95e1ea5737
Clarify requirement on compiled formatter
2023-07-20 10:24:02 -07:00
Victor Zverovich
fb97cb2318
Suppress a bogus stringop-overflow warning
2023-07-20 09:53:54 -07:00
Victor Zverovich
dd5a9691f9
Clarify that data is not null-terminated
2023-07-20 07:36:30 -07:00
Kieran Clancy
72dc4491ea
Fix format_string_checker initialisation order ( #3542 )
...
Linter (clang-tidy) complains about uninitialised fields in
format_string_checker since types_ is passed to context_ before being
initialised. Fixes #3541 .
2023-07-20 07:30:45 -07:00
Victor Zverovich
9bea6ec04a
Don't use deprecated checked_array_iterator
2023-07-20 07:12:06 -07:00
Victor Zverovich
661b23edeb
Call parse on empty specs at compile time
2023-07-15 22:20:29 -07:00
Victor Zverovich
8e87d3a8be
Fix include
2023-07-15 09:02:19 -07:00
Alta
a474916560
Update CMakeLists.txt ( #3523 )
2023-07-05 06:38:38 -07:00
Barry Revzin
de4705f84d
Trying to improve errors in the unformattable case ( #3478 )
2023-07-01 06:46:04 -07:00
Mike Crowe
e4c8cfe38e
README: Add link to merged clang-tidy check ( #3515 )
...
A much-improved version of the main clang-tidy-fmt check for converting
printf and fprintf has landed in upstream LLVM. It converts to
std::print by default, but can be configured to convert to fmt::print
instead. It makes more sense for the README to point to that version
instead now.
2023-06-30 15:49:36 -07:00
Victor Zverovich
606f85f8b2
Workaround brain-damaged conversions
2023-06-26 16:06:24 -07:00
Tobias Schlüter
a331dbfb65
Fix type in assert message. ( #3508 )
...
Reviewed all strings in the file and found no other typos.
2023-06-26 11:35:29 -07:00
Petr Mánek
13156e54bf
Revert "add ability to build Apple framework using CMAKE_FRAMEWORK" ( #3496 )
...
This reverts commit ae25f7968efca30a6483ad7802ccfa5419f6330a.
Co-authored-by: Petr Manek <1252039-petrmanek@users.noreply.gitlab.com>
2023-06-18 20:41:07 -07:00
Victor Zverovich
9158bea1e1
Remove old grisu tests
2023-06-18 18:15:09 +03:00
Vladislav Shchapov
dd17f89a16
Fix for issue #3492 ( #3493 )
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2023-06-16 02:20:40 -07:00
Victor Zverovich
1daae555b3
Optimize format string compilation
2023-06-15 10:28:23 +03:00
Victor Zverovich
6ad301235f
Optimize code unit output in compiled format
2023-06-14 21:13:26 +03:00
Victor Zverovich
8732ad8773
Update docs
2023-06-13 19:24:18 +03:00
Victor Zverovich
5afb1821a9
Update docs
2023-06-13 18:58:15 +03:00
Victor Zverovich
a81135f2c8
Fix a link
2023-06-13 18:39:00 +03:00
Victor Zverovich
dfc34821ad
Update docs
2023-06-13 18:33:36 +03:00
Victor Zverovich
0765e7284c
Update docs
2023-06-13 18:12:27 +03:00
Victor Zverovich
977d887a4e
Suppress a bogus warning
2023-06-13 14:01:46 +03:00
Minty-Meeo
c86fe0b8d3
Give basic_memory_buffer allocator [[no_unique_address]] ( #3485 )
...
This allows stateless allocators to take up no space while still avoiding the empty base class optimization.
2023-06-13 01:22:19 -07:00
dependabot[bot]
5dbe0ff954
Bump actions/checkout from 3.5.2 to 3.5.3 ( #3486 )
...
Bumps [actions/checkout](https://github.com/actions/checkout ) from 3.5.2 to 3.5.3.
- [Release notes](https://github.com/actions/checkout/releases )
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md )
- [Commits](8e5e7e5ab8...c85c95e3d7 )
---
updated-dependencies:
- dependency-name: actions/checkout
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-06-12 22:46:54 -07:00
Minty-Meeo
de0757b578
Use FMT_TRY and FMT_CATCH in std.h ( #3482 )
...
This naked try-catch block prevents compilation when exceptions are disabled.
2023-06-10 21:28:13 -07:00
Victor Zverovich
8fe893c0ac
Update README.rst
2023-06-06 19:56:53 -07:00
Victor Zverovich
0f823df46a
Remove detail namespace hack
2023-06-04 15:19:50 -07:00
Hans-Martin B. Jensen
60fd9941c0
Use correct Char type in std::filesystem::path ( #3476 )
...
Godbolt repro:
https://godbolt.org/z/o4bjG6ddo
Co-authored-by: Hans-Martin B. Jensen <haje@eposaudio.com>
2023-06-02 14:12:57 -07:00
Hans-Martin B. Jensen
8abfc145be
Fix MSVC warning in std::chrono::time_point formatter ( #3475 )
...
* Fix MSVC warning in std::chrono::time_point formatter
The condition is constexpr causing MSVC level 4 warning:
warning C4127: conditional expression is constant
Changed the code to eliminate the warning
* Use detail::const_check
* Review: revert else condition
---------
Co-authored-by: Hans-Martin B. Jensen <haje@eposaudio.com>
2023-06-02 08:40:34 -07:00
Victor Zverovich
686b3353aa
Simplify typeid check
2023-06-01 09:32:44 -07:00
Victor Zverovich
b2106f3639
Tweak comments
2023-05-31 09:52:44 -07:00
Dana Jansens
35547d6003
Use const_check to silence MSVC warning
...
The condition is constexpr, so the compiler warns if a runtime check
is used as there's no need to generate code for it.
2023-05-31 09:25:53 -07:00
Dana Jansens
179c7e5a66
Use typeid() only if it's available
...
On MSVC it is always available, otherwise it depends on whether
RTTI is enabled.
2023-05-31 09:25:53 -07:00
Bin Lan
61fb3a15ff
Add VxWorks7 user space and kernel space support ( #3467 )
2023-05-31 06:35:07 -07:00
Victor Zverovich
bd393456ed
Remove FMT_*_DETAIL_NAMESPACE
2023-05-28 07:33:26 -07:00
Victor Zverovich
6be36af0d4
Remove udl_formatter
2023-05-27 17:16:36 -07:00
Victor Zverovich
2a35eeed8a
Remove unused data
2023-05-27 10:47:17 -07:00
Victor Zverovich
256a826d63
Consolidate formatters
2023-05-27 09:19:50 -07:00
Victor Zverovich
6369af37d3
Simplify formatters
2023-05-27 09:19:50 -07:00
Victor Zverovich
0b8404918e
Remove get_cached_power
2023-05-27 09:19:50 -07:00
Nico Rieck
171a020c82
Pass correct Char to base format_as formatter ( #3457 )
2023-05-24 14:50:47 -07:00
Victor Zverovich
d8f04e3995
Simplify ceil
2023-05-24 11:51:34 -07:00
Vladislav Shchapov
5e988f8dfa
Remove is_constant_evaluated() check
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2023-05-24 09:07:12 -07:00
Vladislav Shchapov
19b17618a9
Make constexpr ceil
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2023-05-24 09:07:12 -07:00
Vladislav Shchapov
c684a06d51
New CI: macOS 13, Xcode 14.3, C++ 20
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2023-05-24 09:07:12 -07:00
Victor Zverovich
abdb7fdf88
Update api.rst
2023-05-24 06:30:48 -07:00
rlalik
8b09fe2a0a
Fix example for user-defined types in documentation for 10.0.0 ( #3461 )
...
* Fix example for user-defined types in documentation for 10.0.0
* Fix the fix
2023-05-24 06:25:51 -07:00
Victor Zverovich
adad18a74d
Update ChangeLog.rst
2023-05-23 12:46:26 -07:00
Victor Zverovich
858e528abd
Use dragon in constexpr
2023-05-23 06:30:09 -07:00
Gleb Mazovetskiy
a54cb108d4
CMake: Do not fail on unknown compiler features ( #3453 )
...
If CMake does not know much about a compiler, `target_compile_features` will fail. Issue a warning instead.
2023-05-22 14:17:32 -07:00
Victor Zverovich
ef55d4f52e
Suppress a bogus gcc warning
2023-05-22 11:27:20 -07:00
Kasra Hashemi
70b6a6fa44
Update README.rst ( #3454 )
...
Fixed grammar and punctuation issues.
2023-05-22 10:35:24 -07:00
Victor Zverovich
6fe895410d
Remove invalid_arg_index
2023-05-21 19:57:17 -07:00
Joyce
d0652d225f
Create dependabot.yml ( #3452 )
...
Signed-off-by: Joyce <joycebrum@google.com>
2023-05-21 06:41:30 -07:00
Victor Zverovich
de8d0171a2
Simplify FMT_FORMAT_AS
2023-05-20 18:28:01 -07:00
Joyce
7401fe046a
Hash pin Github Workflows ( #3451 )
...
* hash pin doc.yml
Signed-off-by: Joyce <joycebrum@google.com>
* hash pin linux.yml
Signed-off-by: Joyce <joycebrum@google.com>
* hash pin macos.yml
Signed-off-by: Joyce <joycebrum@google.com>
* hash pin windows.yml
Signed-off-by: Joyce <joycebrum@google.com>
* hash pin github owned cifuzz.yml
Signed-off-by: Joyce <joycebrum@google.com>
---------
Signed-off-by: Joyce <joycebrum@google.com>
2023-05-20 06:33:37 -07:00
timsong-cpp
08ef0d0842
fix formatter<char*> ( #3432 )
2023-05-20 06:32:21 -07:00
Florimond Collette
d60b907f87
Replace mod_inv_25 by explicit value ( #3450 )
2023-05-18 11:26:19 -07:00
Florimond Collette
4ce086f731
remove code duplication ( #3448 )
...
* remove code duplication
* new interface for remove_trailing_zeros(uint32_t& n, int s = 0)
---------
Co-authored-by: Florimond Collette <4939681+florimondcollette@users.noreply.github.com>
2023-05-18 08:27:57 -07:00
Victor Zverovich
821f8cdb45
Detemplatize printf more
2023-05-17 12:34:12 -07:00
Victor Zverovich
0bf6ed7e1d
Cleanup printf
2023-05-17 10:53:25 -07:00
Victor Zverovich
e40e04face
Detemplatize printf_arg_formatter
2023-05-17 10:05:46 -07:00
Victor Zverovich
0a1c27281a
Detemplatize basic_printf_context
2023-05-17 09:29:20 -07:00
Victor Zverovich
2f605cc896
Deprecate wide printf
2023-05-17 08:58:55 -07:00
Victor Zverovich
1d54499ac0
Apply coding conventions
2023-05-17 08:21:13 -07:00
Victor Zverovich
3c6053c535
Cleanup basic_printf_context
2023-05-17 07:57:53 -07:00
Victor Zverovich
4a392adaa7
Remove basic_printf_parse_context
2023-05-17 07:47:42 -07:00
Victor Zverovich
b14913fae5
FMT_MODULE_EXPORT -> FMT_EXPORT
2023-05-17 07:38:06 -07:00
Arnaud Desitter
2117df299c
format-inl.h: address implicit int to bool conversion ( #3446 )
2023-05-17 06:39:20 -07:00
Victor Zverovich
616a493786
Revert Char* formatter removal
2023-05-17 06:11:11 -07:00
Barry Revzin
9a034b0d55
Always assert in FMT_THROW ( #3439 )
2023-05-17 06:04:36 -07:00
Victor Zverovich
e0fc0e85e3
Remove unneeded FMT_API
2023-05-16 17:25:20 -07:00
Victor Zverovich
552c43aba9
Improve long formatters
2023-05-14 07:07:36 -07:00
Victor Zverovich
d6846f4ac8
Clarify why byte formatter is in core
2023-05-13 08:04:53 -07:00
Victor Zverovich
aeedac5884
Remove unneeded specialization
2023-05-13 07:46:47 -07:00
Vladislav Shchapov
eaa6307691
Make hex float test more stable ( #3434 )
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2023-05-13 06:34:33 -07:00
Victor Zverovich
e82bf41a1a
Update README.rst
2023-05-12 16:24:47 -07:00
Victor Zverovich
e077396f5a
Update docs
2023-05-12 16:10:38 -07:00
Victor Zverovich
861facad0a
Fix a typo
2023-05-12 16:08:55 -07:00
Victor Zverovich
75bfe57614
Improve docs
2023-05-12 12:57:01 -07:00
Victor Zverovich
697e76ba30
Don't call init_named_args unnecessarily
2023-05-12 11:53:22 -07:00
Victor Zverovich
a425e0ff3b
Cleanup xchar API
2023-05-12 07:05:14 -07:00
Victor Zverovich
c36dd825ba
Remove unnecessary forwarding
2023-05-12 06:45:49 -07:00
Victor Zverovich
130b8fcdb9
Reduce template instantiations
2023-05-11 20:18:34 -07:00
Victor Zverovich
a47e8419be
Cleanup the core API
2023-05-11 19:07:56 -07:00
Victor Zverovich
ea49c91cd1
Cleanup argument construction
2023-05-11 18:43:39 -07:00
Patrick Geltinger
d7592ad8bf
Fix time_point formatting for durations with certain ratios ( #3430 )
...
* Fix time_point formatting
* Add timestamps_ratios tests
2023-05-11 15:25:21 -07:00
Victor Zverovich
ebfb2e6779
Remove unused alias
2023-05-11 10:51:32 -07:00
Victor Zverovich
5780269d57
Improve API safety
2023-05-11 10:19:56 -07:00
Victor Zverovich
b471192160
Fix a comment
2023-05-11 09:39:53 -07:00
Victor Zverovich
8f18e72df5
Improve API safety
2023-05-11 06:32:58 -07:00
Victor Zverovich
93d7cb12f1
Fix formatting
2023-05-10 16:29:47 -07:00
Victor Zverovich
0e4278717b
Remove unused macro
2023-05-10 16:27:16 -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
Victor Zverovich
a08196b149
Update ChangeLog.rst
2023-05-10 09:49:39 -07:00
Victor Zverovich
0398ba42ca
Update ChangeLog.rst
2023-05-10 09:39:04 -07:00
Victor Zverovich
a0b8a92e3d
Update version
2023-05-09 15:55:39 -07:00
Victor Zverovich
5cf2342aa2
Bump version
2023-05-09 15:37:01 -07:00
Victor Zverovich
fe9d39d7cb
Update changelog
2023-05-09 14:27:48 -07:00
Victor Zverovich
4c98561979
Update changelog
2023-05-09 14:25:56 -07:00
Victor Zverovich
403b271ed7
Update changelog
2023-05-09 14:20:59 -07:00
Victor Zverovich
2c991e1af6
Update changelog
2023-05-08 14:43:16 -07:00
Victor Zverovich
c984df9815
Remove an unused function from internal class
2023-05-08 13:35:23 -07:00
Victor Zverovich
fbf21ed224
Update changelog
2023-05-08 13:34:29 -07:00
Victor Zverovich
575583144e
Update changelog
2023-05-08 11:37:33 -07:00
Victor Zverovich
e7f6888c7a
Update changelog
2023-05-08 09:49:39 -07:00
Victor Zverovich
39db2dfd06
Update changelog
2023-05-08 09:41:57 -07:00
Victor Zverovich
9b7829e264
Update changelog
2023-05-08 09:15:07 -07:00
Victor Zverovich
1e0ce567ef
Fix formatting of paths containing invalid Unicode
2023-05-07 10:05:15 -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
Vladislav Shchapov
e84b00e014
Workaround to error: variable 'n' set but not used [-Werror,-Wunused-but-set-variable]
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2023-05-06 08:32:51 -07:00
Victor Zverovich
b12ffea4fb
Add filesystem_error test back
2023-05-06 07:49:46 -07:00
Victor Zverovich
f61f15cc5b
Suppress a false positive in gcc
2023-05-06 06:54:30 -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
d7a8e50cb5
Improve module testing ( #3397 )
...
* use the standard `test-main.cc` component instead of injected test infrastructure sources
* undo now obsolete commit `00235d8a` from July 2021
* Clang cannot import user-defined literals as it seems -> disable test
* Clang emits duplicate, non-mergeable copies of `detail::buffer`'s vtable, causing linker errors -> disable test
2023-05-03 07:56:24 -07:00
Victor Zverovich
02cae7e48a
Improve handling of Unicode in paths
2023-04-30 09:58:59 -07:00
Vertexwahn
53162142b2
Remove .bazelrc mention from Bazel related readme ( #3411 )
2023-04-29 16:25:00 -07:00
Vertexwahn
5bcf0d7f97
Bazel support ( #3406 )
...
* Bazel support: Remove not needed .bazelrc file
* Bump tested Bazel version
* Apply buildifier to format Bazel build files
* Add note about Bzlmod
2023-04-29 07:45:49 -07:00
Vertexwahn
f8c9fabd94
Fix spelling ( #3404 )
2023-04-25 11:47:37 -07:00
Jonathan Müller
62ff4e1dbd
Remove foonathan from maintainer list ( #3402 )
2023-04-23 13:35:05 -07:00
Daniela Engert
f449ca0525
Name vfprintf clashes with the identically named declaration in 'stdio.h' if that happens to be #included into the same TU. Fix this by using qualified name lookup instead of unqualified lookup that also enables ADL. ( #3400 )
2023-04-23 07:10:57 -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
Victor Zverovich
18154cc903
Simplify print
2023-04-22 14:03:40 -07:00
Victor Zverovich
0de789cf29
Update changelog
2023-04-22 09:20:28 -07:00
Daniela Engert
c039389223
export names only once ( #3392 )
...
names declared to be exported at the point of introduction into a namespace *must not* be (re-)declared as exported later in the TU, e.g. when they are redeclared, defined, or specialized. [module.export]/6
Drive-by fix found during module testing: add a missing `detail::` name qualification
2023-04-22 06:21:06 -07:00
Louis Wilson
93e81bb5d8
Fix C4365 (signed/unsigned mismatch) warning on 32-bit Windows ( #3398 )
2023-04-20 17:36:05 -07:00
Kevin Hwang
e7d6eb6794
Update tests to use recommended MOCK_METHOD ( #3395 )
2023-04-20 13:16:21 -07:00
Daniela Engert
18e7a2532b
Remove obsolete msvc workarounds ( #3388 )
...
This bug in the modules implementation is fixed since at least msvc 19.34, possibly even earlier like 19.32.
2023-04-19 17:09:51 -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
8ec94ac6a5
Use full path to pcm
2023-04-14 11:57:17 -07:00
Victor Zverovich
d97d8cea67
Push module check to test
2023-04-14 11:42:01 -07:00
Victor Zverovich
d8a2698e6c
Fix compilation as a C++20 module with gcc 13
2023-04-14 09:49:07 -07:00
Victor Zverovich
d9c19940a3
Update add_module_library
2023-04-13 17:13:52 -07:00
Victor Zverovich
4b5ae0b0ef
Remove unnecessary module support check
2023-04-13 16:53:45 -07:00
Victor Zverovich
75f3b1c094
Use add_module_library
2023-04-12 09:10:34 -07:00
Victor Zverovich
faf83406a9
Workaround cmake issue
2023-04-11 15:59:08 -07:00
Victor Zverovich
165814d57a
Add module support to CMake
2023-04-11 14:38:34 -07:00
June Liu
33f7150778
Fix error C2668 on msvc ( #3378 )
2023-04-11 06:27:28 -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
Victor Zverovich
4613d48fd3
FMT_EXPORT -> FMT_LIB_EXPORT
2023-04-10 08:24:23 -07:00
Victor Zverovich
4a4a2a2bd6
Fix diagnostics
2023-04-09 09:30:20 -07:00
Victor Zverovich
fce74caa15
Disable problematic implicit conversions
2023-04-09 09:08:46 -07:00
Victor Zverovich
02bf4d1c1c
Disable to_string_view ADL
2023-04-09 08:49:05 -07:00
Victor Zverovich
466e0650ec
Remove problematic workaround
2023-04-09 08:04:11 -07:00
Victor Zverovich
029caa8ea2
Update changelog
2023-04-09 07:01:06 -07:00
Victor Zverovich
e406ddbfaf
Remove broken part of the config
2023-04-08 08:46:43 -07:00
Victor Zverovich
9095679536
Update changelog
2023-04-08 08:39:17 -07:00
Björn Schäpers
7f46cb75b8
ranges: Fix extra semi ( #3374 )
2023-04-06 08:31:07 -07:00
Victor Zverovich
4e3f381058
Update changelog
2023-04-02 07:13:42 -07:00
Mikhail Paulyshka
d3c10f5167
fix compilation for MSDOS ( #3369 )
2023-04-01 13:40:53 -07:00
Victor Zverovich
ab956f600f
Update changelog
2023-04-01 08:04:47 -07:00
Vladislav Shchapov
97aedeab48
Workaround a double-double hexfloat format ( #3366 )
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2023-04-01 07:19:23 -07:00
Victor Zverovich
bce8d4ed08
Remove stray comment
2023-03-27 11:04:00 -07:00
Victor Zverovich
a91c7b286d
Cleanup the core API
2023-03-26 21:07:26 -07:00
Victor Zverovich
19c074e477
Remove deprecated fallback formatter
2023-03-26 08:45:06 -07:00
Victor Zverovich
41cfc739fe
Generalize format_as
2023-03-26 07:37:51 -07:00
Vladislav Shchapov
f6276a2c2b
Force use a signed char (On ARM char is unsigned by default) ( #3362 )
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2023-03-22 11:34:59 -07:00
Victor Zverovich
6002ddf825
Remove a deprecated option
2023-03-19 12:17:43 -07:00
Victor Zverovich
6549ffde8e
Improve format_as safety
2023-03-19 12:09:54 -07:00
Alecto Irene Perez
d9bc5f1320
Fix code causing spurious Wstringop-overflow warning
...
See #2989 , #3054 , and others
2023-03-18 09:29:54 -07:00
Victor Zverovich
9c5cd998d1
Remove unused functions
2023-03-18 08:40:16 -07:00
Barry Revzin
93bfa05382
%T is %H:%M:%S ( #3349 )
2023-03-18 07:16:22 -07:00
TheOmegaCarrot
d8e1c4265a
fix case of variant which is valueless by exception ( #3347 )
...
Co-authored-by: theomegacarrot <theomegacarrot@gmail.com>
2023-03-18 07:07:06 -07:00
tmartin-gh
e1720c0e51
Fix CUDA nvcc warning fmt/include/fmt/core.h(295): warning #1675-D: unrecognized GCC pragma ( #3352 )
2023-03-17 11:35:35 -07:00
Gleb Mazovetskiy
7f882918eb
write_floating_seconds: Fall back to ::round (#3343 )
...
On some toolchains, `std::round` is not available.
Fixes #3342
2023-03-12 09:34:19 -07:00
Shawn Zhong
cbc7b8d5c1
Cleanup dead variable ( #3338 )
2023-03-10 09:17:43 -08:00
Vladislav Shchapov
050293646f
Path is not escaped twice in the debug mode ( #3321 )
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2023-03-05 08:01:06 -08:00
Cloyce D. Spradling
3daf33837c
Enable consteval for Xcode 14.0.1 and later ( #3331 )
...
Co-authored-by: Cloyce D. Spradling <cloyce_spradling@apple.com>
2023-03-04 09:22:43 -08:00
Victor Zverovich
e0748e61dd
Fix recursion check in range formatting
2023-03-04 08:20:32 -08:00
Joyce
b94e1016fa
chore: set permission to cifuzz.yml ( #3328 )
...
Signed-off-by: Joyce <joycebrum@google.com>
2023-03-01 07:58:59 -08:00
Victor Zverovich
98699719f8
Make # handling consistent with std::format
2023-02-26 10:15:16 -08:00
Victor Zverovich
48dfbcaa95
Improve license and PR template wording
2023-02-26 09:08:53 -08:00
Antony Polukhin
c644c753d7
Add ' 🐙 userver framework' to the projects
2023-02-26 08:42:55 -08:00
Vladislav Shchapov
73b7cee7fb
Fix for issue #3325 ( #3326 )
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2023-02-26 06:59:41 -08:00
tom-huntington
5b8302079d
Add optional support ( #3303 )
2023-02-25 06:45:56 -08:00
luzpaz
3a69529e8b
Fix various typos ( #3312 )
...
Found via `codespell -q 3 -S ./test/gtest -L "fo,pres,seh,wronly"`
2023-02-21 15:14:41 -08:00
Victor Zverovich
76f520835f
Call element parse in tuple parse
2023-02-20 12:54:20 -08:00
Victor Zverovich
507c3042d8
class -> typename
2023-02-18 10:23:42 -08:00
Victor Zverovich
1741e90dec
Always call parse in range formatter
2023-02-18 09:58:37 -08: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
Vladislav Shchapov
e03753c4ac
Add ubuntu mirrors ( #3302 )
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2023-02-12 07:46:50 -08:00
Russell Greene
6e6eb63770
[msvc] fix warning about non-inline variable
2023-02-11 09:45:13 -08:00
Shawn Zhong
3c5464ba1c
Fix OpenBSD build error ( #3295 )
2023-02-11 08:46:28 -08:00
Victor Zverovich
655046d24f
Fix container adaptor formatting
2023-02-10 09:45:37 -08:00
Shawn Zhong
581c6292c9
Add formatters for container adapters ( #3279 )
2023-02-08 17:25:41 -08:00
Shawn Zhong
7718eeeacc
Implement glibc ext for sec, min, and hour ( #3271 )
2023-02-08 09:22:58 -08:00
Victor Zverovich
44e0eea94e
Use FMT_HAS_INCLUDE and apply clang-format
2023-02-08 07:19:10 -08:00
Roman-Koshelev
99070899b7
Fix errors setting of FMT_USE_FLOAT128 ( #3259 )
2023-02-08 07:15:02 -08:00
Barry Revzin
05e3a9233a
Allowing formatting non-copyable ranges. ( #3290 )
2023-01-27 12:29:57 -08:00
Ivan Shynkarenka
70db193f09
Visual Studio 2022: fmt/format-inl.h(1145,60): warning C4310: cast truncates constant value #3287 ( #3288 )
2023-01-26 11:46:30 -08:00
Victor Zverovich
a2c05a10ec
Workaround a bug in MSVC <= 19.22
2023-01-25 10:34:28 +13:00
Victor Zverovich
cae9bf45b9
Simplify apidoc comments
2023-01-25 09:32:03 +13:00
Shawn Zhong
87c066a35b
Implement println ( #3267 )
2023-01-24 12:30:00 -08:00
Vladislav Shchapov
9409b2e4d8
Workaround for incompatibility between libstdc++ consteval-based std::is_constant_evaluated() implementation and clang-14 ( #3281 )
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2023-01-22 11:29:34 -08:00
jk-jeon
f89cd276f7
Refactor countl_zero fallback ( #3276 )
2023-01-17 15:04:34 -08:00
Victor Zverovich
240b728d81
Report an error on overflow
2023-01-18 11:52:33 +13:00
Shawn Zhong
dfbb952b2c
Fix empty spec for time point ( #3275 )
2023-01-16 11:48:00 -08:00
Shawn Zhong
39971eb336
Fix localized format for float-point numbers ( #3272 )
2023-01-15 11:47:24 -08:00
jk-jeon
0f42c17d85
Implement a new formatting algorithm for small given precision ( #3269 )
...
Implement the formatting algorithm for small given precision discussed in https://github.com/fmtlib/fmt/issues/3262 and https://github.com/fmtlib/fmt/pull/2750
2023-01-14 11:30:20 -08:00
Kenny Weiss
bfc0924eac
Bugfix for fmt::printf on Power9 architecture with the XL compiler ( #3256 )
2023-01-13 11:36:00 -08:00
Shawn Zhong
676c2a107e
Fix negative subsec for time_point ( #3261 )
2023-01-11 11:36:50 -08:00
François Carouge
2c80cedc39
Fix standard default installation target presence ( #3264 )
2023-01-10 17:56:00 -08:00
Shawn Zhong
dda53082be
Support fill, align & width for time point ( #3260 )
2023-01-09 11:25:31 -08:00
Victor Zverovich
2622cd23e6
Simplify arg_mapper
2023-01-03 16:35:21 -08:00
Victor Zverovich
9e4a54fa6e
Disable remaining implicit conversions
2023-01-03 12:08:42 -08:00
Victor Zverovich
9ce6480676
Disble deprecated implicit enum conversions
2023-01-03 10:24:31 -08:00
Victor Zverovich
9121f9b1d3
Enable format_as for classes
2023-01-03 08:58:23 -08:00
Victor Zverovich
b7535365b2
Enable format_as for non-integral types
2023-01-02 13:37:13 -08:00
Victor Zverovich
09ed1ddb9c
Cleanup tests
2023-01-02 09:58:12 -08:00
Victor Zverovich
0ec65d99aa
Merge parse_presentation_type into parse_format_specs
2023-01-02 09:19:32 -08:00
Victor Zverovich
71e4e02722
Cleanup vprintf
2023-01-02 08:37:00 -08:00
Victor Zverovich
aad546baa5
Simplify presentation type parsing
2023-01-01 16:14:17 -08:00
Victor Zverovich
14a69fcc54
Use parse_align
2023-01-01 10:44:55 -08:00
Victor Zverovich
bf34ffd33f
Refactor format string parsing
2023-01-01 10:21:47 -08:00
Victor Zverovich
6056e07125
Simplify symbols
2022-12-30 19:35:05 -08:00
Victor Zverovich
aa99b86409
Minor cleanup
2022-12-30 18:51:15 -08:00
Victor Zverovich
6ade2eb4e5
Inline all_int_set
2022-12-30 17:05:08 -08:00
Victor Zverovich
caa6974942
Simplify parse functions
2022-12-30 16:34:36 -08:00
Victor Zverovich
a73a9b6a84
Refactor format string checks
2022-12-30 16:03:41 -08:00
Victor Zverovich
72785a3aba
Cleanup write
2022-12-30 13:53:55 -08:00
Victor Zverovich
0c3dd5ddd7
Remove redundant check
2022-12-30 12:55:19 -08:00
Victor Zverovich
739b600f40
Remove iterator shenanigans
2022-12-30 12:37:22 -08:00
Victor Zverovich
3710c4d38f
Link to dragonbox
2022-12-30 12:07:55 -08:00
Victor Zverovich
a05ba44df8
Simplify format string parsing
2022-12-30 11:23:42 -08:00
Victor Zverovich
ffb9b1d13c
Improve handling of signed types
2022-12-30 10:31:39 -08:00
Victor Zverovich
32190859ec
Fix handling of char
2022-12-30 09:11:42 -08:00
Victor Zverovich
8fe4d97d5e
Reduce template instantiations
2022-12-30 08:44:23 -08:00
Orvid King
7e5a959564
Fix build with MSVC C++20 modules ( #3254 )
...
When using fmt with C++20 modules under MSVC, it can end up requiring certain things to have storage that would not otherwise have needed to. Since I didn't see anything that was already doing detection for `inline constexpr` variable support, I've just moved the entire thing into the only function where it's used.
2022-12-28 19:58:57 -08:00
Victor Zverovich
9e60304869
Clarify that unused args are allowed
2022-12-28 06:58:04 -08:00
Victor Zverovich
7ad48c1f65
Cleanup core.h
2022-12-26 09:14:15 -08:00
Victor Zverovich
a921a596e7
Cleanup core.h
2022-12-26 07:46:31 -08:00
Victor Zverovich
3e762fdf5c
Use ignore_unused
2022-12-26 06:57:21 -08:00
Victor Zverovich
79981a2528
Cleanup ranges formatting
2022-12-25 20:05:20 -08:00
Victor Zverovich
bd12aaa98e
Simplify format string parsing
2022-12-25 12:31:38 -08:00
Victor Zverovich
b8f36207c9
Simplify format string parsing
2022-12-25 11:47:43 -08:00
Victor Zverovich
d907786f04
Move anchor to where it belongs
2022-12-25 10:58:54 -08:00
Victor Zverovich
f2355bbe5e
Fix docs
2022-12-25 10:25:35 -08:00
Victor Zverovich
f398c94761
Fix docs
2022-12-25 10:24:36 -08:00
Vladislav Shchapov
4841784e82
Simplify C99 strftime detection conditions
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2022-12-25 10:16:19 -08:00
Vladislav Shchapov
cb72c23e9e
Improve timezone tests
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2022-12-25 10:16:19 -08:00
Vladislav Shchapov
583f2d8209
Set timezone for chrono tests
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2022-12-25 10:16:19 -08:00
Victor Zverovich
32c4390704
Minor cleanup
2022-12-25 08:59:25 -08:00
Victor Zverovich
3a5e19fbf5
Minor cleanup
2022-12-25 08:42:16 -08:00
Victor Zverovich
dfb857ebef
Refactor format spec parsing
2022-12-25 07:25:32 -08:00
Victor Zverovich
9ea9b6bcb1
Cleanup arg id parsing
2022-12-24 16:33:57 -08:00
Victor Zverovich
2b0ff62a7f
Remove unused template arg from format_string_checker
2022-12-24 15:46:34 -08:00
Victor Zverovich
d1745084e0
Simplify parse context
2022-12-24 15:20:24 -08:00
Victor Zverovich
407e7b7b6d
basic_format_specs -> format_specs
2022-12-24 14:34:50 -08:00
Victor Zverovich
3cf9794755
Cleanup format string parsing
2022-12-24 13:47:20 -08:00
Victor Zverovich
934c8e5f76
Refactor precision parsing
2022-12-24 13:29:23 -08:00
Shawn Zhong
fc96938345
Remove empty semicolon
2022-12-24 09:54:55 -08:00
Victor Zverovich
f0ab112c34
Cleanup parsing
2022-12-24 09:40:35 -08:00
Victor Zverovich
9660e5b956
Remove redundant tests
2022-12-24 07:28:13 -08:00
Shawn Zhong
a585571e90
Ignore 0 character with align
2022-12-23 19:36:05 -08:00
Victor Zverovich
840ec8569d
Cleanup width handlers
2022-12-23 19:18:35 -08:00
Victor Zverovich
1dadeb8a33
Refactor width parsing
2022-12-23 18:29:59 -08:00
Victor Zverovich
275b4b3417
Remove obsolete parse-benchmark
2022-12-23 12:50:08 -08:00
Vladislav Shchapov
e004f1d699
Fix for issue #3241
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2022-12-23 12:26:20 -08:00
Victor Zverovich
bde1a6070d
Simplify fill and alignment parsing
2022-12-23 10:52:56 -08:00
Cleroth
040dc2a5d4
small typo in syntax.rst
...
0x1e was misread as 0x13, it looks like
2022-12-23 10:29:14 -08:00
Victor Zverovich
6a186bcd66
Localize FMT_USE_LOCAL_TIME
2022-12-21 14:52:52 -08:00
Shawn Zhong
8c56919bd2
Check chrono spec starts with %
2022-12-21 14:40:30 -08:00
Niall Douglas (s [underscore] sourceforge {at} nedprod [dot] com)
115001a3b1
Formatting of system clocks ought to be to UTC, not to local time.
...
This improves standards conformance of fmt.
2022-12-21 14:23:02 -08:00
Victor Zverovich
b90895412f
Fix formatting of named arguments with locale
2022-12-15 09:59:40 -08:00
Vladislav Shchapov
d072f1dc69
Fix for issue #3228
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2022-12-14 13:49:36 -08:00
Victor Zverovich
3999fd193a
Workaround an ADL issue
2022-12-11 09:32:17 -08:00
Vladislav Shchapov
c06e0b4ede
Extract timezone offset from timezone conversion functions
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2022-12-10 10:13:53 -08:00
Vladislav Shchapov
1bf302a4ea
Implement %Ez, %Oz for chrono formatter
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2022-12-10 10:13:53 -08:00
Victor Zverovich
f1733afd49
Pin godbolt example to specific version
2022-12-10 09:35:55 -08:00
Victor Zverovich
f61dcccc6e
Update README.rst
2022-12-06 11:52:37 -08:00
Victor Zverovich
f9bcbdcbcf
Update README.rst
2022-12-06 11:51:59 -08:00
Victor Zverovich
1a854b4aa5
Clarify what mod_inv_5 is
2022-12-04 08:36:03 -08:00
Radek Brich
62ceb181b1
fix #3105 - Compile-time error when mixing named argument with automatic indexing
2022-12-04 08:13:26 -08:00
Maksymilian Czudziak
b0c8263cb2
include/fmt/core.h: copy constructors removal
2022-11-30 16:44:42 -08:00
Vladislav Shchapov
d24be2e95c
Add countl_zero function
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2022-11-30 12:25:01 -08:00
Victor Zverovich
8d50d814db
Fix a chrono formatting issue found by fuzzing
2022-11-30 11:04:51 -08:00
Vladislav Shchapov
115ca96e0e
Bump tested CMake version to 3.25
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2022-11-30 08:09:32 -08:00
Vladislav Shchapov
886491625d
Remove workaround for GTest bug
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2022-11-30 07:16:37 -08:00
Vladislav Shchapov
74c51ff37e
Skip only strptime dependent test in scan-test
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2022-11-27 08:59:30 -08:00
Chris Thrasher
69ffedfe52
Use target_compile_features to specify C++ standard requirement
2022-11-26 11:03:17 -08:00
Victor Zverovich
fae6f7e081
Optimize range formatter
2022-11-26 08:50:46 -08:00
Victor Zverovich
a69e43c9d7
Update benchmark results
2022-11-25 09:52:02 -08:00
Vladislav Shchapov
91c024ed33
Rename leading_v -> leading_xdigit
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2022-11-25 09:08:40 -08:00
David Korczynski
649aa102d6
CI linux: add CIFuzz Github action
...
Signed-off-by: David Korczynski <david@adalogics.com>
2022-11-24 08:22:51 -08:00
Vladislav Shchapov
31364732dc
Replace snprintf-based hex float formatter with internal implementation
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2022-11-24 07:15:46 -08:00
Vladislav Shchapov
74d55a4938
Add missing operators
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2022-11-24 07:15:46 -08:00
Vladislav Shchapov
8276f1a204
Fix warning: the implicit by-copy capture of "this" is deprecated (EDG frontend)
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2022-11-22 10:51:00 -08:00
Vladislav Shchapov
81ebe70b9b
Fix warning: a class type that is not trivially copyable passed through ellipsis (EDG frontend)
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2022-11-22 10:51:00 -08:00
Vladislav Shchapov
3160847ebd
Enable C++17 tests on macOS
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2022-11-18 08:22:07 -08:00
Vladislav Shchapov
6a95f8c7eb
Add missing env CTEST_OUTPUT_ON_FAILURE
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2022-11-18 08:22:07 -08:00
thesmurph
c7980542d3
Skip the scan-test if strptime isn't defined ( #3184 )
...
cygwin and embedded systems. By default newlib doesn't provide strptime
in time.h because it was added in a later X/Open versions. Issue: #3178
2022-11-16 09:42:01 -08:00
Hans-Martin B. Jensen
7df30f91ae
Format unique_ptr with custom deleter ( #3177 )
...
* Format unique_ptr with custom deleter
Added deleter type to fmt::ptr unique_ptr overload. Deleter type is
part of the unique_ptr type.
* Review: apply clang-format
Co-authored-by: Hans-Martin B. Jensen <haje@eposaudio.com>
2022-11-13 21:54:32 -08:00
Victor Zverovich
d2e89c8b08
Document more chrono specs
2022-11-08 19:35:34 -10:00
Victor Zverovich
bd19593204
Document more chrono specs
2022-11-08 16:22:23 -10:00
Victor Zverovich
fd0d0ec8df
Document more chrono specs
2022-11-08 14:57:57 -10:00
Victor Zverovich
8e93434edd
Update README.rst
2022-11-08 11:21:16 -08:00
Victor Zverovich
fc07217d85
Make utf-8 detection compatible with gbk
2022-11-02 15:42:47 -07:00
Vladislav Shchapov
cb7373b469
Replace format with FMT_STRING. ( #3162 )
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2022-11-02 13:17:16 -07:00
Stepan Ponomaryov
795ed8abf5
Add precision modifier for seconds in chrono format ( #3148 )
...
Co-authored-by: Stepan Ponomarev <stepan.ponomarev@itiviti.com>
2022-11-02 11:58:51 -07:00
Barry Revzin
66d71a1b35
Fixing formatting of range of range of char. ( #3158 )
2022-11-02 11:04:54 -07: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
Stepan Ponomaryov
64965bdc96
Add locale getter in tm_writer ( #3147 )
...
* Add locale getter in tm_writer
* Apply clang-format
Co-authored-by: Stepan Ponomarev <stepan.ponomarev@itiviti.com>
2022-10-20 10:22:03 -07:00
Vladislav Shchapov
e1ffa7655d
Fix warning: conditional expression is constant. ( #3150 )
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2022-10-20 07:49:53 -07:00
Federico Razzoli
8c19bf3f2f
Mention MariaDB amongst the projects that use fmt ( #3145 )
2022-10-17 13:33:05 -07:00
Vladislav Shchapov
f67dbc9811
Remove duplicate implementation ( #3144 )
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2022-10-17 11:15:28 -07:00
Vladislav Shchapov
cd7202e039
Fix overflow error ( #3143 )
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2022-10-16 14:04:55 -07:00
Vladislav Shchapov
51d3685efe
Remove duplicate template parameter. ( #3142 )
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2022-10-14 16:34:24 -07:00
Patrick Roocks
9254cfa6f0
Support formatting of subseconds ( #3115 )
...
* Timestamp formatting shall print also subseconds, fixed a bug for fractional durations
2022-10-12 14:33:53 -07:00
Ihor Dutchak
cfb34a0607
Avoid using uint as a type name ( #3137 )
...
Sometime `uint` is defined as a global type by the project's code directly or by some 3rdparty libraries (e.g. Qt or OpenCV).
Some versions of MSVC (e.g. v16.11.15) gives a type shadowing warning:
```
3rdparty\fmtlib\fmt\include\fmt/format.h(3251): warning C4459: declaration of 'uint' hides global declaration
opencv2/core/hal/interface.h(45): note: see declaration of 'uint'
```
This also causes a compilation failure when `/WX` is used.
2022-10-12 10:53:47 -07:00
Tinson Lai
5ad7b71381
Fix options for C++20 experimental module in CMake ( #3134 )
...
* Fix options for C++20 experimental module in CMake
* Replace `FMT_CAN_MODULE` by `FMT_MODULE` in test/CMakeLists.txt
2022-10-12 08:23:12 -07:00
Vladislav Shchapov
d2c47c0df2
Fix broken condition ( #3129 )
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2022-10-07 13:46:45 -07:00
Victor Zverovich
491c32cbd9
Workaround gcc bug 103879
2022-10-05 21:12:38 -07:00
Vladislav Shchapov
662adf4f33
Move formatter<std::error_code> from fmt/os.h to fmt/std.h ( #3125 )
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2022-10-01 17:46:09 -07:00
Vladislav Shchapov
ad91cab374
Normalization of stdlib inline namespace names ( #3119 )
...
* Normalization of stdlib inline namespace names
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
* Remove all subnamespaces with names matching "__*" mask
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2022-09-29 09:52:38 -07:00
Vladislav Shchapov
0ccaed3a6c
Set CMAKE_RUNTIME_OUTPUT_DIRECTORY relative to CMAKE_CURRENT_BINARY_DIR instead of CMAKE_BINARY_DIR ( #3120 )
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2022-09-28 16:51:23 -07:00
Patrick Roocks
ad719619cc
Support formatting of std time_point with utc_clock ( #3110 )
2022-09-28 07:31:53 -07:00
Dimitrij Mijoski
6e0a5f7fba
Update CI to Ubuntu 20.04 and to newer versions of actions
2022-09-27 15:06:12 -07:00
huangqinjin
48f525d025
Add basic_format_string::get()
2022-09-22 19:50:04 -07:00
Victor Zverovich
0b5cb18b71
Use buffering in to_string to avoid bloat
2022-09-21 17:11:43 -07:00
Victor Zverovich
4c4f99a583
Update a godbolt link
2022-09-21 12:05:57 -07:00
Victor Zverovich
3272a7a3ce
Update an example
2022-09-21 12:03:18 -07:00
Victor Zverovich
a48e3355a6
Improve docs
2022-09-18 08:44:04 -07:00
Victor Zverovich
afcf424294
Update docs
2022-09-16 15:27:18 -07:00
Victor Zverovich
ac85afaab6
Simplify format_error
2022-09-16 14:25:14 -07:00
Victor Zverovich
3178bb9a26
Update docs
2022-09-16 10:29:53 -07:00
Victor Zverovich
cf58f64c54
Update docs
2022-09-16 10:28:00 -07:00
Victor Zverovich
e4e0ae3918
Use fmt/core.h in examples
2022-09-15 20:41:32 -07:00
Victor Zverovich
d65acc4e6c
Improve docs
2022-09-14 10:59:50 -07:00
Victor Zverovich
c9f790b061
Update docs
2022-09-14 10:58:52 -07:00
Victor Zverovich
6b8144a5ac
Update locale docs
2022-09-14 06:38:29 -07:00
Björn Schäpers
2d66ad5d33
Suppress -Wshadow
...
Solves:
/fmt/include/fmt/ostream.h:89:18: warning: declaration of 'fbuf' shadows a previous local [-Wshadow]
89 | else if (auto* fbuf = dynamic_cast<__gnu_cxx::stdio_filebuf<char>*>(rdbuf))
| ^~~~
C:/GIT/ok-mimot/libs/3rdParty/fmt/include/fmt/ostream.h:87:13: note: shadowed declaration is here
87 | if (auto* fbuf = dynamic_cast<__gnu_cxx::stdio_sync_filebuf<char>*>(rdbuf))
| ^~~~
2022-09-13 11:14:30 -07:00
Björn Schäpers
042af53324
Suppress -Wfloat-equal
...
Only NaN and Inf are not less than Inf and the check for NaN is done
before.
Solves:
.../fmt/include/fmt/format.h:2509:43: warning: comparing floating-point with '==' or '!=' is unsafe [-Wfloat-equal]
2509 | return !detail::isnan(value) && value != inf && value != -inf;
2022-09-13 11:14:30 -07:00
Victor Zverovich
192859c2b5
Optimize writing to buffers via back_insert_iterator
2022-09-12 15:32:12 -07:00
Sergiu Deitsch
e2f6d7665b
fix gcc <= 7.1 compile errors
2022-09-12 10:43:16 -07:00
Vladislav Shchapov
61844b6b67
Fix build error on GCC-9
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2022-09-12 07:02:29 -07:00
Vladislav Shchapov
7a752e75ff
New CI: GCC-9
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2022-09-12 07:02:29 -07:00
Victor Zverovich
94ceb38a09
Improve locale API
2022-09-11 09:33:31 -07:00
Victor Zverovich
58c4c012fa
Disable slow windows build and simplify write_loc
2022-09-11 08:35:09 -07:00
Victor Zverovich
c3494ae364
Refactor float localization
2022-09-11 07:47:27 -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
76705fc2ee
Update doc
2022-09-10 15:06:09 -07:00
Vladislav Shchapov
21c2137e77
Add class name output to formatter for std::exception ( #3076 )
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2022-09-10 08:04:00 -07:00
Victor Zverovich
ecffca6726
Don't parse '}' as fill
2022-09-07 17:33:31 -07:00
gerboengels
3176e0fad7
Add locale overload for formatted_size ( #3084 ) ( #3087 )
...
Co-authored-by: Gerbo Engels <gerbo.engels@ortec-finance.com>
2022-09-07 14:15:12 -07:00
VinaCC
1feb430faa
Fix intellisense on Windows ( #3082 )
...
__INTELLISENSE__ is 1 on vs2022 and clang, causing FMT_HAS_INCLUDE, FMT_USE_FCNTL, etc to be 0.
That results in VS and VSCode having a lot of linter errors while code compiles just fine.
2022-09-05 11:50:06 -07:00
Victor Zverovich
b98ffb7dbd
Improve locale handling
2022-09-04 21:07:30 -07:00
Vladislav Shchapov
bac53951b8
Add starts_with to basic_string_view. ( #3080 )
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2022-09-04 11:41:16 -07:00
Victor Zverovich
d59b89e9cd
More locale
2022-09-04 11:23:45 -07:00
Victor Zverovich
58a5563a9f
Implement grouping
2022-09-04 09:01:26 -07:00
Victor Zverovich
1b94271ff6
Add support for UTF-8 digit separators
2022-09-03 11:01:05 -07:00
Victor Zverovich
768d79a839
Implement format_facet
2022-09-03 09:42:36 -07:00
Victor Zverovich
91ecb38a34
Localize negative integers
2022-09-03 07:01:11 -07:00
Victor Zverovich
aec3bb5d0a
Workaround C complex.h idiocy
2022-09-03 06:35:55 -07:00
NewbieOrange
29c6000137
Simplify is_variant_like_ check, fix compile error before GCC 11 ( #3072 )
...
Co-authored-by: Vladislav Shchapov <vladislav@shchapov.ru>
Co-authored-by: Vladislav Shchapov <vladislav@shchapov.ru>
2022-09-02 21:08:07 -07:00
Victor Zverovich
fec5515c55
num_format_facet -> format_facet
2022-09-02 18:55:08 -07:00
Victor Zverovich
f187274d36
Add loc_value
2022-09-02 13:45:23 -07:00
Victor Zverovich
fc5e59fe4a
Don't use stringstream
2022-09-02 13:05:26 -07:00
Victor Zverovich
d6a8704605
Improve locale support
2022-09-02 11:52:19 -07:00
Victor Zverovich
56c72a671c
Reduce locale dependency
2022-09-02 10:22:11 -07:00
Zach Toogood
4191477b98
Add formatter for std::exception ( #3062 )
...
Co-authored-by: fekir <federico.kircheis@gmail.com>
Co-authored-by: Alexey Ochapov <alexez@alexez.com>
Co-authored-by: Vladislav Shchapov <vladislav@shchapov.ru>
Co-authored-by: fekir <federico.kircheis@gmail.com>
Co-authored-by: Alexey Ochapov <alexez@alexez.com>
Co-authored-by: Vladislav Shchapov <vladislav@shchapov.ru>
2022-09-02 08:33:37 -07:00
Victor Zverovich
75383a87f9
Inline trivial functions
2022-09-01 18:25:23 -07:00
Victor Zverovich
48327a82e3
Make format.h compile faster
2022-09-01 17:06:47 -07:00
Victor Zverovich
b79ed4105a
Remove unnecessary type_identity
2022-09-01 16:29:08 -07:00
Victor Zverovich
64e29893cf
Improve locale support
2022-09-01 14:48:43 -07:00
Victor Zverovich
0b0f7cfbfc
hip workaround
2022-09-01 09:18:53 -07:00
Greg Sjaardema
40e414d823
Fix compilation error with gcc-7.2.0
...
Without the added line, the gcc-7.2.0 compiler will give the following error:
```
/opt/compiler-explorer/libs/fmt/trunk/include/fmt/format.h:1240:8: error: uninitialized variable 'buffer' in 'constexpr' function
Char buffer[digits10<UInt>() + 1];
^~~~~~
```
See https://godbolt.org/z/fh7TMs9qs
2022-08-30 10:55:57 -07:00
Vladislav Shchapov
33b4c33c5b
Requires FMT_CONSTEXPR20 support
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2022-08-29 13:33:48 -07:00
Vladislav Shchapov
a07411c2b9
Disable compile-time checks for dynamic width/precision test for LCC and compiler without std::is_constant_evaluated()
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2022-08-29 13:33:48 -07:00
Vladislav Shchapov
797d82b21a
Disable non-type template args for LCC
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2022-08-29 13:33:48 -07:00
Vladislav Shchapov
a553521d6d
Disable "GCC optimize" pragma for LCC
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2022-08-29 13:33:48 -07:00
Victor Zverovich
a33701196a
Update version
2022-08-27 08:57:10 -07:00
Victor Zverovich
1f575fd5c9
Bump version
2022-08-27 08:55:39 -07:00
Victor Zverovich
c7635288f7
Fix docs, take 2
2022-08-27 08:28:07 -07:00
Victor Zverovich
c8ed78e315
Fix docs
2022-08-27 08:01:47 -07:00
Victor Zverovich
e07cfb2068
Update changelog
2022-08-27 07:55:06 -07:00
Victor Zverovich
1dc7af5693
Fix markup
2022-08-27 07:52:58 -07:00
Victor Zverovich
f7d21c3a1a
Update changelog
2022-08-27 07:51:24 -07:00
Victor Zverovich
a55bcb24bd
Update changelog
2022-08-27 07:13:36 -07:00
Victor Zverovich
30cb2b3122
Remove appveyor config
2022-08-27 06:52:25 -07:00
Victor Zverovich
cf8d3c3229
Update changelog
2022-08-26 16:17:42 -07:00
Victor Zverovich
3c3cb6f6b1
Update changelog
2022-08-26 16:00:24 -07:00
Victor Zverovich
91481f255c
Detemplatize code_point_length_impl
2022-08-26 15:45:00 -07:00
Vladislav Shchapov
f98048b621
Fix bugs in utf8 decoder ( #3056 )
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2022-08-26 15:37:15 -07:00
Victor Zverovich
4a8e2949bb
Fix formatting of ranges of code unit types
...
Thanks Nicole Mazzuca.
2022-08-26 13:48:58 -07:00
Vladislav Shchapov
3a3b0709e2
Disable bogus -Wstringop-overflow on GCC 11 ( #3054 )
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2022-08-24 12:37:34 -07:00
Victor Zverovich
e724bbea16
Fix wchar_t corner cases
2022-08-24 12:23:10 -07:00
Bernhard Manfred Gruber
665d9779ec
Disable non-type template args for nvhpc ( #3053 )
2022-08-24 10:56:45 -07:00
Victor Zverovich
13d07c6a3d
Apply doc fixes retroactively
2022-08-24 09:16:12 -07:00
Victor Zverovich
391f922acc
Improve error reporting in format string compilation
2022-08-24 09:05:15 -07:00
Victor Zverovich
dc59d3df3f
Fix a warning in gtest
2022-08-24 07:18:14 -07:00
Vladislav Shchapov
489dabbd31
Fix decoder on broken utf8 sequences. ( #3044 )
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2022-08-24 07:13:27 -07:00
Victor Zverovich
541cd21838
Fix locale name (thanks Mikhail Paulyshka)
2022-08-20 08:06:20 -07:00
Victor Zverovich
1f95c34381
Fix sign handling with large code units
2022-08-20 07:46:58 -07:00
Victor Zverovich
779449fd99
Belarusify test
2022-08-20 07:37:15 -07:00
Olli Lupton
fbb568bce0
nvhpc/22.3: workaround for c++17 mode. ( #3043 )
2022-08-18 11:30:40 -07:00
Haowei Hsu
36c23bd5fd
Prepare for deprecating FindPythonInterp module. ( #3040 )
...
* Prepare for deprecating FindPythonInterp module.
Since FindPythonInterp module is deprecated after CMake 3.12, it is better to start using the new FindPython module.
* Add the proper punctuation in comments.
2022-08-17 14:18:39 -07:00
Rémi Burtin
9ff0f3a7d6
Fix docs
2022-08-16 11:31:11 -07:00
Dimitrij Mijoski
fd41110d38
Add MinGW to CI
2022-08-14 08:40:38 -07:00
Dimitrij Mijoski
fc23cfbf4e
Fix testsuite on MinGW + MSVCRT
...
Fixes #2952 . The testsuite indirectly called strftime() with conversion
specifiers defined only in C99. In MSVCRT this function conforms only to
C89. Only in the updated UCRT this functon provides the functionality of
C99.
2022-08-14 08:40:38 -07:00
Mark Santaniello
fd93b633b8
Constexpr formatted_size ( #3026 )
...
* Constexpr formatted_size
* Add C++20 tests for gcc 9 and 10
* Adjust unit test to require __cpp_lib_bit_cast
2022-08-10 09:35:30 -07:00
Victor Zverovich
7fb8d33f9d
Fix compile-time width/precision type check
2022-08-09 16:10:02 -07:00
Dimitrij Mijoski
8bd02e93b2
Reduce conditional compilation
2022-08-09 09:05:01 -07:00
Dimitrij Mijoski
d9c1c7353a
Use is_utf8() in print(std::ostream&, ...)
...
This patch concludes the Unicode support for print(ostream&, ...)
2022-08-09 09:05:01 -07:00
Vladislav Shchapov
682e097bee
Remove -Wl,--as-needed linker option
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2022-08-07 06:51:41 -07:00
Hannes Friederich
b9087ee587
Suppress unused typedef warning
2022-08-05 15:27:01 -07:00
Victor Zverovich
df56fdf883
Clarify docs for compile-time checks
2022-08-05 07:00:34 -07:00
Vladislav Shchapov
90c48b8525
Remove double code execution
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2022-08-05 06:15:59 -07:00
Vladislav Shchapov
5a8b7cd742
Add comment
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2022-08-05 06:15:59 -07:00
Vladislav Shchapov
36a25d75b4
Reuse detail::string_literal in the chrono formatter
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2022-08-05 06:15:59 -07:00
Vladislav Shchapov
6c9304b2c2
Replace ParseContext with basic_format_parse_context
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2022-08-05 06:15:59 -07:00
Vladislav Shchapov
24ab9dd19e
Remove duplicate method
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2022-08-05 06:15:59 -07:00
Vladislav Shchapov
a95dc17017
Remove unused condition
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2022-08-05 06:15:59 -07:00
Victor Zverovich
5f774c0aed
I shouldn't be there
2022-08-02 16:35:50 -07:00
Victor Zverovich
6567df7f24
Update README.rst
2022-08-02 06:50:09 -07:00
Vladislav Shchapov
6c6b1fbf6e
Workaround a bug in MSVC
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2022-08-02 06:46:02 -07:00
Dimitrij Mijoski
9beddd08f9
Improve CI on Windows
2022-08-02 06:46:02 -07:00
Victor Zverovich
6452e3c9eb
Fix a typo in example
2022-08-02 06:26:19 -07:00
Dimitrij Mijoski
756822ba39
Fix Unicode handling for ostream under Windows with libc++. ( #3001 )
...
Also replaces the SFIANE tricks applied in
ce7ecdb7afb207dadf55c8ae457e14aa44e7f537 with conditional compilation.
The code was too complicated along with the other trick to access private
data members.
2022-07-30 06:49:21 -07:00
Barry Revzin
0b2862a1e4
Range formatter ( #2983 )
...
* Implement range_formatter and format_kind
* Attempted gcc 4.8 fix
* gcc 4.8 interprets inaccessible as a hard error (instead of... not available)
* Attempting to delete set_debug_format.
* clang-format
* Different implementation of FMT_STATICALLY_WIDEN
* Renaming copy_str_range to copy_str.
* I guess I need a definition
* Forgot to delete these.
* Other PR comments.
2022-07-29 13:55:16 -07:00
Jean-Michaël Celerier
258000064d
Add fmt:: namespace to doc ( #3009 )
...
Otherwise as-is the example does not compile on Visual Studio due to the conflict with std::format_to:
https://gcc.godbolt.org/z/qe4jEvvqY
2022-07-29 13:10:09 -07:00
Victor Zverovich
e9ca7ea472
Suppress a bogus warning
2022-07-28 07:12:49 -07:00
Dimitrij Mijoski
81f1cc74a7
Improve Unicode handling when writing to an ostream on Windows ( #2994 )
...
* Refactor detail::print() by splitting into two functions.
The part with SetConsoleW is a separate function, without fwrite().
* Make Unicode handing when writing to std::ostream more robust.
Calls to print(ostream&) in the special Unicode case on Windows fallback
to writing via ostream::write instead of fwrite().
* Fix Unicode handling when writing to an ostream on GCC on Windows
* Add TODO note about detail::is_utf8()
* Fix warning -Wundef
* Fix for non-Windows OSs
* Fix building as DLL on Windows
* Refactor
* Suppress warning
2022-07-23 08:03:31 -07:00
Dimitrij Mijoski
bbcb129e02
Reduce filesize of the tests on MinGW ( #2995 )
...
This patch removes the workaround applied here
1acfd07f1ed9d4055833a70d9195e57aee7bbe77.
MinGW is not tested on Appveyor anymore.
2022-07-22 20:11:33 -07:00
Victor Zverovich
48e0a59222
Implement compile-time checks for dynamic width/precision type
2022-07-22 17:00:40 -07:00
Federico
bc5c7c50fd
Fixes IBM XLC behavior with uint128 fallback ( #2985 )
...
* Fixes IBM XLC behavior with uint128 fallback
* Replace legacy xlc with clang-based xlc
* simplify xlc intrinsics handling
Co-authored-by: Federico Busato <fbusato@nvidia.com>
2022-07-22 13:49:17 -07:00
Victor Zverovich
00adc7120d
Add a regression test for here be dragons
2022-07-22 11:08:00 -07:00
Haowei Hsu
c48be439f1
Add additional search paths for doxygen on Windows
...
`find_program(DOXYGEN doxygen)` didn't find the executable automatically even if I installed Doxygen on Windows. Therefore, I added some additional search paths.
2022-07-19 08:59:18 -07:00
Victor Zverovich
371f9c71ca
Fix even in format_dragon
2022-07-19 08:36:34 -07:00
Victor Zverovich
91abfcd6cf
Suppress an msvc warning
2022-07-16 08:57:09 -07:00
Victor Zverovich
deeab54b40
Remove unused include
2022-07-15 20:11:35 -07:00
Junekey Jeon
688a627d6c
Remove unused constants.
2022-07-14 15:25:35 -07:00
Junekey Jeon
9bb1605f10
Remove some branches
2022-07-14 15:25:35 -07:00
Junekey Jeon
8061d9afbe
Simplify Dragonbox implementation
2022-07-14 15:25:35 -07:00
Victor Zverovich
d82e1a108d
Make sure the correct fmod overload is called
2022-07-13 12:42:03 -07:00
Vladislav Shchapov
defa04e730
Fix for EDG frontend (Intel, NVHPC compilers) ( #2982 )
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2022-07-13 11:34:43 -07:00
Barry Revzin
92d36e82c4
The n specifier for ranges ( #2981 )
...
* The n specifier for ranges.
* Flipping flag polarity.
2022-07-12 10:08:38 -07:00
Federico
0db43cf7fe
Pointless comparison warnings ( #2971 )
...
Co-authored-by: Federico Busato <fbusato@nvidia.com>
2022-07-11 12:29:39 -07:00
Victor Zverovich
05be7a0764
Use FMT_USE_FLOAT128 instead of __SIZEOF_FLOAT128__
2022-07-10 08:54:34 -07:00
Victor Zverovich
2a1b3ac629
Fix large shift in uint128_fallback
2022-07-10 08:27:21 -07:00
Daniel Krügler
e1d3d3a326
Exclude recursive ranges from the formatter specialization for ranges ( #2974 )
...
* 2954: Add test case
* Eliminate extra-test and merge it into existing std-test instead. Add conditionals for filesystem::path testing that does not run into the ambiguity problem.
* #2968 : Introduce additional compile-time predicate to detect recursive ranges and reject them in formatter specialization for ranges. In addition, introduce additional wrapper traits for the individual logical operands of the complete range constraints
* #2968 : Eliminate preprocessor condition that enables the formatter specialization for std::filesystem::path
* #2968 : Eliminate preprocessor condition that enables the test for the formatter specialization for std::filesystem::path
* Use own bool_constant, which is available for all C++ versions
* Reintroduce previous workaround but restrict to VS 2015 for now
* Comma fix
* - Rename is_not_recursive_range to is_nonrecursive_range and add comment that explains it being depending on is_range being true
- Merge has_fallback_formatter_delayed into is_formattable_delayed and add comment that explains it being depending on is_not_recursive_range being true
- Replace disjunction in formatter specialization by has_fallback_formatter_delayed
- Get rid of unneeded detail:: prefixes within namespace detail
2022-07-10 06:26:23 -07:00
Victor Zverovich
b761f1279e
Improve forward using the idea from Jonathan Müller
2022-07-07 16:48:17 -07:00
Victor Zverovich
cc1926942f
Inline std::forward
2022-07-07 14:41:54 -07:00
Michael Winterberg
d5e9166f54
Fixed typo in changelog example.
2022-07-05 19:07:39 -07:00
Vladislav Shchapov
b31d1a75a0
Add xchar support for fmt::streamed().
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2022-07-05 19:07:06 -07:00
Victor Zverovich
c4ee726532
Update version
2022-07-04 09:50:06 -07:00
Victor Zverovich
fa2eb2d2e3
Bump version
2022-07-04 09:37:29 -07:00
Victor Zverovich
35f72bf210
Bump version
2022-07-04 09:10:55 -07:00
Victor Zverovich
d22f00d7e4
Update changelog
2022-07-04 09:01:56 -07:00
Victor Zverovich
4e8d215606
Update changelog
2022-07-04 08:56:18 -07:00
Victor Zverovich
84eecb6561
Prune CI configs
2022-07-04 08:51:35 -07:00
Victor Zverovich
55727e3b21
More compile-time checks
2022-07-04 08:25:27 -07:00
Victor Zverovich
1010b7f148
Update docs
2022-07-04 08:18:44 -07:00
Victor Zverovich
2ac51fc448
Update changelog
2022-07-04 08:13:27 -07:00
Vladislav Shchapov
831132293b
Workaround for Microsoft Visual Studio 2022 Internal compiler error.
...
D:\a\fmt\fmt\test\compile-test.cc(362,3): fatal error C1001: Internal compiler error. [D:\a\fmt\build\test\compile-test.vcxproj]
(compiler file 'D:\a\_work\1\s\src\vctools\Compiler\CxxFE\sl\p1\c\constexpr\constexpr.cpp', line 8635)
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2022-07-04 07:18:21 -07:00
Vladislav Shchapov
115e00e0b9
Replace __cplusplus with FMT_CPLUSPLUS.
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2022-07-04 07:18:21 -07:00
Vladislav Shchapov
94114b05ca
New CI: Microsoft Visual Studio 2022.
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2022-07-04 07:18:21 -07:00
Daniel Krügler
d2a2320820
Fix partial specialization problem for filesystem for Visual Studio ( #2957 )
...
* #2954 : Provide std::conjunction and std::disjunction substitutes
* #2954 : Use conjunction and disjunction substitute to make formatter specializations for ranges and maps more robust (especially for Visual Studio compiler family)
* #2954 : As workaround for older MSVC compilers split formatter<std::filesystem::path> partial template specialization into two explicit specialization.
* 2954: Add test case
* Provide simplified implementations of conjunction and disjunction
* Remove workaround explicit specializations if the partial specialization would cause an ambiguity error
* Eliminate extra-test and merge it into existing std-test instead. Add conditionals for filesystem::path testing that does not run into the ambiguity problem.
2022-07-03 11:06:54 -07:00
Victor Zverovich
0c06c81da8
Deprecated implicit conversion of enums to ints for consistency with scoped enums
2022-07-03 09:02:22 -07:00
Vladislav Shchapov
c12b4c0cf1
New CI: GCC-8 C++17, Clang-8 C++17.
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2022-07-02 08:34:52 -07:00
Vladislav Shchapov
99bb5b1d17
Fix std::variant, std::filesystem::path tests on GCC-8, Clang-7,8.
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2022-07-02 08:34:52 -07:00
Victor Zverovich
e29c2bc60e
Update docs
2022-06-30 08:13:34 -07:00
Victor Zverovich
c65e4286bf
Update changelog
2022-06-29 09:02:08 -07:00
Victor Zverovich
69c24e47e8
Update changelog
2022-06-28 11:00:56 -07:00
jehelset
6a775e9560
Add support for 'std::variant' in C++17 ( #2941 )
...
Add support for 'std::variant' in C++17.
For C++17, if all the alternatives of a variant are formattable
the variant is now also formattable. In addition 'std::monostate'
is now formattable.
Moves implementation into 'std.h', and tests into 'std-test.cc'.
Avoid fold-expression since MSVC was crashing.
Add section for 'fmt/std.h' in API-docs.
2022-06-26 07:28:01 -07:00
Victor Zverovich
51535866d0
Update docs
2022-06-25 09:13:29 -07:00
Victor Zverovich
3ef5caa9fe
Update docs
2022-06-25 09:11:10 -07:00
Victor Zverovich
dccd3e6742
Fix docs
2022-06-25 09:04:31 -07:00
Victor Zverovich
9cb02aaaad
Fix UDLs
2022-06-25 08:52:10 -07:00
Victor Zverovich
e6d478f8e8
Update changelog and docs
2022-06-25 08:33:57 -07:00
Victor Zverovich
2d931b1497
Add fmt::streamed
2022-06-24 09:26:24 -07:00
Victor Zverovich
0506a5733d
Update changelog
2022-06-24 09:04:56 -07:00
Jonathan W
e8bd2a804d
Fix enable_ifs for map formatter ( #2944 )
2022-06-23 08:24:11 -07:00
Victor Zverovich
7c56e11ecf
Update changelog
2022-06-23 07:40:56 -07:00
Victor Zverovich
69a20db081
Update changelog and fix an apidoc comment
2022-06-22 08:32:46 -07:00
Victor Zverovich
7a2a97c882
Update changelog
2022-06-22 07:31:34 -07:00
jehelset
5682338891
Fix is_formattable for tuple-like types. ( #2940 )
2022-06-19 08:25:58 -07:00
Vladislav Shchapov
f0de128449
Remove /source-charset:utf-8 compile option.
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2022-06-19 07:37:39 -07:00
Victor Zverovich
eaa8efb950
Fix ofstream handling in msvc
2022-06-16 15:02:33 -07:00
Victor Zverovich
fb991e9d3b
Update changelog
2022-06-12 12:17:39 -07:00
Juraj
8e47cfd1cd
fix -Wsign-conversion warning
2022-06-11 12:31:33 -07:00
David Chisnall
2471875867
Make the tests pass on a CHERI system.
2022-06-10 07:02:03 -07:00
Victor Zverovich
b135f1c014
Refactor handling of argument types
2022-06-09 17:03:33 -07:00
Victor Zverovich
f61a1e8132
Add format_arg_types
2022-06-09 15:50:30 -07:00
Mattes D
48b7e3dafb
Added a FMT_STRING wrapper for system_error() call.
...
This enables the use of FMT_ENFORCE_COMPILE_STRING on MSVC 2019.
2022-06-07 07:00:57 -07:00
Victor Zverovich
4bb3af7a6b
Improve compile-time checks
2022-06-05 13:58:04 -07:00
Vladislav Shchapov
d02c582b96
Fix 'duplicate symbol' error.
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2022-06-05 07:17:25 -07:00
Vladislav Shchapov
b59d8c3a23
Make std::filesystem::path formatter utf-8 compatible.
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2022-06-04 10:10:21 -07:00
Vladislav Shchapov
232e21d51f
Add utf-8 test for std::filesystem::path formatter.
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2022-06-04 10:10:21 -07:00
Alex
8644654190
Docs: add comment about empty format context range
2022-06-02 08:40:29 -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
9d60395953
Fix compilation on ppc64
2022-05-31 13:53:15 -07:00
Victor Zverovich
a2681aabcb
Debug ppc failure
2022-05-31 11:30:22 -07:00
Julian Amann
bfc5767368
Add support for std.h in Bazel build
2022-05-30 16:52:25 -07:00
Victor Zverovich
798d09bb70
Debug ppc failure
2022-05-30 13:06:34 -07:00
Victor Zverovich
8c7cf51395
Cleanup
2022-05-30 08:21:01 -07:00
Victor Zverovich
cdfacb4345
Cleanup parse_format_string
2022-05-30 07:30:11 -07:00
Victor Zverovich
926ddd0631
Move compile string to detail
2022-05-30 07:06:36 -07:00
Victor Zverovich
cb682f36f4
Move to_string_view to detail
2022-05-29 22:51:31 -07:00
Victor Zverovich
156744ad47
Simplify fmt::runtime
2022-05-29 21:18:52 -07:00
Victor Zverovich
d9c7166cf0
bi_iterator -> base
2022-05-29 21:01:57 -07:00
nathannaveen
11316b29af
chore: Set permissions for GitHub actions
...
Restrict the GitHub token permissions only to the required ones; this way, even if the attackers will succeed in compromising your workflow, they won’t be able to do much.
- Included permissions for the action. https://github.com/ossf/scorecard/blob/main/docs/checks.md#token-permissions
https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#permissions
https://docs.github.com/en/actions/using-jobs/assigning-permissions-to-jobs
[Keeping your GitHub Actions and workflows secure Part 1: Preventing pwn requests](https://securitylab.github.com/research/github-actions-preventing-pwn-requests/ )
Signed-off-by: nathannaveen <42319948+nathannaveen@users.noreply.github.com>
2022-05-29 19:12:52 -07:00
Victor Zverovich
fe6eb792d5
Cleanup check_format_string
2022-05-29 19:01:06 -07:00
Victor Zverovich
054b1d9808
Remove unused include
2022-05-29 18:24:10 -07:00
Victor Zverovich
e927149f8e
Cleanup macros
2022-05-29 17:23:02 -07:00
Victor Zverovich
1761e2666a
Remove FMT_CONSTEXPR_DECL
2022-05-29 16:42:58 -07:00
Victor Zverovich
d6b568a6cc
Cleanup string_view checks
2022-05-29 16:30:39 -07:00
Victor Zverovich
c83a5d42bb
FMT_MSC_VER -> FMT_MSC_VERSION
2022-05-29 15:39:08 -07:00
Victor Zverovich
27cd68c301
Cleanup macros
2022-05-29 14:45:59 -07:00
Victor Zverovich
08be4abb30
Remove FMT_NVCOMPILER_VERSION
2022-05-29 13:54:31 -07:00
Victor Zverovich
661b192545
Remove FMT_HEADER_ONLY_CONSTEXPR20
2022-05-29 13:22:45 -07:00
Victor Zverovich
d1026fa5d2
Remove extern format_float
2022-05-29 13:11:19 -07:00
Victor Zverovich
7e63b600b6
Make to_string work with __float128
2022-05-29 12:23:57 -07:00
Victor Zverovich
b2ea212cd1
Update README.rst
2022-05-29 11:44:09 -07:00
Victor Zverovich
c2fcdc54e2
Move format_float to format.h for __float128
2022-05-29 11:30:33 -07:00
Victor Zverovich
2b9037a190
Move basic_fp to format.h for compile-time formatting
2022-05-29 07:32:52 -07:00
Victor Zverovich
542785ccbf
Get rid of detail::bits
2022-05-29 07:10:36 -07:00
Vladislav Shchapov
65dd2ea52c
Use write_escaped_string to std::filesystem::path.
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2022-05-28 07:48:02 -07:00
Vladislav Shchapov
9860f67cde
Improve xchar support for std formatters.
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2022-05-28 07:48:02 -07:00
Vladislav Shchapov
03b1b2838e
Improve std::filesystem::path formatter.
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2022-05-28 07:48:02 -07:00
Victor Zverovich
4f9311e689
Fix definition of error_handler::on_error
2022-05-27 10:49:19 -07:00
Ivan Shynkarenka
652fea45a9
Visual Studio 2022: fmt/format.h(1526,27): warning C4127: conditional expression is constant #2908
2022-05-27 10:38:13 -07:00
Vladislav Shchapov
1f9eae7e31
Add xchar support for write_escaped_string.
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2022-05-27 08:36:38 -07:00
Nick Kiesel
90b68783ff
Skip cmake targets inclusion if fmt::fmt already exists ( #2907 )
2022-05-27 08:35:40 -07:00
Victor Zverovich
ce246aaf74
Remove deprecated APIs
2022-05-22 07:10:09 -07:00
Victor Zverovich
edeb3d8091
Remove deprecated APIs
2022-05-21 19:57:38 -07:00
Victor Zverovich
496aff7c33
Remove deprecated APIs
2022-05-21 15:12:38 -07:00
Victor Zverovich
f5cdf7cb04
Simplify snprintf_float
2022-05-21 12:34:21 -07:00
Victor Zverovich
440512f08d
Remove deprecated APIs
2022-05-21 12:20:31 -07:00
Victor Zverovich
621eb80bbb
Remove deprecated APIs
2022-05-21 11:34:07 -07:00
Victor Zverovich
5c7d315ded
Remove locale.h
2022-05-21 08:19:09 -07:00
Victor Zverovich
c6324009ba
Add initial double-double support
2022-05-21 07:32:54 -07:00
frithrah
147e8ca580
Fix Windows max mix-up ( #2903 )
2022-05-18 16:35:26 -07:00
Victor Zverovich
6bf039d750
Add std: 🧵 :id formatter
2022-05-17 16:37:19 -07:00
Victor Zverovich
9730fb0156
Fix path formatter
2022-05-17 14:29:49 -07:00
Victor Zverovich
f0903ad9df
Add a path formatter
2022-05-16 17:32:25 -07:00
Victor Zverovich
8833f386e4
Merge branch 'master' of github.com:fmtlib/fmt
2022-05-15 09:51:38 -07:00
Victor Zverovich
5ab9d39253
Namespace-qualify format_to to avoid conflict with std::format_to
2022-05-15 09:51:20 -07:00
Victor Zverovich
af5644c274
Update README.rst
2022-05-15 06:29:15 -07:00
Ivan Shynkarenka
3e28dc021c
VS2022 17.2: C4189: 'zero': local variable is initialized but not referenced #2891 ( #2892 )
...
VS2022 17.2: C4189: 'zero': local variable is initialized but not referenced #2891
Co-authored-by: Ivan Shynkarenka <Ivan_Shynkarenka@epam.com>
2022-05-13 07:04:34 -07:00
Victor Zverovich
f6f920a1a8
Tweak a comment and apply clang-format
2022-05-11 14:40:26 -07:00
Victor Zverovich
ae963e444f
Implement constexpr isfinite to avoid producing NaN
2022-05-11 08:43:22 -07:00
Victor Zverovich
358f5a7e50
Make precision computation consistent with width
2022-05-11 06:34:51 -07:00
Sean McBride
f63afd161f
Fixed all clang -Wsigned-enum-bitfield warnings ( #2882 )
...
Made enums involved in bitfields unsigned by specifying their underlying type as unsigned char.
Due to a bug, when specifying an underlying type, gcc < 9.3 warns about bitfields not being big enough to hold the enum, even though they are. So keep the plain enum for old gcc.
An example of the bug is here:
https://godbolt.org/z/58aEv8zEq
2022-05-09 11:03:51 -07:00
Victor Zverovich
7e4ad40171
Add initial support for double-double
2022-04-24 07:43:02 -07:00
Vladislav Shchapov
ffb5e6a732
Suppress a -Wliteral-range warning on Apple M1 ( #2861 )
2022-04-19 11:10:18 -07:00
Victor Zverovich
5d804ee7fe
Fix handling of subnormals in exotic FP
2022-04-17 08:56:35 -07:00
Victor Zverovich
86e27ccb41
Suppress a warning
2022-04-12 09:30:29 -07:00
Victor Zverovich
192f79aaae
Fix handling of locale separators in FP formatting
2022-04-12 08:00:17 -07:00
Victor Zverovich
395cf0f03e
Fix detection of unformattable pointers
2022-04-12 06:45:46 -07:00
Victor Zverovich
fc429d18b6
Avoid overhead on sensible platforms
2022-04-11 16:52:34 -07:00
Victor Zverovich
ce7ecdb7af
Replace conditional compilation with SFINAE
2022-04-11 12:16:05 -07:00
Victor Zverovich
8751a03a04
Fix Unicode handling when writing to an ostream
2022-04-10 09:46:01 -07:00
Victor Zverovich
c55175a589
Add an issue template
2022-04-08 07:53:42 -07:00
Mattias Ljungström
a935ac3e60
MSVC CMake generation optimization ( #2852 )
2022-04-08 06:27:23 -07:00
Victor Zverovich
22d31b31f0
Add a __float128 test
2022-04-03 14:56:29 -07:00
Victor Zverovich
f607e3e970
Add __float128 support
2022-04-03 12:58:06 -07:00
Victor Zverovich
686de58886
Implement 128-bit constant mul in bigint
2022-04-03 07:24:18 -07:00
Victor Zverovich
02eb215f2f
Replace uint128_wrapper with uint128_fallback
2022-04-02 18:01:41 -07:00
Victor Zverovich
b4dc7a1d34
Add 128-bit operations to bigint
2022-04-02 09:29:13 -07:00
Victor Zverovich
ef54f9aa38
Suppress -Wfloat-equal
2022-04-01 12:18:22 -07:00
Jean-Michaël Celerier
288c3b928b
Remove dead code in ostream.h format_value
2022-03-29 10:21:19 -07:00
Victor Zverovich
96930161f9
Implement 128-bit operator+= for uint128_fallback
2022-03-27 08:07:54 -07:00
Victor Zverovich
b41890c1e5
Make arg_mapper SFINAE-friendly again
2022-03-27 07:10:15 -07:00
Victor Zverovich
e2408f37c8
Check if formatter is not defined if there is format_as
2022-03-26 09:44:49 -07:00
Victor Zverovich
db5b8993ac
Fix formatting of std::byte via format_as
2022-03-26 09:01:30 -07:00
Vladislav Shchapov
1c83eaf75e
Fix incompatible between Jinja2 >= 3.1 and sphinx 3.3.0
2022-03-26 07:30:17 -07:00
Sean McBride
5379063b54
Fixed clang -Wreserved-identifier warings
...
Created FMT_UNCHECKED_TYPE that resolves to special identifier _Unchecked_type for Microsoft, but to a dummy string otherwise. Using
_Unchecked_type is invalid because underscore + uppercase is a reserved identifier.
2022-03-24 07:33:43 -07:00
Sean McBride
b591fc87dc
Fixed all clang -Wreserved-id-macro warnings (on macOS at least)
...
Avoid defining various reserved identifiers (starting with underscore and capital letter). Fortunately, they were all Windows-only, so it was easy to conditionalize them in Window-only preprocessor checks.
2022-03-24 07:33:43 -07:00
Victor Zverovich
17dda58391
constexpr -> const for portability
2022-03-23 21:14:22 -07:00
Victor Zverovich
7ffe87c0bc
Fix docs
2022-03-22 19:13:01 -07:00
Victor Zverovich
3c4273dd09
Simplify UDL
2022-03-22 17:43:37 -07:00
Victor Zverovich
36d95c9fcc
Fix docs
2022-03-22 17:31:31 -07:00
Victor Zverovich
44abd1f483
Update signatures in docs and ostream.h
2022-03-22 16:05:30 -07:00
Victor Zverovich
db745986f2
Workaround broken std::numeric_limits
2022-03-20 08:50:52 -07:00
Victor Zverovich
8271e43e5e
Improve __float128 support and use constexpr
2022-03-20 07:20:41 -07:00
Victor Zverovich
3f9b7433a3
Improve __float128 support
2022-03-19 09:44:14 -07:00
Victor Zverovich
71778e8b90
Specialize float_info for __float128
2022-03-19 08:39:16 -07:00
Victor Zverovich
f024565c3f
Improve exponent handling in Dragon
2022-03-19 08:23:32 -07:00
Victor Zverovich
e7f31f5cdb
Cleanup format_dragon
2022-03-18 16:03:19 -07:00
Victor Zverovich
3c61799fbf
Cleanup fuzzing mode
2022-03-18 12:01:52 -07:00
Victor Zverovich
4e39e13085
Remove xchar.h include from ostream.h
2022-03-18 10:53:15 -07:00
timsong-cpp
ac0d9d5fe2
Issue #2816 : also strip named-arg for the fallback formatter
2022-03-18 10:11:14 -07:00
timsong-cpp
4ad90578f7
Fix #2818 : diagnose unformattable arguments in unpacked case
2022-03-18 10:11:14 -07:00
timsong-cpp
17ba99c1d2
Fix #2817 : add compile-time checking to ostream overloads of fmt::print
2022-03-18 10:11:14 -07:00
timsong-cpp
3d19be282a
Fix #2816 : strip named argument wrappers for compile-time checking
2022-03-18 10:11:14 -07:00
Victor Zverovich
c076a54a4d
Move snprintf_float to format.h
2022-03-18 08:31:31 -07:00
Victor Zverovich
0419d23882
Add FMT_USE_FLOAT128
2022-03-18 07:43:51 -07:00
cre
69396347af
Update color.h ( #2815 )
...
fixed typo in comment
2022-03-17 10:55:02 -07:00
Victor Zverovich
c51604a0e1
Reduce the number of configs
2022-03-15 18:20:59 -07:00
Victor Zverovich
587dc9946d
Remove windows-2016 env no longer suppported by GA
2022-03-15 18:16:13 -07:00
Victor Zverovich
1f3d44b859
Update std::tm/chrono docs
2022-03-15 16:53:51 -07:00
Victor Zverovich
bc654faf82
Add is_floating_point that works with __float128
2022-03-15 08:26:05 -07:00
Victor Zverovich
26bffce66d
Simplify basic_memory_buffer
2022-03-15 07:15:52 -07:00
Victor Zverovich
ed18ca3eae
Implement isnan
2022-03-14 20:37:46 -07:00
Victor Zverovich
a204b8dde7
Add initial __float128 support
2022-03-14 19:34:41 -07:00
Victor Zverovich
b6b003b073
Cleanup test
2022-03-14 15:48:38 -07:00
Victor Zverovich
f2543b0a98
Add initial support for 128-bit floats
2022-03-14 14:00:15 -07:00
Victor Zverovich
72f487562d
Simplify float_info
2022-03-14 13:37:03 -07:00
Victor Zverovich
f91f61cd13
Reuse num_significand_bits
2022-03-14 11:34:24 -07:00
Victor Zverovich
9a1beab574
Workaround Windows API garbage
2022-03-11 17:31:39 -08:00
Riccardo Brugo
a8fe8becf4
Fix compilation error for ranges with ADL begin/end ( #2807 )
...
* Use `range_begin`/`end` to get formatted range iterators
* Add test for adl `begin`/`end`
* Apply clang-format
* Simplify tests
2022-03-11 11:36:39 -08:00
Victor Zverovich
f6bcb25e16
Remove extra dot
2022-03-10 16:26:17 -08:00
Victor Zverovich
b4a4189d0c
Fix handling of implicit bit
2022-03-10 15:34:56 -08:00
Riccardo Brugo
32d477e5f1
Add styled in documentation ( #2805 )
2022-03-10 12:24:47 -08:00
Victor Zverovich
0b7c045a2f
Simplify _cf
2022-03-08 15:31:51 -08:00
Victor Zverovich
c10fffecdc
Make _cf visible in the doc build
2022-03-08 11:00:04 -08:00
rtobar
dcfbe4a77a
Document output_file default behavior correctly ( #2803 )
...
The documentation for output_file incorrectly says that opening an output file happens with `file::WRONLY | file::CREATE` by default, but this includes `file::TRUNC` is also included since 119f7dc3d.
2022-03-08 10:02:22 -08:00
Riccardo Brugo
8c9bc070f5
Implement styled arguments ( #2793 )
...
* Implement styled arguments
* Inherit from formatter<Arg> to get the underlying `parse` and `format`
* Move styled_arg definition into the previous detail block
* Change styled_arg ctor parameters names to avoid shadowing members
* Move const before auto
* Remove redundant constructor for styled_arg
* Use the iterator instead of the buffer in styled_arg::format
* Remove unnecessary `styled` overloads
* Remove defaulted text_style parameter in styled function
2022-03-08 09:50:14 -08:00
Greg Sjaardema
5bc39d363a
Eliminate intel compiler warnings ( #2802 )
...
The intel compiler emits `declaration hides parameter "loc" ..." and similar warnings for "out" and "args" since the function arguments are the same as other visible symbols. This is for intel-2021.3.0 20210609.
2022-03-07 15:34:33 -08:00
Boris Dalstein
e3d688e79a
Fix warning C4251: class fmt::v8::file needs to have dll-interface ( #2797 )
...
* Fix warning C4251: class fmt::v8::file needs to have dll-interface
* Add CMake target dependency between test-main and fmt
2022-03-07 12:09:48 -08:00
Victor Zverovich
8d4f3e91b2
Update docs
2022-03-06 10:12:40 -08:00
Barry Revzin
0cef1f819e
Fixing formatting of certain kinds of ranges of ranges. ( #2787 )
...
* Fixing formatting of certain kinds of ranges of ranges.
* Renaming const_range to range_type.
2022-03-04 16:21:00 -08:00
Victor Zverovich
5c0d656401
Fix apt install
2022-03-03 15:50:25 -08:00
Victor Zverovich
d416a995ea
Update README.rst
2022-03-01 13:53:02 -08:00
Victor Zverovich
3f67a12477
Update README.rst
2022-03-01 13:48:54 -08:00
YuTArrUsO
cc57e35974
Update godbolt link in the readme ( #2789 )
2022-02-25 13:47:23 -08:00
Victor Zverovich
86477f7ecc
Fix size computation
2022-02-22 17:21:07 -08:00
Björn Schäpers
0742606f19
Fix Conversion Warning ( #2782 )
...
With -Wconversion and 32 Bit I get a warning here with unsigned long
long converted to unsigned long.
2022-02-22 08:16:36 -08:00
Victor Zverovich
1ba69fb5a1
Remove snprintf FP fallback
2022-02-21 08:01:55 -08:00
Victor Zverovich
ea6f0bf0e5
Minor cleanup
2022-02-21 07:29:36 -08:00
Ivan Shynkarenka
1a18a2f3dd
Fixing "C4127: conditional expression is constant" Visual Studio 2022 warning in pedantic mode ( #2783 )
2022-02-21 07:26:16 -08:00
Victor Zverovich
4fcacea354
Parameterized fp on significand type
2022-02-21 07:25:13 -08:00
Victor Zverovich
cf940ae82e
Simplify to_decimal
2022-02-20 19:38:02 -08:00
Juraj
70dc3de053
Update format.h
...
To prevent the following compiler message:
[...]/include/fmt/format.h:392:20: warning: conversion to 'long unsigned int' from 'int' may change the sign of the result [-Wsign-conversion]
392 | unsigned value[size];
| ^~~~
2022-02-20 11:38:03 -08:00
Victor Zverovich
cbc59ca893
Clear moved from memory buffer
2022-02-20 08:12:59 -08:00
Vladislav Shchapov
ea3d326c63
Fix clang -Wliteral-range warning ( #2779 )
2022-02-19 10:52:33 -08:00
Victor Zverovich
aad44f2839
Add fmt::enums::format_as
2022-02-19 08:03:42 -08:00
Victor Zverovich
1319719a5e
Add underlying_t
2022-02-19 07:57:43 -08:00
Victor Zverovich
af5d8004fc
Limit Dragonbox to supported FP formats
2022-02-19 07:14:18 -08:00
Victor Zverovich
7b96420961
Remove unused include
2022-02-18 18:56:51 -08:00
Victor Zverovich
a0b43bfae2
Add support for 96-bit long double
2022-02-18 18:01:49 -08:00
Victor Zverovich
2c8cd2db34
Fix handling of zero precision
2022-02-18 12:38:30 -08:00
Victor Zverovich
b6d56170fc
Remove unnecessary inline
2022-02-18 07:41:55 -08:00
Victor Zverovich
05432e570e
Use consistent indentation
2022-02-18 07:38:42 -08:00
Victor Zverovich
47da218cc3
Remove uintptr_fallback
2022-02-18 07:03:33 -08:00
Victor Zverovich
4ddab8901c
Merge accumulator into int128_fallback
2022-02-18 06:17:28 -08:00
Victor Zverovich
d38f72aff2
Refactor fallback ints
2022-02-17 20:24:42 -08:00
Victor Zverovich
15c2a3bacc
int128_t -> int128_opt
2022-02-17 20:03:25 -08:00
Victor Zverovich
532a69a639
Fix handling of 96-bit long double with -m32
2022-02-17 15:51:59 -08:00
Andrey Filipenkov
d8e1dd4ab2
improve installing headers
2022-02-17 08:13:26 -08:00
Andrey Filipenkov
ae25f7968e
add ability to build Apple framework using CMAKE_FRAMEWORK
2022-02-17 08:13:26 -08:00
Victor Zverovich
ce93a66dfb
Implement a fallback uint128_t
2022-02-17 07:37:09 -08:00
Victor Zverovich
6a13464059
Include 128-bit with other signed integers in specifier check
2022-02-16 16:57:06 -08:00
Greg Sjaardema
70de324aa8
Apply 2746 fix for NVidia compiler also ( #2770 )
2022-02-16 12:04:16 -08:00
Victor Zverovich
a1ea3e015b
Move built-in formatter specialization to core
2022-02-16 07:37:00 -08:00
Victor Zverovich
161059dd98
Add support for extended precision FP
2022-02-16 06:07:04 -08:00
Victor Zverovich
c4c6b42de7
Bump version
2022-02-15 13:36:59 -08:00
Victor Zverovich
21785040c7
Fix markup
2022-02-15 13:28:53 -08:00
Victor Zverovich
2b6f7fc7a3
Add partial support for extended precision FP
2022-02-15 07:22:41 -08:00
Vladislav Shchapov
0a24a0714e
Clz builtin may be not constexpr (Issue #2761 ) ( #2762 )
2022-02-14 18:19:06 -08:00
Vertexwahn
ba6f89c76e
Update .bazelversion ( #2766 )
2022-02-14 06:08:46 -08:00
jk-jeon
5594edaf67
Address https://github.com/fmtlib/fmt/issues/2763 ( #2765 )
2022-02-13 20:14:28 -08:00
Vladislav Shchapov
10e3b83a75
Replace `make_args_checked with make_format_args` ( #2760 )
...
* Replace make_args_checked to make_format_args
* Deprecate legacy make_args_checked
2022-02-13 20:13:35 -08:00
Victor Zverovich
c48353cb75
Update docs
2022-02-13 07:41:15 -08:00
Junekey Jeon
083510f0f0
Add FMT_CONSTEXPR to rotr instead
2022-02-13 06:15:17 -08:00
Junekey Jeon
dba99bc860
Revert adding constexpr to rotr to satisfy C++11 compilers
2022-02-13 06:15:17 -08:00
Junekey Jeon
c04af4bfc7
Simplify remove_trailing_zeros
2022-02-13 06:15:17 -08:00
Junekey Jeon
b348caa9e9
Remove some C-style casts for consistency
2022-02-13 06:15:17 -08:00
Junekey Jeon
c8bd1e646e
Simplify remove_trailing_zeros
2022-02-13 06:15:17 -08:00
Junekey Jeon
9b23e9dcb8
Fix wrong comment/refer to a correct reference
2022-02-13 06:15:17 -08:00
Junekey Jeon
69f2c550ab
Remove std:: infront of uint32_t/64_t & add constexpr to rotr
2022-02-13 06:15:17 -08:00
Junekey Jeon
9b62310f03
Fix some conversion issues
2022-02-13 06:15:17 -08:00
Junekey Jeon
08d12f31d1
Fix typo
2022-02-13 06:15:17 -08:00
Junekey Jeon
dbddb1d066
Remove literal separator to satisfy some compilers
2022-02-13 06:15:17 -08:00
Junekey Jeon
7dbe3dcded
Recover log10_2_significand
2022-02-13 06:15:17 -08:00
Junekey Jeon
10642e6082
Optimize remove_trailing_zeros
2022-02-13 06:15:17 -08:00
Junekey Jeon
7b4323e1e0
Add rotr
2022-02-13 06:15:17 -08:00
Junekey Jeon
f1bd6f7731
Check r < deltai first, because that is the major branch chosen for short inputs
2022-02-13 06:15:17 -08:00
Junekey Jeon
5d8eb6a1a0
Reflect the new paper
...
- Change constants appearing in log & division computations
- Rename beta_minus_1 to beta
2022-02-13 06:15:17 -08:00
Victor Zverovich
8e2e4d4034
Suppress a gcc warning
2022-02-12 09:26:48 -08:00
Vladislav Shchapov
a44716f58e
Workaround to Intel compiler ( #2758 )
2022-02-11 06:25:42 -08:00
Vladislav Shchapov
c71b070168
Add missing const qualifier ( #2755 )
2022-02-10 10:51:32 -08:00
Victor Zverovich
ecd6022c24
Update docs
2022-02-08 06:28:22 -08:00
Victor Zverovich
afbcf1e8ea
Remove legacy C locale wrapper
2022-02-05 12:37:21 -08:00
Victor Zverovich
90325d0970
Fix stored type detection
2022-02-05 10:44:34 -08:00
Victor Zverovich
e2ba01fcb0
Fix overload ambiguity in print
2022-02-05 08:35:19 -08:00
Victor Zverovich
17b362f78c
Simplify ostream opt-in API
2022-02-04 18:33:59 -08:00
Victor Zverovich
a5a7e3a261
Update docs
2022-02-04 15:42:22 -08:00
Victor Zverovich
f055ebbd25
Make ostream operators opt in to reduce the risk of ODR violations
2022-02-04 15:06:45 -08:00
Victor Zverovich
8a21e328b8
Remove problematic constructibility check
2022-02-04 12:20:02 -08:00
Victor Zverovich
31e743d06e
Don't use ostream for types convertible to string_view
2022-02-04 11:00:00 -08:00
Victor Zverovich
35c0286cd8
Simplify byte handling
2022-02-02 16:13:24 -08:00
Victor Zverovich
c7173a36a1
Drop :: and fix formatting
2022-02-02 07:00:33 -08:00
Charlie Barto
3e8372b96e
qualify unqualified calls to format in compile.h ( #2742 )
2022-02-01 18:41:19 -08:00
Barry Revzin
a34a97cc1d
Supporting ? as a string presentation type ( #2674 )
...
* Supporting ? as a string presentation type.
* Supporting ? as a char presentation type.
* Adding iterator_category to counting_iterator.
2022-01-30 08:55:28 -08: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
1557ab7644
Add format_as for enums
2022-01-28 06:38:02 -08:00
Federico
b00a1eac75
Fixes NVIDIA HPC compiler and Intel ICC compatibility ( #2732 )
...
* Fixes NVIDIA HPC compiler and Intel ICC compatibility
* Fixes NVIDIA HPC compiler and Intel ICC compatibility
* Rename FMT_NVHPC_VERSION to FMT_NVCOMPILER_VERSION
Co-authored-by: Federico Busato <fbusato@nvidia.com>
2022-01-26 15:53:04 -08:00
Victor Zverovich
a7aecbfcaa
Remove an old mingw workaround
2022-01-23 09:44:53 -08:00
VasiliPupkin256
dfcc730cbd
Making target_compile_options PRIVATE, fix #2726 , fix #2507
2022-01-23 09:36:11 -08:00
Victor Zverovich
f7a809be6e
Clarify the choice of magic numbers and compute the most magic one
...
https://github.com/fmtlib/fmt/pull/2713#discussion_r788349826
2022-01-23 08:58:58 -08:00
Victor Zverovich
09fde7f4b8
Add fmt::underlying for enum classes
2022-01-22 08:06:22 -08:00
Victor Zverovich
0014024a2c
Don't rely on transitive includes
2022-01-21 15:03:28 -08:00
Victor Zverovich
c28500556a
FMT_NOEXCEPT -> noexcept
2022-01-20 16:55:47 -08:00
Junekey Jeon
6240d02011
Improve comments
2022-01-19 17:03:44 -08:00
Junekey Jeon
925b744ae8
Improve comments
2022-01-19 17:03:44 -08:00
Junekey Jeon
22b14ff252
Simplify cache recovery
2022-01-19 17:03:44 -08:00
Junekey Jeon
3dc26b44d3
Make a fallback path more compiler-friendly
2022-01-19 17:03:44 -08:00
Junekey Jeon
2e4038bf51
Simplify lines with __builtin_addcll and friends
2022-01-19 17:03:44 -08:00
Junekey Jeon
76336b4f63
Replace noexcept with FMT_NOEXCEPT
2022-01-19 17:03:44 -08:00
Junekey Jeon
9181983483
Fix syntax errors
2022-01-19 17:03:44 -08:00
Junekey Jeon
74097a149b
Remove now-unused stuffs
2022-01-19 17:03:44 -08:00
Junekey Jeon
21a1c53381
Fix typo
2022-01-19 17:03:44 -08:00
Junekey Jeon
04eea0f0a8
Remove now-unused stuffs
2022-01-19 17:03:44 -08:00
Junekey Jeon
35a468ed38
Simplify integer checks
2022-01-19 17:03:44 -08:00
Junekey Jeon
1882a7a2c1
Replace Dragonbox cache which allows simpler cache recovery & integer checks
2022-01-19 17:03:44 -08:00
Junekey Jeon
f4dd1b1b8b
Simplify Dragonbox Step 3.
2022-01-19 17:03:44 -08:00
Junekey Jeon
70561ed13e
Minimize the usage of built-in 128-bit ints
...
It usually generates slower code than manual handling.
2022-01-19 17:03:44 -08:00
Ivan Volnov
cdf1a3b530
Fix codecvt warning ( #2408 ) ( #2725 )
2022-01-19 10:26:09 -08:00
Tobias Hellmann
b8b037e930
Fix -Wconversion warning ( #2724 )
...
* - try fixing the warning "chrono.h:1217:37: warning: conversion from 'std::make_unsigned<long long int>::type' {aka 'long long unsigned int'} to 'size_t' {aka 'unsigned int'} may change value [-Wconversion]" by casting int to size_t (occurs when cross-compiling to Raspberry Pi ARMv7)
* - remove call to to_unsigned() because using static_cast<size_t> is enough
2022-01-19 06:31:33 -08:00
matrackif
5985f0a7d2
Fix overflow for chrono durations ( #2722 )
2022-01-17 12:14:59 -08:00
Victor Zverovich
8f8a1a02d5
Fix handling of formattable types implicitly convertible to pointers
2022-01-14 13:42:01 -08:00
Vladislav Shchapov
b02e5af52c
fmt::join support FMT_COMPILE ( #2720 )
2022-01-14 09:58:49 -08:00
Victor Zverovich
58fb782396
Improve docs
2022-01-13 14:57:17 -08:00
Victor Zverovich
4fe6129d6c
Fix FMT_NOEXCEPT definition
2022-01-13 10:20:32 -08:00
Pokechu22
c056a009de
Docs: Fix link to "Compile-time Format String Checks" section ( #2712 )
2022-01-12 16:07:56 -08:00
Victor Zverovich
7c12118c19
Deprecate buffered_file::fileno
2022-01-12 10:54:44 -08:00
Victor Zverovich
2a09d468da
Use noexcept unconditionally
2022-01-12 09:42:29 -08:00
Victor Zverovich
a126b4d888
Check if right shift is arithmetic
2022-01-11 08:23:30 -08:00
Victor Zverovich
9ff91b18cd
Simplify write_fractional_seconds
2022-01-09 15:08:46 -08:00
Victor Zverovich
d9f045fba1
Fix a UB in chrono
2022-01-09 14:06:13 -08:00
Barry Revzin
c06bef7273
Adding comments for range formatting. ( #2706 )
...
* Adding comments for range formatting.
* Adding missing quotes
2022-01-08 16:37:21 -08:00
Victor Zverovich
3c98f1a4cd
Comment style
2022-01-08 09:52:39 -08:00
Barry Revzin
6e0f1399d7
Supporting nested format specs for ranges. ( #2673 )
...
* Supporting nested format specs for ranges.
* I dedicate this commit to Eric Niebler.
* clang-format
* PR comments.
* throw -> FMT_THROW
* Need to map every element too.
* Clarifying uncvref_type
* Trying to add a workaround for MSVC.
2022-01-08 09:48:26 -08:00
Alex Guteniev
0102101acc
Make colored print handle UTF-8 ( #2701 )
...
* Fix #2681 - Make detail::print handle UTF-8
* Okay, let's do this Windows-only
* drop extra \0
* yay we can throw!
2022-01-06 16:10:53 -08:00
Victor Zverovich
4ac5269b4f
Update ChangeLog.rst
2022-01-06 15:03:01 -08:00
Victor Zverovich
b6f4ceaed0
Update version
2022-01-06 14:35:15 -08:00
Victor Zverovich
15f812dae8
Update changelog
2022-01-06 14:13:01 -08:00
Victor Zverovich
6884aab49b
Update changelog
2022-01-06 12:38:33 -08:00
Victor Zverovich
88ec4e7061
Bump version
2022-01-06 12:32:43 -08:00
Victor Zverovich
dd3d2490ed
Update changelog
2022-01-06 12:07:13 -08:00
Victor Zverovich
739055ae7b
Fix apidocs
2022-01-06 11:06:39 -08:00
Victor Zverovich
dbbd711f46
Suppress a warning
2022-01-05 09:41:35 -08:00
Victor Zverovich
98cbb6a43c
Fix ABI compatiblity issue
2022-01-05 08:08:38 -08:00
Vladislav Shchapov
214cf13f17
Fix endianness bug in write_digit2_separated ( #2699 )
...
* Fix endianness bug in write_digit2_separated
* Move endianness check to compile time if it possible
* Turn 8 into a constant
2022-01-04 14:23:42 -08:00
Julian Rüth
17a5c808da
Restore FMT_API on error_handler::on_error() ( #2696 )
...
this fixes a breaking ABI change that was introduce in the upgrade from
8.0.1 to 8.1.0.
Fixes #2695 .
2022-01-04 10:53:44 -08:00
Richard Berger
fc1783fcc6
Avoid undefined symbols with mingw-w64 ( #2692 )
...
Fixes issue #2691
2022-01-03 15:29:29 -08:00
Victor Zverovich
1b193e7b37
Deprecate more
2022-01-03 11:13:09 -08:00
Victor Zverovich
8e59744b8d
Switch to new github auth mechanism
2022-01-02 09:29:42 -08:00
Victor Zverovich
7081a6aa34
Update version
2022-01-02 09:01:32 -08:00
Victor Zverovich
64dc8fbada
Bump version
2022-01-02 08:34:01 -08:00
Victor Zverovich
fc8e3de7db
Fix manage.py script
2022-01-02 08:22:25 -08:00
Victor Zverovich
57bee9fcdd
Fix formating
2022-01-02 08:09:55 -08:00
Victor Zverovich
dce52e491e
Update changelog
2022-01-02 08:02:45 -08:00
Victor Zverovich
9405a47245
Update changelog
2022-01-02 07:57:36 -08:00
Victor Zverovich
495b8bf12e
Update changelog
2022-01-01 13:56:31 -08:00
Victor Zverovich
e221166fab
Update changelog
2022-01-01 11:34:04 -08:00
Victor Zverovich
035cab8da3
Update changelog
2022-01-01 09:36:40 -08:00
Victor Zverovich
89c6ed12bf
Clarify in comments (for now) deprecated map functions
2022-01-01 09:29:50 -08:00
Björn Schäpers
e462da828d
Add some noexcept ( #2684 )
...
I got warnings from -Wnoexcept, fixed them.
2022-01-01 08:44:00 -08:00
Victor Zverovich
79c66d66bd
Update changelog
2021-12-29 15:33:30 -08:00
Victor Zverovich
5d37f705f4
Update changelog
2021-12-29 15:31:03 -08:00
Victor Zverovich
6bb370cec1
Update changelog
2021-12-29 15:26:11 -08:00
Victor Zverovich
bb69201578
Fix tuple join
2021-12-29 14:46:45 -08:00
Victor Zverovich
4fac7daaef
Cleanup bit_cast
2021-12-29 12:14:51 -08:00
Victor Zverovich
3617c2795a
Update changelog
2021-12-29 08:25:12 -08:00
Victor Zverovich
9c0c1bcdbd
Simplify tuple formatting
2021-12-29 08:03:12 -08:00
Victor Zverovich
187e8db1be
Update changelog
2021-12-28 08:11:03 -08:00
Alexey Ochapov
c7f88180f6
add tests for format string compile-time checks
2021-12-27 20:55:06 -08:00
Alexey Ochapov
8a2c3fb88f
add reverse tests to compile-error-test
...
to make sure that error tests do not fail because they become outdated
2021-12-27 20:55:06 -08:00
Alexey Ochapov
1164eda5af
disable compile-error-test on Windows
...
since it takes too much time to complete, similar to other tests with additional
CMake invocation
2021-12-27 20:55:06 -08:00
Alexey Ochapov
4482f6f1f0
rewrite compile-error-test to use non-header-only library
2021-12-27 20:55:06 -08:00
Victor Zverovich
796662a612
Escape range items convertible to std::string_view
2021-12-27 09:38:06 -08:00
Vladislav Shchapov
33ee4cc516
Improve noexception test
2021-12-26 16:28:41 -08:00
Vladislav Shchapov
3bbf2c673c
Fix throw with exceptions disabled
2021-12-26 16:28:41 -08:00
Victor Zverovich
074c9c52ef
Update changelog
2021-12-26 08:36:29 -08:00
Victor Zverovich
3110ec5a23
Update changelog
2021-12-26 08:19:32 -08:00
Victor Zverovich
3014b3d770
Clarify that C strings must be null-terminated
2021-12-26 07:23:43 -08:00
Victor Zverovich
eab2ea9fc2
Replace an assert with an exception
2021-12-26 07:05:45 -08:00
Victor Zverovich
21ed92a6e9
Update changelog
2021-12-24 07:25:23 -08:00
Vladislav Shchapov
04111dd1e4
Fix issue #2670 ( #2671 )
2021-12-23 12:38:48 -08:00
Alexey Ochapov
817788fbf0
remove incorrect C++20 check from test/CMakeLists.txt ( #2663 )
...
It disables entire branch of tests declaration unconditionally because CXX_STANDARD
is not defined there. But even we use CMAKE_CXX_STANDARD here, these tests should
not be disabled with standard >= C++20.
2021-12-23 12:32:03 -08:00
Victor Zverovich
4511030af2
Minor code style tweaks for consistency
2021-12-23 11:55:58 -08:00
lucpelletier
7812813a32
Don't explicitly delete copy ctor of dynamic_format_arg_store ( #2664 )
...
* Don't explicitly delete copy ctor of dynamic_format_arg_store
Explicitly deleting the copy ctor causes the move constructor to not be
implicitly generated. This behaviour is different than what was in
v8.0.1 and causes code that relied on the move ctor of
dynamic_format_arg_store to break.
* Add test for dynamic_format_arg_store's move ctor
* include <memory>, don't use make_unique
2021-12-23 11:34:16 -08:00
Victor Zverovich
664cd6067d
Remove std-format-test
2021-12-23 10:58:02 -08:00
Victor Zverovich
784e2a7b42
Fix an overflow when formatting very large durations
2021-12-23 10:34:32 -08:00
Stefan Weil
fc2a376d8e
Remove two expressions which had no effect (reported by LGTM)
...
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2021-12-22 16:29:16 -08:00
Alexey Ochapov
c5aafd8f90
expose headers as SYSTEM depending on special configuration option
2021-12-19 08:29:51 -08:00
Victor Zverovich
eaddd1e3cd
Fix handling of byte
2021-12-19 06:46:24 -08:00
Victor Zverovich
2d44577586
Try fixing byte regression
2021-12-18 08:51:21 -08:00
Alexey Ochapov
e46392ea2c
deprecate _format UDL in code using FMT_DEPRECATED
2021-12-18 08:33:20 -08:00
Victor Zverovich
c882790a2e
Add a set formatter
2021-12-18 07:35:40 -08:00
Victor Zverovich
121002d700
Add a map formatter
2021-12-18 07:12:53 -08:00
Victor Zverovich
be51ee1ceb
Disable broken copy ctor of dynamic_format_arg_store
2021-12-17 17:18:18 -08:00
Victor Zverovich
659de779e6
Fix a UB in parse_format_specs when begin is null
2021-12-17 16:51:24 -08:00
Alexey Ochapov
51b14b6c0c
remove commented out lines
2021-12-17 16:05:56 -08:00
Alexey Ochapov
223a0fa55d
move gtest-specific check into gtest/CMakeLists.txt
2021-12-17 16:05:56 -08:00
Alexey Ochapov
ef72b471fc
enable named arguments check in compile-time checks ( #2649 )
...
works only if all named arguments are UDL-based
2021-12-17 15:53:05 -08:00
Alexey Ochapov
82246b8766
fix throw with exceptions disabled ( #2647 )
2021-12-17 13:44:36 -08:00
Victor Zverovich
35f60377aa
Update ChangeLog.rst
2021-12-17 06:49:29 -08:00
Marek Kurdej
3a951a66cb
Avoid qualifying by inline namespace. Fixes #2642 . ( #2643 )
2021-12-10 08:28:25 -08:00
Marek Kurdej
e0136fc8bd
Qualify calls to make_wformat_args. Fixes #2639 . ( #2641 )
2021-12-10 06:36:42 -08:00
Victor Zverovich
ac1b5f3da5
Refactor problematic trailing returns in arg_mapper
2021-12-09 18:08:30 -08:00
Victor Zverovich
fd62fba985
Don't convert scoped enums to integers
2021-12-09 12:09:33 -08:00
Victor Zverovich
c652f8243a
Make header guard consistent with header name
2021-12-09 10:49:47 -08:00
Victor Zverovich
a9c7b9b8f7
Clarify that _format is deprecated
2021-12-09 10:34:27 -08:00
Victor Zverovich
e4f0564aa6
Disable is_streamable for string[_view]
2021-12-09 10:02:18 -08:00
Victor Zverovich
91533d3c33
Minor tweaks to chrono subsecond formatting
2021-12-09 06:55:31 -08:00
matrackif
0bbc9708f9
Implement c++20 std::chrono::duration subsecond formatting ( #2623 )
...
* Add support for subsecond printing for std::chrono::duration according to the c++20 standard
* Remove assert test that overflows intmax_t
* * Hopefully fix int64_t to int32_t conversion errors.
* Allow proper Duration::rep type to propagate via template argument deduction
* * Hopefully fix int64_t to int32_t conversion errors.
* Allow proper Duration::rep type to propagate via template argument deduction
* Fix sign conversion (-Wsign-conversion) warning treated as error in num_digits()
* Format chrono.h with clang-format
* Remove extra forward slash in doxygen style comment
Co-authored-by: Victor Zverovich <victor.zverovich@gmail.com>
* Apply all suggestions from GitHub, except for replacing the utility subsecond_helper class with a function
* * Move logic of handling subseconds from utility class to function with name write_fractional_seconds()
* Revert write(Rep value, int width) function to previous state
* Fix -Wshadow warning
* Remove unsued get_subseconds() function, its logic has been moved to write_fractional_seconds()
* Change comment from lowercase int to uppercase Int
* Simplify test check
* Integrate suggested changes
* Remove static from detail functions, they are no longer member functions of a class and static is unnecessary.
* Change comment from "amount" to "number"
Co-authored-by: Victor Zverovich <victor.zverovich@gmail.com>
2021-12-09 06:45:13 -08:00
Vladislav Shchapov
9d5b9defde
Enable tzset only on Windows desktop app ( #2633 )
2021-12-07 15:22:36 -08:00
Victor Zverovich
215f21a038
Detect overflow on large precision
2021-12-05 07:26:58 -08:00
Vladislav Shchapov
c240d98ffd
Optimize tm formatting (Non C-locales and %Z) ( #2617 )
...
* Move fmt::detail::formatbuf to format.h
* Replace std::basic_ostringstream to std::basic_ostream with custom formatbuf
* Use tm.tm_zone
2021-12-04 11:02:31 -08:00
Andrew Corrigan
6ab73113fc
Mark grow as FMT_CONSTEXPR20 ( #2630 )
...
resolves https://github.com/fmtlib/fmt/issues/2627
2021-12-03 07:13:30 -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
Lounarok
ec3b097cb9
[doc] FMT_STRING supports C++14 and no-op in C++11 ( #2620 )
...
* FMT_STRING supports C++14 and no-op in C++11
* Move requirement to the end. Modify description.
2021-11-28 07:02:15 -08:00
Victor Zverovich
c472a27818
Fix handling of very large precision in fixed format
2021-11-27 08:23:05 -08:00
Alex Guteniev
201971e293
Make MSVC use [[nodiscard]] ( #2615 )
...
* Make MSVC use [[nodiscard]]
* Uniformly detect attributes for __cplusplus and _MSVC_LANG
2021-11-26 07:32:50 -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
Florin Iucha
491ba2dda5
Annotate fmt::format and fmt::formatted_size as [[nodiscard]]
...
This prevents accidentally writing fmt::format when fmt::print was
intended. Other than running tests, there's not a good use case for
discarding the formatted output.
2021-11-25 07:30:30 -08:00
Vladislav Shchapov
5abe9e8266
Add platform-specific 'z' formatter
2021-11-25 06:52:39 -08:00
Vladislav Shchapov
be3a3a5aed
Use predefined formats for C-locale
2021-11-25 06:52:39 -08:00
Alex Guteniev
a3ab36c803
Formatting of function pointers, member function pointers, member object pointers... ( #2610 )
2021-11-23 12:55:22 -08:00
Eric Curtin
19cac63fe4
Broken link in README.rst
...
Added src directory to link
2021-11-19 09:24:38 -08:00
Victor Zverovich
43419a4ada
Workaround a bug in gcc
2021-11-19 07:32:42 -08:00
Vladislav Shchapov
c089f7d497
Simplify std::tm formatter
2021-11-14 07:16:22 -08:00
Vladislav Shchapov
aa5517f6b9
Reuse tm_writer in chrono_formatter
2021-11-14 07:16:22 -08:00
Vladislav Shchapov
50140be7ae
Reuse tm_writer in weekday formatter
2021-11-14 07:16:22 -08:00
Victor Zverovich
8b89454994
Improve consistency
2021-11-13 08:59:56 -08:00
Victor Zverovich
5380ff4d88
Detect types convertible to unformattable pointers
2021-11-13 08:26:27 -08:00
Pavel Novikov
094b66e81d
changed locale retrieval way to a fancy one
2021-11-12 12:46:38 -08:00
Vladislav Shchapov
b69ae4854c
Reorder classes ( #2591 )
2021-11-10 17:09:23 -08:00
Pavel Novikov
0b843af56b
sped up chrono.h formatting for cases without providing locale ( #2576 )
2021-11-07 08:52:57 -08:00
lukester1975
12b1d8b14a
Fix precision 0 with std::chrono::duration and added additional tests. ( #2588 )
2021-11-06 08:57:22 -07:00
Olli Lupton
e67f92c55c
Cleanup warnings with nvhpc/21.9. ( #2582 )
...
* Cleanup warnings with nvhpc/21.9.
* Move __NVCOMPILER check.
* Be more explicit.
* Immediately executed lambda.
* Fix shadowing warning.
2021-11-05 12:17:11 -07:00
Victor Zverovich
812733cc96
const qualify format function for systen_clock
2021-10-31 09:41:16 -07:00
Victor Zverovich
028f227752
Handle implicit conversions in write
2021-10-31 08:58:54 -07:00
Victor Zverovich
5b0aa638cf
Minor grammar fix
2021-10-30 09:14:13 -07:00
Vladislav Shchapov
6eaceb5f73
Fix incompatible between docutils 1.18.0 and sphinx 3.3.0 ( #2575 )
2021-10-30 09:12:36 -07:00
timkalu
0697c5edb6
FMT_USE_FCNTL can be predefined ( #2573 )
...
'os.h' accepts a predefined FMT_USE_FCNTL override so using FMT with e.g. the NXP toolchain for ARM (e.g. for FreeRTOS) does not have a fcntl() call, but the detection routine does not detect this correctly.
2021-10-30 08:35:48 -07:00
Vladislav Shchapov
1031eedf27
Replacing strftime with std::time_put ( #2550 )
...
* Fix unicode test
* Add xchar support to chrono formatter
* Replace strftime with std::time_put
* Add std::locale support to std::tm formatter
* Use predefined names and formats for C-locale
* Performance improvement
* Make locale-independent and C locale formats consistent among platforms
2021-10-30 08:25:45 -07:00
Vladislav Shchapov
90034e4c4b
Add FMT_ASSERT and validation of values of struct tm members ( #2564 )
...
Switch internal year calculations to long long
2021-10-27 13:29:07 -07:00
Daniela Engert
df40e94673
Upgrade module-test to msvc 16.11.5 and 17.0-pre5 ( #2558 )
2021-10-24 08:12:39 -07:00
zhsj
e6d5059cbb
Simplify js tag in basic-bootstrap theme ( #2562 )
...
When build the docs for debian package, it uses a sphinx building
helper, which does a sanity check for the output.
The sanity check complains missing data-url_root attribute in the
js tag. So this patch changes the js tag to use the same function like
the origin basic theme, which adds additional information like
data-url_root.
Ref: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=997437
2021-10-24 06:36:10 -07:00
Daniela Engert
3b6e409cd8
Enable consteval for msvc 17.0-pre5 ( #2559 )
2021-10-23 07:19:57 -07:00
Axel Kohlmeyer
249f03bbb7
do not detect LLVM based IBMXL compiler (on ppc) as clang ( #2555 )
2021-10-20 06:21:49 -07:00
Vladislav Shchapov
7463c83205
Fix overflow for very bigger years (>2*10^9) ( #2551 )
2021-10-19 07:04:55 -07:00
Victor Zverovich
1266c2b600
Fix handling of exotic character types
2021-10-17 09:07:48 -07:00
Victor Zverovich
684e2fdc94
Minor cleanup
2021-10-17 06:33:27 -07:00
Victor Zverovich
a1d586302f
Minor cleanup
2021-10-17 06:07:03 -07:00
Vladislav Shchapov
7a604cdd98
Cleanup
2021-10-16 15:03:57 -07:00
Vladislav Shchapov
aeb54b0dd9
Fix bug on '%Y' and '%C' formats with negative years
...
Requested changes
2021-10-16 15:03:57 -07:00
Vladislav Shchapov
f88c020fc0
Generalization of strftime/wcsftime function calls in tests
2021-10-16 15:03:57 -07:00
Vladislav Shchapov
2eeddba756
Renaming, splitting of functions
2021-10-16 15:03:57 -07:00
Vladislav Shchapov
2754546080
Fix errors in ISO week-base-year formatter
2021-10-16 15:03:57 -07:00
Vladislav Shchapov
218cecb6d1
Fix error in test
2021-10-16 15:03:57 -07:00
Vladislav Shchapov
e9f4453b0e
Fix Microsoft Visual Studio 14.0 build
2021-10-16 15:03:57 -07:00
Vladislav Shchapov
27c3674ce1
Improve performance
2021-10-16 15:03:57 -07:00
Vladislav Shchapov
5dc3dd3d4a
New tests
2021-10-16 15:03:57 -07:00
Vladislav Shchapov
f8542cd988
Unified formatters for std::chrono::time_point<std::chrono::system_clock, Duration> and std::tm
2021-10-16 15:03:57 -07:00
Vladislav Shchapov
4707373d33
Fix year formatter
2021-10-16 15:03:57 -07:00
Vladislav Shchapov
79c00ad8f2
Improve ISO week-base-year formatter
2021-10-16 15:03:57 -07:00
Vladislav Shchapov
fbaaa5906b
Improve week of the year formatter
2021-10-16 15:03:57 -07:00
Vladislav Shchapov
cde44ddb72
Improve year formatter
2021-10-16 15:03:57 -07:00
Vladislav Shchapov
b04601b918
Switch from std::strftime/std::wcsftime to internal implementation for locale independent formats
2021-10-16 15:03:57 -07:00
Vladislav Shchapov
d3d30a46f0
New tests
2021-10-16 15:03:57 -07:00
Vladislav Shchapov
7911d8d3f5
Add format spec checker
2021-10-16 15:03:57 -07:00
Vladislav Shchapov
fbbfc3b03c
Reorder formatters
2021-10-16 15:03:57 -07:00
Vladislav Shchapov
509eac9575
Workarounds for implementation-defined std::strftime behavior
2021-10-16 15:03:57 -07:00
Vladislav Shchapov
85b38190d1
New tests for all C++11 std::strftime format specifiers
2021-10-16 15:03:57 -07:00
Barry Revzin
7aca36bca4
Extending fmt::join to support C++20-only ranges. ( #2549 )
2021-10-16 10:02:03 -07:00
Victor Zverovich
f5371a75f4
locale.h -> format.h
2021-10-14 15:57:10 -07:00
Josh Essman
febdef43f5
fix: add workaround for intel parameter pack bug
2021-10-14 10:44:24 -07:00
Josh Essman
f56756986b
fix: check to make sure both 'if constexpr' and return type deduction are available
...
fix: remaining ifdefs
2021-10-14 10:44:24 -07:00
Victor Zverovich
dcd282bb26
Namespace qualify calls to get
2021-10-09 07:15:14 -07:00
Oliver Lee
9c14474d30
Include <bit> when using std::bit_cast
2021-10-09 06:11:36 -07:00
Victor Zverovich
1e96e01766
Fix compiler flag check ( #2540 )
2021-10-09 06:05:05 -07:00
Roman-Koshelev
7e4bc94510
Speeding up write_significand() ( #2499 )
2021-10-09 05:27:38 -07:00
Pavel Novikov
26c1ca4c3e
Replaced default spec with equivalent one, which is potentially more optimizable ( #2537 )
2021-10-08 07:09:54 -07:00
Victor Zverovich
1e865b3539
Fix docs
2021-10-03 07:05:31 -07:00
Victor Zverovich
4a85db1ce1
Change default open mode to -rw-r--r-- ( #2530 )
2021-10-03 06:36:40 -07:00
Vladislav Shchapov
0a985fd4c6
Move size_ initialization to initializer list ( #2529 )
2021-10-02 17:20:33 -07:00
Victor Zverovich
012cc709d0
Workaround gcc _Pragma bug 59884
2021-10-02 15:41:47 -07:00
Victor Zverovich
d6590e3bd2
Fix compiler check
2021-10-02 08:46:18 -07:00
Victor Zverovich
134aec40f0
Fix search in docs
2021-10-02 07:58:08 -07:00
Victor Zverovich
48a476ae0f
Update example ( #2522 )
2021-10-02 07:33:33 -07:00
Victor Zverovich
023c2018f7
Don't use strlen in constexpr
2021-10-02 07:17:05 -07:00
Victor Zverovich
800d4c8ac8
Refactor Windows workarounds
2021-10-02 06:06:08 -07:00
Mathias Born
32865aeaab
changed detection of Intel Compiler Classic to distinguish MS-Windows ( #2510 )
...
* changed detection of Intel Compiler Classic to distinguish MS-Windows
* replaced !FMT_ICC_ON_WINDOWS by FMT_ICC_POSIX
removed #pragma manged
* replaced FMT_ICC_POSIX with FMT_ICC_INTRINSIC_BUG to be crystal clear about the macro's purpose
2021-10-02 05:43:41 -07:00
Vertexwahn
7b339795a1
Describe a better approach of how to use {fmt} as a depency in a Bazel project ( #2516 )
2021-10-02 05:36:43 -07:00
Jonathan W
ae9bbe1169
Suppress warning C4127 in chrono.h (conditional expression is constant) ( #2518 )
2021-09-30 09:14:38 -07:00
Max FERGER
927dbd134d
Misplaced comma in README.rst ( #2515 )
2021-09-28 09:53:37 -07:00
Victor Zverovich
2a9a77dd8c
Remove misplaced comment
2021-09-26 18:01:39 -07:00
Victor Zverovich
1aee4bc90a
Refactor FP formatting
2021-09-26 14:37:33 -07:00
Victor Zverovich
e1bd6cc913
Refactor FP formatting
2021-09-26 10:25:46 -07:00
Victor Zverovich
027fcaf05e
Replace use_grisu with fallback since Grisu is only one of multiple implemented algorithms
2021-09-26 08:44:05 -07:00
Victor Zverovich
716d69f27e
Refactor FP formatting
2021-09-26 08:27:18 -07:00
Victor Zverovich
ff7e73af66
Always run grisu_gen_digits before fallback_format
2021-09-26 07:54:25 -07:00
Victor Zverovich
2976e31ac9
Refactor format_float
2021-09-25 11:20:56 -07:00
Victor Zverovich
807ee5ec31
Disable consteval in Apple clang
2021-09-25 05:55:05 -07:00
Vertexwahn
d9a731d486
Add basic support for Bazel ( #2505 )
2021-09-24 13:17:26 -07:00
jk-jeon
9c57357e05
Add static to a table ( #2509 )
2021-09-24 06:25:08 -07:00
Victor Zverovich
2742611cad
Fix formatting
2021-09-18 11:09:24 -07:00
Victor Zverovich
5092b198bc
Document group_digits
2021-09-18 10:50:30 -07:00
Alexey Ochapov
b4d9d82e1d
make FP formatting available to be used at compile-time ( #2426 )
...
* works only with FMT_HEADER_ONLY
* works only with float and double types (not long double)
2021-09-18 08:03:23 -07:00
Vladislav Shchapov
d9fd695ac7
Fix wchar_t tm formatting
2021-09-15 07:33:24 -07:00
Vladislav Shchapov
92614ecbf9
Optimize %T in tm formatting
2021-09-15 07:33:24 -07:00
Victor Zverovich
aaeca12d89
Move FMT_MAYBE_UNUSED to format.h where it is used
2021-09-13 07:51:36 -07:00
Victor Zverovich
3d0c7ae385
Move data to format.cc
2021-09-13 06:23:57 -07:00
Victor Zverovich
04e3a79f76
Use memcpy in more cases in copy2
2021-09-12 12:23:45 -07:00
Roman-Koshelev
e47e99bb09
Simplify format_decimal ( #2498 )
...
* Add copy2() constexpr
* Removed redundant format_decimal implementation for constexpr context
2021-09-12 10:36:06 -07:00
Victor Zverovich
9b6b0e403c
Remove data
2021-09-12 09:46:00 -07:00
Victor Zverovich
4d1c6034eb
Deprecate basic_data
2021-09-12 09:37:23 -07:00
Victor Zverovich
a3348eccdd
Deprecate most of basic_data
2021-09-12 08:59:39 -07:00
Victor Zverovich
3a04481485
Remove data::hex_digits
2021-09-11 17:54:40 -07:00
Victor Zverovich
ad77331c04
Move log10_2_significand to format-inl.h
2021-09-11 09:36:23 -07:00
Victor Zverovich
d9ebc4e821
Add a function to get sign char
2021-09-11 09:17:59 -07:00
Victor Zverovich
c00eb4f4c6
Add missing inline
2021-09-10 09:01:18 -07:00
Victor Zverovich
25af02f21a
positive -> nonnegative ( #2493 )
2021-09-10 08:52:54 -07:00
Victor Zverovich
67cb2dad37
Optimize %F in tm formatting
2021-09-10 07:48:50 -07:00
Roman-Koshelev
1aa98f8b93
Eliminate double copying in vformat_to_n ( #2489 )
2021-09-09 08:10:29 -07:00
Victor Zverovich
a58c133821
Improve code_point_length codegen on older gcc
2021-09-07 19:34:13 -07:00
Victor Zverovich
aeee70a815
Remove unnecessary cast
2021-09-07 10:53:43 -07:00
Jean-Michaël Celerier
c771ba361c
Fix build for the clang-10 / libstdc++-9 couple ( #2491 )
2021-09-07 08:52:34 -07:00
Victor Zverovich
ab6e2272cc
Clarify shifts encoding
2021-09-06 18:45:34 -07:00
Victor Zverovich
e4728409e7
Use throw_format_error in more places to reduce bloat
2021-09-06 16:42:17 -07:00
Victor Zverovich
e3ebf366a6
Inline padding shifts
2021-09-06 16:26:50 -07:00
Victor Zverovich
894faf3fed
Refactor presentation types
2021-09-06 13:32:33 -07:00
Victor Zverovich
4eb97fa4e3
Reduce code bloat
2021-09-05 16:24:20 -07:00
Victor Zverovich
6b55c83252
is_const_formattable -> has_const_formatter
2021-09-05 08:35:08 -07:00
Victor Zverovich
2fe94ad7e3
Make specifiers support in tuple_join an opt-in
2021-09-05 07:34:06 -07:00
Victor Zverovich
3940de5952
thousands -> group_digits
2021-09-05 06:47:18 -07:00
Victor Zverovich
c4d0f96a6d
Implement format specs in fmt::thousands
2021-09-04 06:56:51 -07:00
Victor Zverovich
3b9c442689
Implement thousands separators without locales
2021-09-04 06:32:46 -07:00
Victor Zverovich
08f98c7fac
Simplify get_arg_index_by_name
2021-09-03 21:17:36 -07:00
Victor Zverovich
a151f955a0
Remove FMT_OVERRIDE
2021-09-03 18:15:17 -07:00
Victor Zverovich
42a225cbd9
Remove redundand final
2021-09-03 17:33:26 -07:00
Victor Zverovich
bf20d19901
Simplify the core API
2021-09-03 16:57:33 -07:00
Victor Zverovich
fc0884037e
Move FMT_GCC_VISIBILITY_HIDDEN to format.h
2021-09-03 16:34:42 -07:00
Victor Zverovich
1aeed2dbca
Require inline namespaces
2021-09-03 15:59:23 -07:00
Victor Zverovich
799bea4730
Remove FMT_HAS_GXX_CXX11
2021-09-03 15:49:40 -07:00
Victor Zverovich
60cd5ea3f2
Add support for more formattable types in ranges
2021-09-03 14:55:41 -07:00
Victor Zverovich
4fd9a00f35
Simplify ostream interface
2021-09-03 13:07:54 -07:00
Victor Zverovich
5681563898
Cleanup ostream interface
2021-09-03 10:35:19 -07:00
Victor Zverovich
20931baf1d
Disable fallback_formatter for arrays
2021-09-03 08:59:36 -07:00
Pierre-Antoine Lacaze
d58d19ba32
Fix an odr violation in ranges.h ( #2483 )
...
* Add a testcase demonstrating ODR violation in ranges.h
* Fix ODR violation in ranges.h
* Fix comments
Co-authored-by: Pierre-Antoine Lacaze <pa.lacaze@gmail.com>
2021-09-02 08:47:44 -07:00
Victor Zverovich
ee0659f8b6
Fix formatting of abstract classes via ostream
2021-09-02 08:19:12 -07:00
Roman-Koshelev
8029bf955c
Fix copy_str performance ( #2477 )
2021-09-02 07:25:26 -07:00
Max
2520f410c8
Workaround for #2478 ( #2482 )
...
_MSC_VER 1911 (Visual Studio 2017 15.3)
2021-09-02 07:13:30 -07:00
Vladislav Shchapov
ee63f5f04e
Workaround to MSVC bug ( #2474 ) ( #2476 )
2021-08-31 07:54:42 -07:00
Victor Zverovich
1aaf72fb6d
Add an example to fmt::runtime
2021-08-29 12:10:40 -07:00
Victor Zverovich
c1313c2057
Clarify that format_to[_n] do not append a terminating null
2021-08-29 12:07:35 -07:00
Victor Zverovich
cb0f177c35
Improve docs
2021-08-29 11:30:35 -07:00
Victor Zverovich
71677e5204
Improve docs
2021-08-29 11:21:38 -07:00
Paul Dreik
4db5723525
add fuzzers for chrono timepoint and localtime,gmtime ( #2469 )
...
* add fuzzers for chrono timepoint and localtime,gmtime
* reorder cases to improve throughput
mutating the first byte of the input now always results in picking
on of the two paths. Before, two of the four possible outcomes resulted
in doit() not being invoked.
* drop the localtime fuzzer
* inline aliases
* only fuzz std::chrono::system_clock
2021-08-29 06:58:23 -07:00
Victor Zverovich
dc7f3ef2bb
Fix header name
2021-08-28 20:34:45 -07:00
Victor Zverovich
419ba86a91
Improve docs
2021-08-28 16:54:58 -07:00
Victor Zverovich
6a5b4d5faf
Document format_string
2021-08-28 16:51:48 -07:00
Victor Zverovich
2599163b8a
Document format_string
2021-08-28 15:20:56 -07:00
Victor Zverovich
8ef22f7740
Update docs
2021-08-28 12:05:30 -07:00
Victor Zverovich
c0c4d1adab
Update docs
2021-08-28 11:52:13 -07:00
Victor Zverovich
729a44e67d
Depreate strtod and remove problematic tests
2021-08-28 09:20:36 -07:00
Victor Zverovich
74c1118964
Apply force inline
2021-08-26 21:17:35 -07:00
Victor Zverovich
596508a928
Cleanup
2021-08-26 20:56:28 -07:00
Victor Zverovich
043e3b3429
Remove static_assert from arg_mapper
2021-08-26 20:45:01 -07:00
Victor Zverovich
8b0cb944da
Fix error reporting when mixing character types
2021-08-26 18:16:05 -07:00
Alexey Ochapov
117fc67077
CI: replace g++ C++20 build to test FP formatting at compile-time
2021-08-26 17:16:45 -07:00
Alexey Ochapov
c79a3841e8
make detail::fp and detail::bigit constexpr
2021-08-26 17:16:45 -07:00
Alexey Ochapov
5888de9f34
make detail::make_checked() constexpr
2021-08-26 17:16:45 -07:00
Alexey Ochapov
04b4b69b11
make detail::bit_cast() constexpr with C++20
2021-08-26 17:16:45 -07:00
Alexey Ochapov
fd34a3d246
make detail::basic_memory_buffer constexpr with C++20
2021-08-26 17:16:45 -07:00
Victor Zverovich
6d597e39c3
Fix overload ambiguity in arg_mapper
2021-08-26 16:54:27 -07:00
Victor Zverovich
b9ce56d936
Improve comments
2021-08-26 16:30:58 -07:00
Victor Zverovich
f889e52a15
Improve error reporting
2021-08-26 15:47:44 -07:00
Victor Zverovich
34caecd6b6
Use consistent initialization style
2021-08-23 10:10:56 -07:00
sunmy2019
a44c8f651b
reimplement formatter<tuple_join_view> ( #2457 )
...
* reimplement `formatter<tuple_join_view>`
1. completely reimplement `formatter<tuple_join_view<Char, T...>, Char>`
2. Add some tests
* use FMT_THROW
2021-08-23 09:51:19 -07:00
owent
4b8bda25c0
Fix 2462
...
Signed-off-by: owent <admin@owent.net>
2021-08-23 06:31:10 -07:00
Paul Dreik
6b5e6119ee
set clang in one place
2021-08-22 17:52:45 -07:00
Paul Dreik
7af1dc1d27
fix UB in fuzzer common (memcpy on nullptr)
2021-08-22 17:52:45 -07:00
Paul Dreik
e77686f7a8
clang format
...
using clang format 11
2021-08-22 17:52:45 -07:00
Victor Zverovich
2207ea0b36
More escaping
2021-08-22 16:54:26 -07:00
Victor Zverovich
a212ff757f
Escape invalid code points
2021-08-22 15:51:33 -07:00
Victor Zverovich
a76031e11d
check -> is_printable
2021-08-22 13:23:38 -07:00
Victor Zverovich
a7f280765c
Improve naming
2021-08-22 12:44:00 -07:00
Victor Zverovich
07d033ecb4
Fix is_printable
2021-08-22 10:37:18 -07:00
Victor Zverovich
cdb4299acb
Add Unicode support to is_printable
2021-08-22 09:11:35 -07:00
Victor Zverovich
7df2c82a8a
Rewrite printable.py codegen to emit C++
2021-08-22 09:10:10 -07:00
Victor Zverovich
6cf90d7cee
Add script license and fix python version
2021-08-22 08:17:58 -07:00
Victor Zverovich
2f1ad8ed3c
Add printable codegen from Rust
2021-08-22 08:15:34 -07:00
Victor Zverovich
371d8e2ee0
Escape Unicode
2021-08-22 07:55:59 -07:00
Victor Zverovich
6397095ca4
More escaping
2021-08-21 16:36:25 -07:00
Victor Zverovich
f69a572538
Don't overescape wide strings
2021-08-19 17:25:16 -07:00
Victor Zverovich
11b07a56b2
We should escape
2021-08-19 14:50:59 -07:00
Victor Zverovich
b559cfd4c0
Implement basic escaping
2021-08-19 14:12:26 -07:00
Victor Zverovich
11d49491cb
Handle global locale
2021-08-14 09:38:41 -07:00
Victor Zverovich
6ea6cf9464
Add decimal separator support to float
2021-08-14 09:16:26 -07:00
Victor Zverovich
9730a2af0a
Update ChangeLog.rst
2021-08-13 10:07:48 -07:00
Victor Zverovich
c2ed5f6863
Update ChangeLog.rst
2021-08-13 10:07:20 -07:00
Chris White
7b66e72e2c
Use builtin intrinsics on intel ( #2450 )
2021-08-11 06:22:02 -07:00
Victor Zverovich
d57b2a6525
Suppress a warning
2021-08-08 09:18:46 -07:00
Victor Zverovich
bdfbd794e3
Cleanup begin/end usage
2021-08-07 08:55:01 -07:00
Victor Zverovich
111de881fa
Don't copy non-const-iterable ranges
2021-08-07 07:34:02 -07:00
Victor Zverovich
d6e882ed84
Undo the move because the doc is not a GH template
2021-08-06 11:22:33 -07:00
Cory Quammen
f488eed101
Resolve default constructor error in Xcode 7.2.1 and 8.2.1
...
Fix issue that produces the error 'default initialization of an object
of const type 'const detail::buffer_size' without a user-provided
default constructor'
2021-08-06 11:17:02 -07:00
Victor Zverovich
652c3653bb
Move CONTRIBUTING.md to .github
2021-08-06 10:56:05 -07:00
Nikita Sobolev
fb19faa31b
Improves README with svg badge ( #2446 )
...
Looks much better now!
2021-08-05 06:50:15 -07:00
Vladislav Shchapov
07211701f4
Disable the -Wstringop-overflow warning from GCC 7 ( #2442 )
2021-08-02 14:20:18 -07:00
Victor Zverovich
bba0a9d962
Make flush public
2021-07-30 07:02:49 -07:00
Victor Zverovich
f1794a8853
Switch to threadsafe death test style
2021-07-29 06:56:38 -07:00
brm
0544a2279b
Exclude fallback functions when FMT_BUILTIN_CLZ(LL) is not defined ( #2434 )
2021-07-25 10:37:18 -07:00
Victor Zverovich
5c222f0561
Add support for nonconst formattable types
2021-07-24 09:53:53 -07:00
Spiros Tsalikis
3def950b84
Set FMT_CAN_MODULE=OFF for MSVC 19.29.30035+
2021-07-23 09:35:09 -07:00
Spiros Tsalikis
63fe2d5bd2
Add copy constructor for dynamic_format_arg_store, and test
2021-07-23 09:35:09 -07:00
Victor Zverovich
561834650a
Improve digit count
2021-07-18 09:14:56 -07:00
Johnathan
f20f50368f
Replace throw with FMT_THROW ( #2427 )
...
Using `throw` results in compile errors with `-fno-exceptions`. gcc seems fine with it, but arm-gcc and clang would complain.
2021-07-18 07:08:24 -07:00
Cameron DaCamara
00235d8a99
fix module test odr violations ( #2414 )
2021-07-17 09:16:49 -07:00
Victor Zverovich
2038bf6183
Update format_to usage
2021-07-13 07:56:24 -07:00
Victor Zverovich
e41ac1f875
Don't use deprecated API in docs
2021-07-10 13:42:51 -07:00
Victor Zverovich
8465869d7b
Move ignore_unused to detail
2021-07-09 08:24:11 -07:00
mwinterb
3d53d1539d
Warning removals in test code ( #2399 )
...
* Warning removals in test code.
Mostly 0 to nullptr and adding override to virtual function implementations.
* Fix module-test.
2021-07-09 08:05:02 -07:00
Victor Zverovich
20e4ef8b4c
Pass significand_size by value
2021-07-05 08:51:43 -07:00
Victor Zverovich
c4a3c2342a
Refactor locale handling
2021-07-05 08:25:12 -07:00
Victor Zverovich
7a0d301753
Update README.rst
2021-07-04 07:03:20 -07:00
Daniela Engert
f2b03facd9
Include test sources to pick up functions and classes from the module rather than from the non-modular library which is baked into the test-main library. ( #2356 )
...
This averts linker problems:
- strong ownership model: missing linker symbols
- weak ownership model: duplicate linker symbols
Simplify `gtest-extra.cc` while at it.
2021-07-03 07:21:54 -07:00
Benoît Lormeau
02ad5e11da
Add faint, blink, reverse and conceal to the emphases ( #2394 )
2021-07-02 20:03:55 -07:00
Victor Zverovich
d141cdbeb0
Update version
2021-07-02 16:14:33 -07:00
Victor Zverovich
cfc05e05f0
Bump version
2021-07-02 14:43:31 -07:00
Victor Zverovich
8ea312633b
Update changelog
2021-07-02 14:43:00 -07:00
Victor Zverovich
e461f3dbbe
Minor consitency and comment tweaks
2021-07-02 13:56:37 -07:00
Mattias Ljungström
54014e42e3
silence warning C4100 on MSVC 2019 when exceptions are disabled ( #2397 )
2021-07-02 13:51:49 -07:00
Victor Zverovich
3e7a29cc92
Workaround clang/gcc incompatibility
2021-07-02 13:29:22 -07:00
Victor Zverovich
00a57a9f8f
Update changelog
2021-07-02 08:07:48 -07:00
Victor Zverovich
1d7384530e
Add missing presentation type checks for std::string ( #2402 )
2021-07-02 07:51:04 -07:00
Jonathan Emmett
889bbf27a2
Fix missing std::get overload in MSVC ( #2407 )
...
This replaces the `std::get` call with an unqualified equivalent to allow
it to be treated as a dependent call.
ranges.h needs std::get overloads from `<tuple>` but does not directly
include it. This causes compilation failures in MSVC with /permissive-.
On other platforms `<tuple>` is included as a dependency from other headers
(specifically from `<memory>`), but there is no such implicit dependency in
MSVC's STL.
Fixes #2401
2021-07-01 10:55:46 -07:00
Victor Zverovich
5f8473914c
Remove outdated apidoc
2021-07-01 07:56:53 -07:00
Victor Zverovich
785908ee37
Fix warnings
2021-06-30 06:42:29 -07:00
Greg Sjaardema
fbb70eec5c
suppress unused variable warnings ( #2381 )
...
* suppress unused variable warnings
An arguably better method for suppressing unused variable warnings. The `(void)var` method does not work on many intel compiilers.
This is from Herb Sutter's blog post https://herbsutter.com/2009/10/18/mailbag-shutting-up-compiler-warnings/
* Format to eliminate long lines
* Run clang-format
2021-06-30 06:33:30 -07:00
Javier Honduvilla Coto
002bb759ff
Remove unneeded num_result_bigits decrement
...
For what I see this seems unused?
2021-06-29 06:23:02 -07:00
Marek Kurdej
a3f762c5aa
[doc] Minor: fix `code`.
2021-06-29 06:21:15 -07:00
Eren Okka
c3c27e5ab5
Fix MSVC warning C4819
2021-06-28 06:14:53 -07:00
Victor Zverovich
c6b1f181aa
Fix docs
2021-06-27 09:06:21 -07:00
Victor Zverovich
94564b058e
Fix docs
2021-06-27 08:55:16 -07:00
Victor Zverovich
0fc73a2a85
Merge branch 'master' of github.com:fmtlib/fmt
2021-06-27 08:10:49 -07:00
Victor Zverovich
3156fcf5f4
Switch to older breathe version
2021-06-27 08:10:37 -07:00
Aidan Sun
f85fb9fdff
Adjust definition for FMT_HAS_INCLUDE
...
Adjust definition for FMT_HAS_INCLUDE
Remove check for `!FMT_MSC_VER`
2021-06-27 07:08:29 -07:00
Victor Zverovich
0bc3d664e3
Fix docs
2021-06-27 06:41:54 -07:00
Victor Zverovich
e5c46e13e8
Fix docs: breathe 18 and earlier corrupts trailing return type
2021-06-26 09:55:27 -07:00
Patrick Geltinger
49a3b58c8b
Specify size for static data arrays
2021-06-26 06:55:24 -07:00
Victor Zverovich
d0c8d45a2e
apt update before install
2021-06-26 06:29:53 -07:00
Jason A. Donenfeld
c9a10631cb
format: do not use udl_{arg,formatter} return types when UDL is not in use
...
The udl_{arg,formatter} structs are only defined when
FMT_USE_USER_DEFINED_LITERALS is set, so don't try to define things that
return that struct when it's not defined.
2021-06-26 06:25:16 -07:00
Greg Sjaardema
3bd806f12f
Eliminate intel compiler warning
...
The intel compiler defines `__GNUC__`, but does not support the gcc `_Pragma`. This PR filters out the intel compiler to avoid warnings about an unrecognized function.
2021-06-26 06:16:12 -07:00
Владислав Щапов
fd16bcb20c
Fix bug in cmake join function
2021-06-24 09:10:53 -07:00
Daniela Engert
5221242f6e
Instruct msvc to report the _true_ value in __cplusplus and force _full_ C++ conformance
...
* do this in _some_ tests to improve test coverage and catch possible problems due to that
* fix invalid export of `static constexpr` constant
* fix msvc warnings about unreachable code in high warning levels
2021-06-24 09:10:08 -07:00
Victor Zverovich
31a5f0d399
Bump version in inline namespace
2021-06-22 14:47:59 -07:00
Victor Zverovich
102a4d492a
Bump version in inline namespace
2021-06-22 07:04:02 -07:00
Victor Zverovich
f68508b6ce
Update ChangeLog.rst
2021-06-21 18:37:56 -07:00
Victor Zverovich
9e8b86fd2d
Update version
2021-06-21 05:59:17 -07:00
Victor Zverovich
92fec0f050
Bump version
2021-06-21 05:57:50 -07:00
Victor Zverovich
4749cc930a
Update changelog
2021-06-19 08:16:43 -07:00
Victor Zverovich
78a0ba0a6a
Improve conversion of paragraphs
2021-06-19 08:02:52 -07:00
Victor Zverovich
7a39837d96
Use a working breathe version
2021-06-19 07:35:09 -07:00
Victor Zverovich
55b6e92db5
Fix docs
2021-06-19 06:31:19 -07:00
Victor Zverovich
69dc3a8535
Fix docs
2021-06-18 12:51:48 -07:00
Victor Zverovich
27f4cdd586
Update changelog
2021-06-18 12:23:16 -07:00
Victor Zverovich
70d61a0ae3
Update changelog
2021-06-18 08:32:43 -07:00
Victor Zverovich
427b534054
Add no_value state to value
2021-06-15 07:53:28 -07:00
Victor Zverovich
e421d52713
Simplify error handling in parse_nonnegative_int
2021-06-14 16:05:37 -07:00
Владислав Щапов
a59678f376
Fix chrono_test.locale
...
UTF-8: https://datatracker.ietf.org/doc/html/rfc3629
2021-06-14 09:41:08 -07:00
Владислав Щапов
c98254c3d7
Install locales into CI
2021-06-14 09:41:08 -07:00
Владислав Щапов
c123a72844
Fix set locale error in chrono formatter
2021-06-14 09:41:08 -07:00
Victor Zverovich
3c8fad126c
Optimize parse_nonnegative_int
2021-06-13 19:20:44 -07:00
sunmy2019
f28cf3302d
adding a default format for std::chrono::time_point<std::chrono::syst… ( #2345 )
2021-06-11 10:52:39 -07:00
Daniela Engert
55010a9d3a
Support non-char overloads (module)
2021-06-11 09:38:53 -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
3423d75475
Remove the msvc workaround ( #2351 )
2021-06-11 06:20:25 -07:00
Владислав Щапов
f6b5cc9f84
Fix chrono_test.weekday on legacy glibc
2021-06-10 16:17:10 -07:00
Daniela Engert
59a298f124
Enable enforce-checks-test for MSVC, too
2021-06-10 12:54:54 -07:00
Victor Zverovich
36c2948225
Update docs
2021-06-08 08:25:50 -07:00
Victor Zverovich
c9fe1fa5ba
Remove unused flag
2021-06-08 08:00:37 -07:00
Victor Zverovich
dccddc2bdb
Apply clang-format
2021-06-07 08:49:47 -07:00
Victor Zverovich
0e36681b8e
Cleanup digit count
2021-06-07 07:42:22 -07:00
Victor Zverovich
1de80f5b22
Workaround lack of static constexpr in constexpr functions
2021-06-07 07:27:56 -07:00
Victor Zverovich
2039dce75f
Detect consteval
2021-06-07 06:57:43 -07:00
Victor Zverovich
d551b88a6d
Move is_char specializations to xchar.h
2021-06-06 15:32:30 -07:00
Victor Zverovich
16c3514d01
wchar-test -> xchar-test
2021-06-06 07:59:18 -07:00
Victor Zverovich
206000a017
Workaround pathological conversion ( #2343 )
2021-06-06 07:18:44 -07:00
Victor Zverovich
76ee490468
Move wchar/custom char overloads to xchar.h
2021-06-05 22:57:45 -07:00
Victor Zverovich
e77b22d6da
Deprecate memory buffer overload of format_to
2021-06-05 14:58:36 -07:00
Victor Zverovich
07039f4b19
Update README.rst
2021-06-05 06:32:22 -07:00
Victor Zverovich
4678192c88
Remove bsr2log10
2021-06-04 21:33:05 -07:00
Victor Zverovich
7c3d3dfa29
Update thousands_sep_impl signature
2021-06-04 21:12:47 -07:00
Victor Zverovich
ef826b86cb
Fix docs
2021-06-04 20:34:58 -07:00
Victor Zverovich
5223f552c8
Remove FMT_ALWAYS_INLINE
2021-06-04 20:29:54 -07:00
Victor Zverovich
cfde93afe0
Add FMT_STATIC_CONSTEXPR
2021-06-04 16:50:09 -07:00
Cristi
986a5a6c2c
Fixed join_view formatter for wchar_t
2021-06-04 14:50:45 -07:00
Tobias Ribizel
7c8b35ff32
fix MSVC Win32 count_digits
2021-06-04 11:06:25 -07:00
Victor Zverovich
3eeb084e71
Optimize count_digits
2021-06-04 09:14:58 -07:00
Victor Zverovich
2ac0bfe59e
Improve handling of thousands separator
2021-06-04 06:12:44 -07:00
Alexey Ochapov
024741b476
CI: set up multi-thread build for all platforms
2021-06-04 05:56:55 -07:00
Victor Zverovich
f4c95f6dd9
Improve handling of thousands separator
2021-06-03 18:25:08 -07:00
Victor Zverovich
d4fbeacc33
Fix docs build
2021-06-03 18:25:08 -07:00
Victor Zverovich
0eef389ddb
Code style
2021-06-03 18:25:08 -07:00
Victor Zverovich
e27b1ce50c
Fix docs
2021-06-03 09:32:12 -07:00
Victor Zverovich
9f8b6daca2
Fix wheel installation
2021-06-03 09:10:07 -07:00
Victor Zverovich
6060bcfc8a
Fix docs
2021-06-03 09:03:00 -07:00
Victor Zverovich
ff9673463c
Fix docs
2021-06-03 08:43:41 -07:00
Victor Zverovich
1085cc2178
Fix docs
2021-06-03 08:28:02 -07:00
Victor Zverovich
11addaa16e
Update docs
2021-06-03 06:24:17 -07:00
Victor Zverovich
760ca5ccc0
Update docs
2021-06-02 19:45:42 -07:00
Victor Zverovich
290d3f8b61
Cleanup ranges API
2021-06-02 17:06:02 -07:00
Victor Zverovich
aa09e0f5dd
Update docs
2021-06-02 16:25:21 -07:00
Victor Zverovich
d142579e97
Cleanup the format API
2021-06-02 16:25:21 -07:00
Владислав Щапов
f286139d22
Fix "undefined reference to `fmt::v7::detail::basic_data<void>::digits'"
...
Remove unused FMT_EXTERN_TEMPLATE_API
2021-06-02 14:33:17 -07:00
Victor Zverovich
7b9d69b827
Add xchar.h to docs
2021-06-02 08:19:54 -07:00
Victor Zverovich
cbd861f188
Update docs
2021-06-02 08:06:52 -07:00
Victor Zverovich
faf972f039
Update docs
2021-06-02 07:46:26 -07:00
Victor Zverovich
622d1c0423
Update changelog
2021-06-02 07:36:27 -07:00
Victor Zverovich
634c948769
Update changelog
2021-06-02 07:13:06 -07:00
Victor Zverovich
a04e3a2dc8
Comment
2021-06-01 20:47:16 -07:00
Victor Zverovich
87876d5474
Cleanup the printf implementation
2021-06-01 20:32:56 -07:00
Victor Zverovich
d338d66324
Cleanup the printf implementation
2021-06-01 19:30:46 -07:00
Victor Zverovich
272660e704
Remove deprecated printf functions
2021-06-01 18:08:31 -07:00
Victor Zverovich
5a95c5ae2c
Update changelog
2021-06-01 17:47:23 -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
ad97258915
Merge branch 'master' of github.com:fmtlib/fmt
2021-06-01 13:38:26 -07:00
Victor Zverovich
ed2a6377e7
Workaround msvc constexpr issues
2021-06-01 13:32:44 -07:00
Alexey Ochapov
9976869549
fix custom types formatting at compile-time, add test
2021-06-01 11:16:05 -07:00
Victor Zverovich
8c1b22ba6d
Workaround a gcc 9.1 bug ( #2334 )
2021-06-01 06:43:30 -07:00
Victor Zverovich
2dba1cfac1
Update changelog
2021-05-31 19:19:09 -07:00
Daniela Engert
d7ba6c3ea8
Use qualified name-lookup in module. ( #2324 )
...
Allow lookup of non-exported names from local classes in function templates.
2021-05-31 09:11:24 -07:00
Victor Zverovich
bf9904ee4d
Workaround msvc bugs
2021-05-31 08:25:05 -07:00
Victor Zverovich
577bce9029
Apply clang-format
2021-05-31 08:09:10 -07:00
Daniela Engert
ba4c7f193b
Swap parameter order to match #2327 ( #2329 )
2021-05-31 07:44:33 -07:00
Victor Zverovich
e9e89b355b
Update ChangeLog.rst
2021-05-31 07:43:29 -07:00
Victor Zverovich
9bb406d78d
Update changelog
2021-05-31 07:37:10 -07:00
Victor Zverovich
11a14db286
Update format_to taking a buffer and remove undocumented vformat_to overload
2021-05-30 07:57:51 -07:00
Victor Zverovich
832ec098fc
Fix argument order in locale overload of vformat_to ( #2327 )
2021-05-30 06:42:09 -07:00
Victor Zverovich
486a80e8ef
Move wchar_t overloads to xchar.h
2021-05-30 06:41:39 -07:00
Victor Zverovich
19d45f4b31
Update changelog
2021-05-29 16:56:33 -07:00
Victor Zverovich
5a2b88f6e9
Reduce binary size
2021-05-29 16:45:43 -07:00
Daniela Engert
00a39ad5f8
Enable Char types other than char ( #2323 )
2021-05-29 11:42:16 -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
Victor Zverovich
0901176fe4
arg_join -> join_view
2021-05-29 08:47:16 -07:00
Victor Zverovich
a9a9018191
Move wmemory_buffer to wchar.h
2021-05-29 08:26:04 -07:00
Victor Zverovich
4a7801c3ec
Update changelog
2021-05-29 08:14:25 -07:00
Victor Zverovich
517578f80e
Update changelog
2021-05-29 07:48:59 -07:00
Victor Zverovich
85442ed045
Update changelog
2021-05-29 07:43:21 -07:00
Victor Zverovich
6a12b13a85
Update changelog
2021-05-29 07:39:35 -07:00
Victor Zverovich
1cfe3c7382
Update ChangeLog.rst
2021-05-29 07:30:47 -07:00
Victor Zverovich
c06014792b
Update changelog
2021-05-29 07:30:07 -07:00
Victor Zverovich
6fe04871f4
Update changelog
2021-05-29 07:20:29 -07:00
Victor Zverovich
9d67988aed
FMT_DEPRECATED_WCHAR -> FMT_DEPRECATED_INCLUDE_WCHAR
2021-05-29 06:41:07 -07:00
Victor Zverovich
765b451edd
Update changelog
2021-05-29 06:15:49 -07:00
Jose Miguel Pérez
17c993c753
Fixed compilation with CMake < 3.7 ( #2321 )
2021-05-28 20:24:31 -07:00
Victor Zverovich
dde6937319
Update changelog
2021-05-28 16:20:46 -07:00
Daniela Engert
272b0f36b3
More module tests ( #2309 )
...
core.h, format.h, args.h, chrono.h, color.h, printf.h, os.h
2021-05-28 15:49:39 -07:00
Daniela Engert
126c8cb46b
Export os.h API, too ( #2318 )
2021-05-28 09:27:45 -07:00
Matthias Liedtke
98b9ff47a1
Align hex floats right as default ( #2317 )
2021-05-28 09:21:01 -07:00
Victor Zverovich
ece4b4b33a
Update changelog
2021-05-28 06:53:33 -07:00
Liedtke
a70a4ae053
Ignore zero-padding for non-finite floating points ( #2310 )
...
* Ignore zero-padding for non-finite floating points
* keep width for non-finite formatting with 0-padding
* clang-format
* preserve alignment
* align code-style
2021-05-27 14:13:05 -07:00
Victor Zverovich
7612f18dc8
Update changelog
2021-05-27 07:06:13 -07:00
Victor Zverovich
b9f2c27661
Update changelog
2021-05-26 21:12:03 -07:00
Victor Zverovich
4e21baff43
Simplify get_units
2021-05-26 18:26:00 -07:00
Victor Zverovich
683ef11ab9
Update changelog
2021-05-26 18:25:21 -07:00
John Melas
ca466374bd
qualify make_format_args ( #2315 )
...
Co-authored-by: John Melas <john@jmelas.gr>
2021-05-26 06:42:02 -07:00
Victor Zverovich
5a2a185682
Make buffers non-movable
2021-05-25 17:30:17 -07:00
Alexey Ochapov
ee52a6dc40
add fmt::print() overload to support compiled format ( #2304 )
2021-05-25 14:54:56 -07:00
sven-herrmann
82607efb57
Fixed int conversion warning ( #2313 )
...
* Fixed int conversion warning
Compiler warns about conversion from int to size_t, thus added explicit cast.
* now using detail::to_unsigned for the cast
2021-05-25 08:13:39 -07:00
Victor Zverovich
35a2c2a743
Refactor chrono formatting
2021-05-25 06:57:47 -07:00
Victor Zverovich
b955e7a6b2
Refactor chrono formatting
2021-05-24 15:33:33 -07:00
Victor Zverovich
883d9595c5
Support alternative locale names in tests
2021-05-24 14:09:19 -07:00
Mark de Wever
1f308a3cea
Update integer presentation types documentation.
...
Documents that the 'c' type is a valid type for integer types. Since
boolean uses the same types as integer its documentation is
automatically updated.
2021-05-24 10:55:08 -07:00
Victor Zverovich
1cd9899cf3
Add initial support for weekday formatting
2021-05-24 10:21:34 -07:00
Victor Zverovich
069131dc25
Add unicode-test
2021-05-24 06:20:51 -07:00
Victor Zverovich
dd8f38fcbb
Cleanup printf API
2021-05-23 20:30:26 -07:00
Victor Zverovich
a216f2562d
Remove undocumented and obsolete vprintf overload
2021-05-23 20:15:02 -07:00
Victor Zverovich
0c0926395d
Add is_exotic_char trait
2021-05-23 19:50:17 -07:00
Victor Zverovich
bc13c6de39
Update README.rst
2021-05-23 07:45:33 -07:00
Daniela Engert
8ec0b9e33b
Do *not* export namespace detail
2021-05-23 06:49:07 -07:00
Daniela Engert
b99c2bd345
Remove deprecated locale.h from module interface unit
2021-05-23 06:17:25 -07:00
Victor Zverovich
c04a24399a
Update changelog
2021-05-22 20:55:56 -07:00
Victor Zverovich
b099a56f9f
Update changelog
2021-05-22 16:12:38 -07:00
Victor Zverovich
703005c8ba
Deprecate locale.h
2021-05-22 10:21:17 -07:00
Victor Zverovich
51f0178625
Cleanup the format API
2021-05-22 07:09:09 -07:00
Victor Zverovich
5d59dcf66e
Remove deprecated aliases / undeprecate has_formatter
2021-05-22 06:53:34 -07:00
Victor Zverovich
c242dd402c
Move cerrno include to where it is used
2021-05-22 06:18:40 -07:00
Victor Zverovich
2216e0b779
Update changelog
2021-05-22 06:04:33 -07:00
Victor Zverovich
1c83a49be9
Simplify buffer extraction
2021-05-21 20:15:56 -07:00
Victor Zverovich
2617384d8e
Improve buffer extraction
2021-05-21 19:44:49 -07:00
Victor Zverovich
34b8acaef7
More wchar_t-specific API to wchar.h
2021-05-21 18:24:39 -07:00
Victor Zverovich
6326c18906
Improve code style consistency
2021-05-21 17:29:15 -07:00
Matthew Gilbert
5c4b0c86fb
Add missing Allocator template argument for basic_memory_buffer in format_to
...
Remove deduced default template arguments in format_to and moves the
SFINAE check to a non-deduced template parameter.
2021-05-21 12:13:46 -07:00
Victor Zverovich
00149c0b6a
Move detail::null to chrono where it is used
2021-05-21 09:16:45 -07:00
Victor Zverovich
c5c968cb22
Improve binary size
2021-05-21 08:50:35 -07:00
Sergiu Deitsch
128cbdeb2f
cmake: hide private symbols by default
2021-05-21 08:25:08 -07:00
Victor Zverovich
18af1dc460
Fix binary size regression caused by b268f88
2021-05-20 18:33:45 -07:00
Victor Zverovich
d1e6f0f8c6
Fix binary size regression caused by b268f88
2021-05-20 18:00:19 -07:00
Daniela Engert
5a0d99fa0b
Add a test for the module
2021-05-20 10:26:31 -07:00
Daniela Engert
6e2e6b796f
Restore support for wchar_t overloads in module
2021-05-20 10:03:58 -07:00
Victor Zverovich
24b677d053
Improve symbol sizes
2021-05-20 07:21:20 -07:00
Victor Zverovich
63271a51c4
Fix ADL issues
2021-05-20 06:31:43 -07:00
Victor Zverovich
61b4c923d7
Reduce code bloat
2021-05-20 05:51:45 -07:00
Michael Winterberg
2a2e4c5801
addressing nits.
2021-05-19 16:09:49 -07:00
Michael Winterberg
be48f4d657
Avoid unwanted sign extensions from MSVC in is_utf8.
...
Microsoft's constexpr evaluator treats the type of micro[0] and micro[1] as
plain char, and so sign extends before comparing them to ints.
The normal compiler, including the optimizer, does not fail in this way,
so this is merely a "future proof" change in case someone uses is_utf8()
in a constant expression.
2021-05-19 16:09:49 -07:00
Sergiu Deitsch
13e652939b
export missed symbols
...
Enable `-fvisibility=hidden` and `-fvisibility-inlines-hidden` by default in CI builds to ensure all public symbols are exported correctly.
2021-05-19 16:03:45 -07:00
Jessy De Lannoit
71fb113818
fix compile error on msvc preview 4 (16.10) involving lookup clash /w STL
2021-05-19 13:17:20 -07:00
Victor Zverovich
08d22503bb
Remove outdated comments
2021-05-19 11:47:21 -07:00
Victor Zverovich
56f518a98f
Update signatures
2021-05-19 09:45:33 -07:00
Victor Zverovich
b7f2933744
Update signatures
2021-05-19 09:39:32 -07:00
Victor Zverovich
7483dfc652
Update signatures
2021-05-19 09:36:12 -07:00
Victor Zverovich
95c358f721
Improve separation between code unit types
2021-05-19 09:06:57 -07:00
Victor Zverovich
39c3c4ec22
Simplify the core API
2021-05-19 08:32:57 -07:00
Victor Zverovich
e9c1c415b8
Improve compile-time checks
2021-05-19 07:57:57 -07:00
Victor Zverovich
21d93bfd33
Move generic format functions to format.h
2021-05-18 19:01:43 -07:00
Victor Zverovich
9a92eb4158
Move more wchar overloads to wchar.h
2021-05-18 05:53:25 -07:00
Victor Zverovich
0dd91e20d5
Add wchar.h for wide char overloads
2021-05-17 21:59:10 -07:00
Victor Zverovich
ce14eafc24
Simplify format string checks
2021-05-17 19:25:50 -07:00
Victor Zverovich
8d70c0edab
Refactor the format API
2021-05-17 18:25:36 -07:00
Victor Zverovich
813ac49543
More API cleanups
2021-05-17 07:58:13 -07:00
Victor Zverovich
4ab01fb198
Cleanup printf API
2021-05-17 07:19:50 -07:00
Victor Zverovich
d5036b11b1
Remove deprecated APIs
2021-05-17 06:59:46 -07:00
Victor Zverovich
2581946231
Cleanup the core API
2021-05-16 13:02:01 -07:00
Victor Zverovich
b35db4e006
Improve handling of 128-bit ints
2021-05-16 11:43:44 -07:00
Victor Zverovich
d35f1ad5c1
Cleanup core
2021-05-16 10:02:33 -07:00
Victor Zverovich
8f1902c05a
Move format string checks to core.h
2021-05-16 07:08:49 -07:00
Daniela Engert
6469b9037c
Silence msvc warning about an unused named parameter
...
Warning C4100 may cause compile failures under strict warning regimes.
2021-05-16 06:14:30 -07:00
Victor Zverovich
7d4c92fb00
Update ChangeLog.rst
2021-05-15 17:19:27 -07:00
Jussi Viiri
0763d8cadf
Fix Visual Studio warning
2021-05-15 17:13:15 -07:00
Daniela Engert
5466373a11
Do *not* export namespace detail
...
Introduce `FMT_BEGIN_DETAIL_NAMESPACE` and `FMT_END_DETAIL_NAMESPACE` for `namespace detail` sections embedded in that part of the code that contains all declarations that are exported from the module, i.e. which is enclosed by `FMT_MODULE_EXPORT_BEGIN` and `FMT_MODULE_EXPORT_END`. Given a correct implementation of C++20 modules, neither the name `fmt::detail` nor any of its contents will become visible outside of the module.
2021-05-15 12:08:42 -07:00
Victor Zverovich
588bdb5404
Simplify get_arg_index_by_name
2021-05-15 06:47:43 -07:00
Alexey Ochapov
54f22a3eef
add support for statically named arguments with FMT_STRING
2021-05-14 16:31:10 -07:00
Daniela Engert
ea94d6d93c
Prevent ambiguity in name lookup
...
Unqualified calls to 'make_format_args' may find the same name by ADL in <format> if this C++20 header happens to be directly or indirectly included in a translation unit. Do a qualified lookup instead.
2021-05-14 07:10:02 -07:00
Victor Zverovich
57280762b6
Move specs checker to core.h
2021-05-13 19:33:09 -07:00
Victor Zverovich
ced3037523
Move dynamic specs to core.h
2021-05-13 19:01:21 -07:00
Victor Zverovich
dd2bc998ab
Move specs to core.h
2021-05-13 18:48:15 -07:00
Victor Zverovich
08da1adcf6
Remove unused headers
2021-05-13 17:58:15 -07:00
Victor Zverovich
3be0cc2087
Fix handling of 128-bit ints
2021-05-13 17:53:23 -07:00
Daniela Engert
9648bdce30
add missing header
2021-05-13 05:39:18 -07:00
Victor Zverovich
d1aebdbde0
Inline format_to
2021-05-12 18:07:59 -07:00
Victor Zverovich
8f0fadfaaa
Cleanup docs
2021-05-11 20:20:03 -07:00
Victor Zverovich
02896dabee
Avoid use after move ( #2278 )
2021-05-11 16:58:07 -07:00
Владислав Щапов
0036a1d195
Fix issue #2274 .
2021-05-10 15:57:23 -07:00
Владислав Щапов
2a9b314627
Replace fmt::error_code to std::error_code
2021-05-09 12:26:19 -07:00
Victor Zverovich
2165bef4ca
Update README.rst
2021-05-09 09:35:44 -07:00
Victor Zverovich
4862930845
Optimize format string compilation
2021-05-09 09:15:55 -07:00
Victor Zverovich
3207a8bbbf
Get rid of unnecessary recursion to enable inlining
2021-05-09 07:54:13 -07:00
Victor Zverovich
6214f15a0c
Optimize standard formatter specialization
2021-05-09 07:11:35 -07:00
Victor Zverovich
cd2c78fb8a
Use write directly in formatter specializations
2021-05-09 07:07:51 -07:00
Владислав Щапов
4211d86539
Add a formatter specialization for std::error_code.
2021-05-09 06:29:39 -07:00
Victor Zverovich
39f28424ca
Cleanup tests
2021-05-07 21:27:58 -07:00
Victor Zverovich
84feeb0f36
Remove redundant comments and put common case check first
2021-05-07 17:14:29 -07:00
Victor Zverovich
2665afb515
Cleanup add-subdirectory-test
2021-05-07 16:42:02 -07:00
Victor Zverovich
d0abe7c246
Make chrono formatting locale-independent by default
2021-05-07 16:14:10 -07:00
Victor Zverovich
50fb0b5eae
Fix formatting
2021-05-07 08:52:49 -07:00
Victor Zverovich
16f2ef91ab
Replace fmt::system_error with std::system_error
2021-05-07 08:33:39 -07:00
Victor Zverovich
4b885c8633
Replace windows_error with system_error
2021-05-07 06:19:03 -07:00
Victor Zverovich
5238055f40
Move esoteric char type support to format.h
2021-05-06 09:02:00 -07:00
Victor Zverovich
9ac088f376
Add fmtlog to projects
2021-05-06 08:39:36 -07:00
Victor Zverovich
849c9f6168
Move is_name_start to core
2021-05-06 08:12:24 -07:00
Victor Zverovich
23892caf53
Move more parsing to core
2021-05-06 07:37:40 -07:00
Victor Zverovich
8e6390c32c
Move FMT_STRING to core
2021-05-06 07:19:41 -07:00
Victor Zverovich
51a33713fc
Move parsing to core
2021-05-06 07:01:29 -07:00
Victor Zverovich
9c3af11a92
Cleanup tests
2021-05-05 18:31:41 -07:00
Victor Zverovich
9d7b53cb9b
Remove redundant formatter specialization for byte
2021-05-05 08:14:12 -07:00
Victor Zverovich
f0095ccd34
Add support for ranges of types without formatters to join ( #2262 )
2021-05-05 07:43:46 -07:00
Victor Zverovich
4f0eadfce4
Exclude fallback from is_formattable
2021-05-05 06:29:51 -07:00
Victor Zverovich
400b953fbb
Use [] instead of {} in ranges for consistency with Python format
2021-05-04 21:04:21 -07:00
Victor Zverovich
38bcc04a11
Drop range limit and cleanup tests
2021-05-04 20:53:56 -07:00
Victor Zverovich
c738c3431f
Cleanup tests
2021-05-04 17:23:13 -07:00
Victor Zverovich
ed7c4320f6
Cleanup tests
2021-05-02 09:28:38 -07:00
Victor Zverovich
9155e2de4c
Cleanup tests
2021-05-01 17:11:45 -07:00
Victor Zverovich
38127d9ec0
Cleanup tests
2021-04-30 15:50:03 -07:00
Victor Zverovich
c9c0e5077d
Cleanup tests
2021-04-30 06:42:38 -07:00
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
Victor Zverovich
0b41145443
Update README.rst
2021-04-10 08:31:47 -07:00
Victor Zverovich
00f3d16b12
Update docs
2021-04-10 08:07:16 -07:00
Victor Zverovich
99c2f7a349
Allow including fmt/core.h in the header-only mode
2021-04-10 07:44:36 -07:00
Alexey Ochapov
b441532396
CI linux: add clang++-11 C++20 (with LLVM libc++) build
...
* find-package-test fixed by passing CXX_FLAGS, i.e. -stdlib=libc++
* std::array usage in compile-test.cc replaced with plain array, because
<array> header was not included
2021-04-10 07:20:05 -07:00
Alexey Ochapov
1dbadb6527
CI linux: add clang++-11 C++20 build
2021-04-10 07:20:05 -07:00
Alexey Ochapov
09dbad47e1
CI linux: add missing build_type
...
for g++-8 C++14, g++10 C++17, g++10 C++20
2021-04-10 07:20:05 -07:00
Alexey Ochapov
e2facffe4d
CI linux: remove excessive clang++-9 include
2021-04-10 07:20:05 -07:00
denchat
273d8865e3
Suppress redef warning of _CRT_SECURE_NO_WARNINGS if any. ( #2218 )
2021-04-08 11:56:35 -07:00
Victor Zverovich
5a8bf1f6a3
Workaround hexfloat inconsistency on windows ( #2205 )
2021-04-07 11:20:08 -07:00
Elliot
78776ee4e2
Fix a conditional expression is constant warning #2210 ( #2211 )
2021-04-07 10:42:11 -07:00
jstaahl
266107f57c
constexpr uint128_wrapper ( #2215 )
...
* constexpr uint128_wrapper
* change FMT_CONSTEXPR to constexpr
* clang format
Co-authored-by: Jake Staahl <jstaahl@snapchat.com>
2021-04-06 22:07:01 -07:00
Alexey Ochapov
2e0d64cf2f
specify size for prefixes static data
2021-04-06 17:07:14 -07:00
Victor Zverovich
95da484727
Fix a link
2021-04-03 09:14:52 -07:00
Victor Zverovich
06b3a1000c
Add support for time points with arbitrary durations ( #2208 )
2021-04-02 11:17:14 -07:00
Victor Zverovich
dac42f52b2
Inline fallback is_constant_evaluated
2021-04-01 10:42:09 -07:00
Victor Zverovich
7c43f8b896
Don't use strlen at compile time ( #2205 )
2021-04-01 10:04:21 -07:00
Jason Cobb
c62e4c30f4
Make buffer_appender default-constructible when back_insert_iterator is
2021-04-01 09:52:44 -07:00
Victor Zverovich
0d6b70d96b
Install gcc 8
2021-04-01 09:19:36 -07:00
Victor Zverovich
15c10b0c66
Add speech synthesis support
2021-04-01 09:19:36 -07:00
Billy Donahue
308510eb4f
"Use" fwrite result (workaround for warn_unused_result)
...
Fixes #2185
2021-03-31 08:31:35 -07:00
Victor Zverovich
afe23e7f10
Don't call fileno on NULL file in tests ( #2196 )
2021-03-30 10:41:12 -07:00
Victor Zverovich
b49af043d7
Remove noexcept from file's move assignment
2021-03-30 09:51:25 -07:00
vtta
14848875bf
Fix: fmt::ostream cannot be moved while holding buffered data #2197 ( #2198 )
...
* Add a test case: move ostream while holding data
* Fix moving ostream while holding data
Co-authored-by: Junliang HU <jlhu@cse.cuhk.edu.hk>
2021-03-30 08:43:26 -07:00
Victor Zverovich
7d8c34018e
Update pull_request_template.md
2021-03-30 08:42:11 -07:00
Victor Zverovich
b966afcc7a
Remove formattable
2021-03-28 14:21:12 -07:00
Victor Zverovich
ec5315a987
Use strlen when possible in fallback basic_string_view
2021-03-28 08:01:55 -07:00
Victor Zverovich
4f8778bab9
Inline basic_format_args's ctor
2021-03-28 07:32:17 -07:00
Yaser Afshar
e2d87548f8
user-defined constructor
...
user-defined constructor added to prevent Intel compilers
warnings. According to the standard, objects need to have a
user-defined constructor if instances are delcared const.
2021-03-28 06:56:14 -07:00
Yaser Afshar
f7151d384b
Extra flag to prevent Intel compiler with Clang front-end warning of 'unknown attribute no_sanitize'
2021-03-28 06:56:14 -07:00
Victor Zverovich
0fb8ef8f79
Inline trivial argument handling functions
2021-03-27 19:05:39 -07:00
Victor Zverovich
1b23e25f95
Simplify formattability check
2021-03-27 18:57:18 -07:00
Victor Zverovich
35c71ff536
Only use -Og with optimizations disabled
2021-03-27 11:35:01 -07:00
Victor Zverovich
243d8bebd1
Enable minimal optimizations in debug mode
2021-03-27 08:40:07 -07:00
Chris White
9b34681d97
Work around xl compiler bug when nvcc preprocesses this file ( #2190 )
2021-03-27 06:05:49 -07:00
Vladislav Shchapov
4dc7170d21
Fix C++17 builds: ( #2192 )
...
- Fix C++17 Visual Studio builds.
- Use C++17 for `windows-2019` builds.
- Removed options for unsupported compiler (MSVC11).
- Removed options, not needed after enabling C++11+ features in gmock/gtest.
2021-03-26 06:19:43 -07:00
Victor Zverovich
9cb347b4b2
Simplify argument formatters
2021-03-21 09:31:46 -07:00
Ryan Sherlock
0f85a4683a
add default cases ( #2186 )
...
Adding default case for switch statements where the compilation
flag -Wswitch-default is present on the command line when spdlog
is included in external projects.
Signed-off-by: Ryan Sherlock <ryan.m.sherlock@gmail.com>
2021-03-19 16:56:52 -07:00
Victor Zverovich
417e1cee9e
Stop using deprecated UDL templates
2021-03-19 08:34:55 -07:00
Victor Zverovich
f7e900e12e
Simplify UDL definitions
2021-03-19 08:10:58 -07:00
Victor Zverovich
d9661c8f3b
Mark grouping as deprecated
2021-03-19 07:54:57 -07:00
Victor Zverovich
14a2a64df4
Fix handling of formattable types with to_string_view ( #2181 )
2021-03-19 06:43:38 -07:00
Victor Zverovich
6ae402fd0b
Fix handling of types with to_string_view and formatter specialization ( #2180 )
2021-03-18 11:25:43 -07:00
Victor Zverovich
a6408a3b09
Add args-test
2021-03-18 09:04:17 -07:00
Victor Zverovich
1147782c79
Fix an ambiguous call to check caused by ADL ( #2184 )
2021-03-17 20:59:36 -07:00
VZ
2f3f3862fa
Fix harmless MSVS warning about using undefined _MANAGED symbol ( #2183 )
...
Since the changes of 1305cbeb (Fix MSVC2019 error C2049 when compiling
with /clr (#1897 ), 2020-09-23), compiling fmt with MSVS 2019 resulted in
fmt\include\fmt\core.h(180,32): warning C4668: '_MANAGED' is not defined
as a preprocessor macro, replacing with '0' for '#if/#elif'.
when the (disabled by default) warning C4668 was enabled.
Fix this simply by checking if _MANAGED is defined before testing it.
2021-03-17 11:21:50 -07:00
Brainy0207
d0bded5988
Fix MSVC /clr builds ( #2179 )
2021-03-15 08:17:28 -07:00
Victor Zverovich
8308f52c2a
Fix dynamic_format_arg_store::push_back comment
2021-03-15 07:10:28 -07:00
Victor Zverovich
6151d0dc1e
Fix the comment
2021-03-14 09:26:18 -07:00
Victor Zverovich
5a1127b726
Don't wrap named arg in cref and clarify docs
2021-03-14 09:08:08 -07:00
moiwi
b8ff3c1820
optimize append ( #2164 )
2021-03-13 07:21:23 -08:00
Alexey Ochapov
c8d8b88223
fix GCC 7,8,9 warning about unused but set parameter ( #2177 )
2021-03-13 06:36:53 -08:00
Victor Zverovich
d28101878a
Document ostream support limitation
2021-03-12 15:49:22 -08:00
Victor Zverovich
bac14ef985
Simplify integer spec checking
2021-03-12 15:02:01 -08:00
Victor Zverovich
8f9db3fcb8
Make ubsan happy on empty format specs ( #2175 )
2021-03-12 09:13:47 -08:00
Victor Zverovich
af567538a0
Bitpack integral prefixes
2021-03-11 21:22:33 -08:00
Victor Zverovich
cdf877d4b1
Workaround missed optimization opportunity
2021-03-11 16:44:59 -08:00
Victor Zverovich
eef4ba9c02
Optimize integer formatting without padding
2021-03-11 15:47:58 -08:00
Victor Zverovich
a1ea8a82c3
Unbloat my heart
2021-03-11 08:27:53 -08:00
Victor Zverovich
a457e16360
Simplify integer formatter
2021-03-11 08:14:03 -08:00
Victor Zverovich
05bc87a66f
Optimize padding
2021-03-10 17:59:36 -08:00
Victor Zverovich
605b603735
Optimize count_digits for powers of 2
2021-03-10 14:48:07 -08:00
Victor Zverovich
85ba271639
Implement 128-bit count_digits in terms of count_digits_fallback
2021-03-10 12:57:46 -08:00
Victor Zverovich
d9835737f0
spec -> specs
2021-03-10 12:51:03 -08:00
Victor Zverovich
f9e0e90441
Apply clang-format
2021-03-10 12:08:02 -08:00
Victor Zverovich
60f5d24411
Simplify arg_formatter
2021-03-10 09:35:48 -08:00
Victor Zverovich
30e1302e73
Simplify on_format_specs
2021-03-10 08:46:16 -08:00
Victor Zverovich
87c5cd46ac
Optimize parsing of argument ids
2021-03-10 07:04:04 -08:00
Alexey Ochapov
6a9016ea60
fix formatted_size with "compiled format" as argument ( #2161 )
2021-03-07 06:44:36 -08:00
Victor Zverovich
6e1fc01752
Move detail::truncating_iterator to fmt/compile.h
2021-03-06 08:35:36 -08:00
Jason Cobb
e718ec3e93
Make truncating_iterator an output_iterator ( #2158 )
2021-03-04 15:53:08 -08:00
John Steele Scott
772aeca338
Don't include <cassert>. ( #2148 ) ( #2152 )
...
* Don't include <cassert>. (#2148 )
This commit replaces use of the assert() macro in format-inl.h with
FMT_ASSERT(). This allows us to drop the cassert include.
* FMT_GCC_VERSION is not defined when we include test-assert.h, use __GCC__ instead.
* Don't explicitly suppress GCC's -Wterminate in tests' FMT_ASSERT.
Throwing from a separate function is enough to silence the warning, no need to
explicitly suppress it.
* Remove messages from assertions added in 2f699d2.
* Correct formatting around throw_assertion_failure().
2021-03-04 07:28:04 -08:00
Alexey Ochapov
684b5b0e40
Fix fallback to runtime API from compile-time API ( #2143 )
...
* fix fallback to the runtime API, add FMT_ENABLE_FALLBACK_TO_RUNTIME_API define, add test
* remove `FMT_ENABLE_FALLBACK_TO_RUNTIME_API`
* pass format string to format_to() inside format_to_n() in compile-time API
instead of compiling it inside format_to_n(), to eliminate code duplication
2021-03-04 07:20:57 -08:00
Alexey Ochapov
d8b9254301
use simplified void_t for all compilers other than gcc 4.x ( #2160 )
2021-03-02 14:42:27 -08:00
Victor Zverovich
835b910e7d
Add an is_formattable trait
2021-02-28 15:25:33 -08:00
Victor Zverovich
578874033a
Revert "Optimize handling of integer constants" ( #2147 )
...
This reverts commit 2797588be121c79915d374788ce530ad642a98cd.
2021-02-25 05:58:58 -08:00
Jiahao XU
640acba850
Print x.what() of FMT_THROW when exception is disabled ( #2145 )
...
Signed-off-by: Jiahao XU <Jiahao_XU@outlook.com>
2021-02-24 06:29:04 -08:00
Alexey Ochapov
d8e1c9f175
fix fmt::get for some GCC versions and legacy Clang ( #2144 )
...
fixes https://github.com/fmtlib/fmt/issues/2140
- some GCC versions decay function pointers to `const void*`, exactly like
MSVC does
- legacy Clang (prior to 7.0) treats function pointers also as `const T*`
pointers, but unable to convert them
2021-02-23 07:18:30 -08:00
Victor Zverovich
2797588be1
Optimize handling of integer constants
2021-02-21 11:11:57 -08:00
Victor Zverovich
e8eff3b8fd
Fix FMT_STATIC_THOUSANDS_SEPARATOR ( #2142 )
2021-02-21 07:42:12 -08:00
Alexey Ochapov
ab0f7d7fdc
use const& for arguments
2021-02-20 11:50:12 -08:00
Alexey Ochapov
29cc8282b1
update chrono duration formatter (constness), use it in compile-test for specs checks
2021-02-20 11:50:12 -08:00
Alexey Ochapov
3f69af3aaf
update wording in the error inside arg_id_handler, use FMT_ASSERT instead of throw
2021-02-20 11:50:12 -08:00
Alexey Ochapov
499047e132
fix incorrect indexing mode for named args, update tests
2021-02-20 11:50:12 -08:00
Alexey Ochapov
78c67157c1
prepare tests, fix incorrect handling of named args with simple {} replacement fields
2021-02-20 11:50:12 -08:00
Alexey Ochapov
b31bc2dc9f
simplify try_format_argument(), make manual_indexing_id() a variable
2021-02-20 11:50:12 -08:00
Alexey Ochapov
95e1aa2dc5
add support for manual indexing and named fields, add tests
2021-02-20 11:50:12 -08:00
Victor Zverovich
7e72673d87
Improve width estimation ( #2033 )
2021-02-13 09:30:29 -08:00
Victor Zverovich
13b117b5bc
Improve code point computation
2021-02-13 08:46:19 -08:00
Victor Zverovich
ee0fed639c
Fix handling of the + flag with locales ( #2133 )
2021-02-13 07:08:01 -08:00
Yuval Gamzon-Kapeller
c5979d564e
Fix fmt::localtime formatting not working in wide-char string contexts
2021-02-13 06:53:30 -08:00
Mike Crowe
e6ef927e6b
fmt::ptr: Support function pointers ( #2131 )
...
Passing a function pointer to fmt::ptr results in:
In file included from /home/mac/git/fmt/test/gmock/gmock.h:238,
from /home/mac/git/fmt/test/format-test.cc:31:
.../fmt/test/format-test.cc: In member function ‘virtual void FormatterTest_FormatPointer_Test::TestBody()’:
.../fmt/test/format-test.cc:1486:56: error: no matching function for call to ‘ptr(void (&)(int, double, std::__cxx11::string))’
format("{}", fmt::ptr(function_pointer_test)));
with GCC and Clang. Let's add an overload to support that usage.
Unfortunately, MSVC would
consider the overload to be ambiguous for unknown reasons:
D:\a\fmt\fmt\test\format-test.cc(1485,1): error C2668: 'fmt::v7::ptr': ambiguous call to overloaded function [D:\a\fmt\build\test\format-test.vcxproj]
D:\a\fmt\fmt\include\fmt/format.h(3742,60): message : could be 'const void *fmt::v7::ptr<void,int,double,std::string>(T (__cdecl *)(int,double,std::string))' [D:\a\fmt\build\test\format-test.vcxproj]
with
[
T=void
]
D:\a\fmt\fmt\include\fmt/format.h(3735,42): message : or 'const void *fmt::v7::ptr<void(int,double,std::string)>(T (__cdecl *))' [D:\a\fmt\build\test\format-test.vcxproj]
with
[
T=void (int,double,std::string)
]
D:\a\fmt\fmt\test\format-test.cc(1486,1): message : while trying to match the argument list '(overloaded-function)' [D:\a\fmt\build\test\format-test.vcxproj]
but luckily this means that the overload is unnecessary in that case
anyway, so we can just make it conditional.
2021-02-09 07:35:16 -08:00
Dan Ibanez
58aa04573f
Fix ordering of install commands for CMake ( #2122 )
...
the library itself needs to be installed before
the fmt-targets.cmake file is installed,
otherwise the installed targets file doesn't
actually point to the library using
IMPORTED_LOCATION
2021-01-30 09:03:55 -08:00
Yin Zhong
1980ca8c4e
fix #2118 : FMT_COMPILE did not work with tm formatter ( #2119 )
...
Co-authored-by: summivox <summivox@github.com>
2021-01-30 08:44:49 -08:00
Alexey Ochapov
2a25e2bf4d
Make ranges-test available with C++11 ( #2114 )
...
* make ranges-test available with C++11, fix problem with some gcc versions
* potentially fix build for MSVC 19.10, a bit reorganizing in test
2021-01-30 07:42:58 -08:00
Yin Zhong
b0b56b4379
fix #2116 (FMT_COMPILE requires exceptions enabled) ( #2117 )
...
Co-authored-by: summivox <summivox@github.com>
2021-01-28 06:58:49 -08:00
Victor Zverovich
373262f9fb
Update docs
2021-01-24 09:11:44 -08:00
Victor Zverovich
ce519e939b
Fix exception propagation from iterators ( #2097 )
2021-01-23 17:27:24 -08:00
Alexey Ochapov
acef0bb51a
use gcc-10.2 instead of gcc-10.1 on CI, also fix one problem ( #2110 )
...
the problem was not detected by test because of wrong gcc-10 minor version on CI
2021-01-23 07:52:41 -08:00
Ivan Polyakov
8bf28e6bb1
Add support for s format specifier to bool ( #2094 ) ( #2109 )
2021-01-23 07:32:41 -08:00
Victor Zverovich
9c418bc468
Update README.rst
2021-01-21 07:45:34 -08:00
Walter Gray
456efa4666
add missing detail namespace ( #2107 )
...
Co-authored-by: Walter Gray <walter.gray@getcruise.com>
2021-01-19 17:44:15 -08:00
Ivan Shynkarenka
80dc7cceb8
Fixed format.h(1465): warning C4702: unreachable code ( #2106 )
...
* Fixed format.h(1465): warning C4702: unreachable code
* Fixed format.h(1416): warning C4702: unreachable code
2021-01-19 17:13:10 -08:00
Victor Zverovich
7fd535c6ae
Cleanup 'L' handling
2021-01-18 07:57:38 -08:00
Victor Zverovich
b4b8917caf
Update docs
2021-01-17 09:36:06 -08:00
Victor Zverovich
e4f2cf455e
Make 'L' a modifier
2021-01-17 09:28:46 -08:00
randomizedthinking
6972b5f3d2
Add build variable: FMT_MASTER_PROJECT ( #2100 )
2021-01-16 16:56:49 -08:00
Victor Zverovich
ac35208115
Install fmt/args.h ( #2096 )
2021-01-16 08:13:38 -08:00
Victor Zverovich
532e846b86
Fix width computation in float formatter
2021-01-15 11:07:55 -08:00
Victor Zverovich
f8c2f8480a
Fix handling of width when formatting int as char
2021-01-14 08:41:17 -08:00
Victor Zverovich
0fe0b15e71
Fix handling of # in width computation
2021-01-13 16:48:07 -08:00
Victor Zverovich
061e364b25
Document output_file
2021-01-09 07:18:56 -08:00
AlιAѕѕaѕѕιN
018688da2a
Correct a typo on syntax.rst (documentation) ( #2081 )
2020-12-31 16:23:42 -08:00
Victor Zverovich
9ec5592bb5
Fix writing to stdout when redirected to NUL on Windows ( #2080 )
2020-12-30 13:23:37 -08:00
Alexey Ochapov
cdc5ef6710
Remove fallback to inline specifier from FMT_CONSTEXPR(20) macro ( #2075 )
2020-12-30 06:23:20 -08:00
Victor Zverovich
c9dd1eb97d
Don't change charset
2020-12-27 07:44:02 -08:00
Alexey Ochapov
d09b5c1453
Fix std::byte formatting with compile-time API ( #2072 )
...
* add test for byte formatting with `FMT_COMPILE`
* fix byte formatting with `FMT_COMPILE`, use `__cpp_lib_byte` macro
* use is not custom mapped type check
* workaround MSVC bug
2020-12-27 07:23:28 -08:00
Alexey Ochapov
bbd6ed5bc5
Add support of most format_specs for formatting at compile-time ( #2056 )
2020-12-25 06:40:03 -08:00
Victor Zverovich
a750bf3ac6
Update api.rst
2020-12-24 07:09:49 -08:00
Victor Zverovich
1256541d7a
Fix formatting
2020-12-24 07:07:15 -08:00
Walter Gray
4fa4c9248f
Add tests for FMT_ENFORCE_COMPILE_STRING, fix several errors ( #2038 )
2020-12-24 06:40:46 -08:00
Issam Maghni
aa89e380d9
add cwchar to format.h for std::fputws ( #2073 )
2020-12-23 07:02:25 -08:00
Björn Schäpers
5a37e182de
Disable warning about format string ( #2067 )
...
Reported by MinGW/GCC 10
2020-12-21 08:43:30 -08:00
Daumantas Kavolis
fa43fd1444
Forward arguments to work with views ( #2068 )
2020-12-20 07:14:54 -08:00
Victor Zverovich
3551f5d118
Workaround a gcc 10 -Warray-bounds bug ( #2065 )
2020-12-19 09:34:43 -08:00
Victor Zverovich
e737672614
Remove an old mingw workaround ( #2059 )
2020-12-10 06:36:04 -08:00
Victor Zverovich
25a41b80fc
Fix a link to Android.mk ( #2057 )
2020-12-09 08:04:58 -08:00
Finkman
9293f7072e
Suppress gcc warning on privates-only class ( #2053 )
...
Since gcc 9 it warns about is_streamable to have only private methods.
Add explicit default ctor instead of suppression
2020-12-09 06:55:17 -08:00
Camille Bordignon
c20874c28f
Reenable support for fallback formatter in join ( #2040 ) ( #2050 )
2020-12-08 08:56:53 -08:00
Alexey Ochapov
5de0bc1d4f
Add UDL as replacement for FMT_COMPILE ( #2043 )
2020-12-07 15:53:11 -08:00
谭九鼎
a6fafe2f01
docs: use https for some links ( #2051 )
2020-12-05 06:41:38 -08:00
Victor Zverovich
33f9a6d360
Fix handling of enums in to_string ( #2036 )
2020-12-03 15:18:33 -08:00
Alexey Ochapov
aabe0a8473
simplify tests by reordering arguments of EXPECT_EQ ( #2044 )
2020-12-03 14:21:23 -08:00
Victor Zverovich
1f4a76d2c8
Add a missing include ( #2047 )
2020-12-03 14:17:09 -08:00
Victor Zverovich
4a6eadbde0
Make std::byte formattabe ( #1981 )
2020-12-03 08:59:07 -08:00
Alexey Ochapov
683a74501f
fix formatting with empty compiled format string ( #2042 )
2020-12-02 07:14:57 -08:00
Victor Zverovich
f43416e1d7
Add a link to contents from index
2020-12-02 06:30:09 -08:00
Victor Zverovich
5a493560f5
Move some code from core.h to format.h where it is used
2020-11-29 09:45:15 -08:00
Victor Zverovich
9ed0a98178
Fix docs build
2020-11-29 09:33:09 -08:00
Alexey Ochapov
dac753b81e
Basics of formatting at compile-time based on compile-time API ( #2019 )
2020-11-29 08:59:11 -08:00
Victor Zverovich
119f7dc3d6
Truncate file by default
2020-11-27 08:15:14 -08:00
Victor Zverovich
22a68d1613
Don't emit trailing zeros by default
2020-11-27 07:45:54 -08:00
Victor Zverovich
d0110b7e35
Update README.rst
2020-11-26 19:51:31 -08:00
Victor Zverovich
3f4839ce3d
Merge branch 'release' of github.com:fmtlib/fmt
2020-11-25 06:41:05 -08:00
Victor Zverovich
7bdf0628b1
Update version
2020-11-24 17:15:02 -08:00
Victor Zverovich
fc1355114d
Update changelog
2020-11-24 17:14:00 -08:00
Victor Zverovich
926233bde8
Fix test
2020-11-24 14:54:15 -08:00
Victor Zverovich
0683fa7d1d
Bump version
2020-11-24 08:36:21 -08:00
Victor Zverovich
6ce207b9a5
Fix formatting
2020-11-24 08:29:17 -08:00
Victor Zverovich
07b1c1a15f
Update changelog
2020-11-24 08:24:14 -08:00
Victor Zverovich
58992761cf
Reintroduce ostream support to range formatters ( #2014 )
2020-11-24 08:22:29 -08:00
Victor Zverovich
b8957f50c3
Fix an overflow in format_to_n ( #2029 )
2020-11-24 08:22:12 -08:00
Victor Zverovich
df66516ed3
Workaround an issue with mixing std versions in gcc ( #2017 )
2020-11-24 08:21:10 -08:00
Victor Zverovich
a57baa69a5
Fix more linkage errors ( #2011 )
2020-11-24 08:17:31 -08:00
Victor Zverovich
85534a1397
Fix linkage errors when linking with a shared library ( #2011 )
2020-11-24 08:15:59 -08:00
Victor Zverovich
a2fa5d6288
Update changelog
2020-11-23 10:35:07 -08:00
Victor Zverovich
cd3003683d
Fix more linkage errors ( #2011 )
2020-11-23 10:34:27 -08:00
Victor Zverovich
d1ef29d679
Fix initialization of iterator_buffer ( #1996 )
2020-11-23 10:28:35 -08:00
Victor Zverovich
5f41bb0f77
clang-format
2020-11-23 10:23:54 -08:00
Victor Zverovich
a58a6b27c3
Add a newline
2020-11-21 16:52:40 -08:00
Victor Zverovich
a036cc97b7
Reintroduce ostream support to range formatters ( #2014 )
2020-11-21 16:31:22 -08:00
Victor Zverovich
38c7def47a
Update clang version to 3.4 since there are ICEs on earlier ones
2020-11-19 10:37:43 -08:00
Jonathan Gopel
5533641319
🆕 [CI] Test with C++14 in Windows 2019 ( #2020 )
...
Problem:
- Both Windows builds test C++14
Solution:
- Use C++11 for `windows-2016` builds and C++14 for `windows-2019`
builds.
Co-authored-by: Jonathan Gopel <jgopel@quantlab.com>
2020-11-19 06:04:16 -08:00
Victor Zverovich
55dfdd9299
Update README.rst
2020-11-18 07:33:38 -08:00
Victor Zverovich
2c734c9bca
Fix an overflow in format_to_n ( #2029 )
2020-11-18 06:50:43 -08:00
Park DongHa
6cdd1be93e
Update build.gradle for latest AGP ( #2026 )
...
* update build.gradle for latest AGP
* bump Android Gradle Plugin version to 4.1.1
* ignore .cxx which was externalNativeBuild in old versions
Use variable 'rootDir' instead of using relative path.
* build.gradle copies AAR files to libs/
2020-11-17 06:31:06 -08:00
Victor Zverovich
bcc20b29df
Implement compile-time checks by default
2020-11-15 17:24:36 -08:00
Walter Gray
befd7d4a2f
Always use FMT_STRING internally where possible [Issue #2002 ] ( #2006 )
...
Co-authored-by: Walter Gray <walter.gray@getcruise.com>
2020-11-15 05:19:06 -08:00
Victor Zverovich
f8640d4050
Add more standards
2020-11-14 12:02:46 -08:00
Victor Zverovich
f81c14aa1e
Workaround an issue with mixing std versions in gcc ( #2017 )
2020-11-14 11:41:51 -08:00
Victor Zverovich
5555651ce0
Fix more linkage errors ( #2011 )
2020-11-14 06:06:10 -08:00
rimathia
b268f8815d
detail::write in one more place relevant to printf with long argument… ( #2016 )
2020-11-13 12:14:16 -08:00
Jonathan Gopel
aa9b09a9e3
🐛 Cannot call non-constexpr function in constexpr context ( #2010 )
...
Problem:
- gcc-8 gives the following error when compiling this function on all
standards:
test/std-format-test.cc: In member function 'constexpr auto std::formatter<S>::parse(std::format_parse_context&)':
test/std-format-test.cc:112:17: error: call to non-'constexpr' function 'int isdigit(int)'
if (!isdigit(c) || (++iter, get_char()) != '}')
~~~~~~~^~~
Solution:
- Write a `constexpr` version of `isdigit` for use in this function.
Co-authored-by: Jonathan Gopel <jgopel@quantlab.com>
2020-11-12 10:10:52 -08:00
rimathia
986fa00406
Printf get container ( #1982 )
...
* eliminate one case where basic_print_context would copy a string into a fmt::basic_memory_buffer character by character instead of using fmt::basic_memory_buffer::append
* use detail::write instead of re-implementing it
* use to_unsigned to avoid signedness conversion warnings
2020-11-12 08:37:04 -08:00
Victor Zverovich
7abc3c01e0
Suppress a useless warning ( #2004 )
2020-11-12 08:18:28 -08:00
Victor Zverovich
6d14f78115
Fix linkage errors when linking with a shared library ( #2011 )
2020-11-12 06:11:17 -08:00
Victor Zverovich
9534b9fe69
Refactor warning suppression
2020-11-12 05:45:36 -08:00
Victor Zverovich
60dc273513
Simplify on_text
2020-11-11 15:13:44 -08:00
Victor Zverovich
b5dac0f0f8
Reduce <algorithm> usage ( #1998 )
2020-11-11 09:12:15 -08:00
Jonathan Gopel
a07627b1f8
🐛 Implicit sign conversion warning in clang in c++17 and 20 modes ( #2009 )
...
Problem:
- On Apple clang version 11.0.3 (clang-1103.0.32.62) in C++17 and C++20
mode, clang 11.0.0 in C++17 and C++20 mode, and clang 9.0.1 in C++17
mode, the following error is generated:
In file included from test/compile-test.cc:16:
include/fmt/compile.h:518:25: error: implicit conversion changes signedness: 'long' to 'unsigned long' [-Werror,-Wsign-conversion]
return {f, pos + (end - str.data()) + 1, ctx.next_arg_id()};
~ ~~~~^~~~~~~~~~~~
include/fmt/compile.h:538:31: note: in instantiation of function template specialization
'fmt::v7::detail::parse_specs<int, char>' requested here
constexpr auto result = parse_specs<id_type>(str, POS + 2, ID);
^
include/fmt/compile.h:569:17: note: in instantiation of function template specialization
'fmt::v7::detail::compile_format_string<fmt::v7::detail::type_list<int>, 0, 0, FMT_COMPILE_STRING>' requested here
detail::compile_format_string<detail::type_list<Args...>, 0, 0>(
^
include/fmt/compile.h:648:37: note: in instantiation of function template specialization
'fmt::v7::detail::compile<int, FMT_COMPILE_STRING, 0>' requested here
constexpr auto compiled = detail::compile<Args...>(S());
^
test/compile-test.cc:140:24: note: in instantiation of function template specialization
'fmt::v7::format<FMT_COMPILE_STRING, int, 0>' requested here
EXPECT_EQ("42", fmt::format(FMT_COMPILE("{:x}"), 0x42));
^
In file included from test/compile-test.cc:16:
include/fmt/compile.h:518:25: error: implicit conversion changes signedness: 'long' to 'unsigned long' [-Werror,-Wsign-conversion]
return {f, pos + (end - str.data()) + 1, ctx.next_arg_id()};
~ ~~~~^~~~~~~~~~~~
include/fmt/compile.h:538:31: note: in instantiation of function template specialization
'fmt::v7::detail::parse_specs<char [4], char>' requested here
constexpr auto result = parse_specs<id_type>(str, POS + 2, ID);
^
include/fmt/compile.h:494:27: note: in instantiation of function template specialization
'fmt::v7::detail::compile_format_string<fmt::v7::detail::type_list<int, int, char const (&)[4], int>, 5, 2, FMT_COMPILE_STRING>'
requested here
constexpr auto tail = compile_format_string<Args, POS, ID>(format_str);
^
include/fmt/compile.h:539:14: note: in instantiation of function template specialization
'fmt::v7::detail::parse_tail<fmt::v7::detail::type_list<int, int, char const (&)[4], int>, 5, 2, fmt::v7::detail::spec_field<char, int, 0>, FMT_COMPILE_STRING>' requested here
return parse_tail<Args, result.end, result.next_arg_id>(
^
include/fmt/compile.h:569:17: note: in instantiation of function template specialization
'fmt::v7::detail::compile_format_string<fmt::v7::detail::type_list<int, int, char const (&)[4], int>, 0, 0, FMT_COMPILE_STRING>'
requested here
detail::compile_format_string<detail::type_list<Args...>, 0, 0>(
^
include/fmt/compile.h:648:37: note: in instantiation of function template specialization
'fmt::v7::detail::compile<int, int, char const (&)[4], int, FMT_COMPILE_STRING, 0>' requested here
constexpr auto compiled = detail::compile<Args...>(S());
^
test/compile-test.cc:145:18: note: in instantiation of function template specialization
'fmt::v7::format<FMT_COMPILE_STRING, int, int, char const (&)[4], int, 0>' requested here
fmt::format(FMT_COMPILE("{:{}}{:{}}"), 42, 4, "foo", 5));
^
2 errors generated.
Solution:
- Explicitly cast the result of the subtraction to the (unsigned) outer
type.
Co-authored-by: Jonathan Gopel <jgopel@quantlab.com>
2020-11-11 07:57:52 -08:00
Jonathan Gopel
1b8f499ee1
🔧 Silence useless cast warnings ( #2008 )
...
Problem:
- gcc-10 is generating the following warning at all standards:
test/format-test.cc: In member function 'virtual void UtilTest_BitCast_Test::TestBody()':
test/format-test.cc:108:42: error: useless cast to type 'uint64_t' {aka 'long long unsigned int'} [-Werror=useless-cast]
108 | s = fmt::detail::bit_cast<uint32_pair>(uint64_t(~0ull));
| ^~~~~~~~~~~~~~~
- gcc-8 is generating the following warning at all standards:
test/format-test.cc: In member function 'virtual void UtilTest_BitCast_Test::TestBody()':
test/format-test.cc:108:56: error: useless cast to type 'uint64_t' {aka 'long long unsigned int'} [-Werror=useless-cast]
s = fmt::detail::bit_cast<uint32_pair>(uint64_t(~0ull));
^
Solution:
- Cast 0 to a 64 unsigned bit int and then invert.
Co-authored-by: Jonathan Gopel <jgopel@quantlab.com>
2020-11-11 07:56:59 -08:00
Victor Zverovich
f428d286a1
Update README.rst
2020-11-11 07:11:43 -08:00
Victor Zverovich
beb248b6ac
Optimize handling of large format strings
2020-11-11 06:11:05 -08:00
Lieven de Cock
1936dddc3c
fix gcc warning of missing override ( #2001 )
...
Co-authored-by: Lieven de Cock <killerbot@linux-2x3u.suse>
2020-11-10 07:57:21 -08:00
Victor Zverovich
14f6bd0f4e
Move one more headers to args.h
2020-11-09 20:35:03 -08:00
Victor Zverovich
e01d26e1a4
Optimize includes
2020-11-09 16:34:54 -08:00
Victor Zverovich
e528d919a8
Merge branch 'master' of github.com:fmtlib/fmt
2020-11-08 12:45:15 -08:00
Victor Zverovich
4881677268
Update signatures
2020-11-08 12:29:26 -08:00
rimathia
3302fd1088
use memchr for searching for '%' in printf format string ( #1984 )
2020-11-08 10:36:00 -08:00
Victor Zverovich
4c2d637203
Update signatures
2020-11-08 10:10:44 -08:00
Victor Zverovich
beaff39618
Update signatures
2020-11-08 10:00:08 -08:00
Victor Zverovich
ffa0a0834a
Use newer versions of Sphinx and Breathe
2020-11-08 09:46:27 -08:00
Victor Zverovich
038057eb3e
Document contexts
2020-11-08 08:16:23 -08:00
Victor Zverovich
5bedcb665b
Fix initialization of iterator_buffer ( #1996 )
2020-11-08 08:08:55 -08:00
Victor Zverovich
2435ea4113
Workaround MSVC mess
2020-11-08 07:48:03 -08:00
Victor Zverovich
8c6215f5de
Fix fmt/color.h
2020-11-08 07:24:07 -08:00
Victor Zverovich
10ebe6cb48
Document color
2020-11-08 07:18:01 -08:00
Victor Zverovich
1ac50fcb5a
Suppress more bogus warnings
2020-11-08 07:04:42 -08:00
Victor Zverovich
e098be8e88
Fix warning filtering
2020-11-08 06:58:41 -08:00
Victor Zverovich
8cf0afaf1c
Improve docs
2020-11-08 06:48:34 -08:00
Victor Zverovich
e29f93e8a8
Suppress more bogus warnings
2020-11-08 06:33:42 -08:00
Victor Zverovich
4e8d000f76
Suppress more bogus warnings
2020-11-08 06:29:50 -08:00
Victor Zverovich
7787792e8d
Fix re usage
2020-11-08 06:20:53 -08:00
Victor Zverovich
6ee5e507c7
Fix imports
2020-11-08 06:16:49 -08:00
Victor Zverovich
06ee32d1b5
Filter useless doxygen warnings
2020-11-08 06:13:56 -08:00
Victor Zverovich
86bb7fe614
Add a missing import
2020-11-08 05:55:49 -08:00
Victor Zverovich
959a9f5cad
Merge branch 'master' of github.com:fmtlib/fmt
2020-11-08 05:50:48 -08:00
Victor Zverovich
4f7df299ea
Improve docs
2020-11-08 05:40:39 -08:00
Jonathan Gopel
b3ab0bc7e3
🎨 [CI] Specify the exact version of clang to use ( #1991 )
...
Problem:
- The version of clang to use is specified only as `clang++`. This is
inconsistent with the specifications for gcc and exposed to unexpected
failure if the default changes.
Solution:
- Specify the exact version of clang to use. I chose `clang++-9` as that
is the version that `clang++` is currently resolving to.
Co-authored-by: Jonathan Gopel <jgopel@quantlab.com>
2020-11-08 05:18:24 -08:00
Victor Zverovich
701ed6c874
Install deps in github actions instead of script
2020-11-07 11:16:38 -08:00
Victor Zverovich
8f2131cf2d
Document chrono
2020-11-07 10:51:08 -08:00
Victor Zverovich
32c4af8f0d
Document chrono
2020-11-07 10:38:51 -08:00
Victor Zverovich
295a60ec8d
Document chrono
2020-11-07 10:30:23 -08:00
Victor Zverovich
a4fae96c96
Document chrono
2020-11-07 10:24:27 -08:00
Victor Zverovich
263bb0e68d
Document chrono
2020-11-07 10:19:40 -08:00
Victor Zverovich
0506b328b5
Document chrono
2020-11-07 09:59:57 -08:00
Victor Zverovich
4e426c19d0
Document chrono
2020-11-07 09:47:56 -08:00
Victor Zverovich
9795d87348
Update docs
2020-11-07 09:27:06 -08:00
Victor Zverovich
2eb0be0b73
Remove debug code and fix bot contact
2020-11-07 09:16:55 -08:00
Victor Zverovich
cd95579834
Move less installation to actions
2020-11-07 09:12:54 -08:00
Victor Zverovich
98639d0f6f
Debug doc build
2020-11-07 09:04:07 -08:00
Victor Zverovich
ab5e0632fe
Debug doc build
2020-11-07 08:54:58 -08:00
Victor Zverovich
b123129f4e
Dump the content of html dir
2020-11-07 08:42:13 -08:00
Victor Zverovich
81d2b986af
Print less command
2020-11-07 08:24:58 -08:00
Victor Zverovich
7a0b1d5781
Add key
2020-11-07 08:09:01 -08:00
Victor Zverovich
9f0617cbfb
Fix branch ref
2020-11-07 08:04:01 -08:00
Victor Zverovich
75b07598fe
Chrono docs
2020-11-07 07:56:53 -08:00
Victor Zverovich
dfbb6975b3
Remove travis config
2020-11-07 07:38:20 -08:00
Victor Zverovich
5b3052f999
Switch doc build to github actions
2020-11-07 07:31:15 -08:00
Ashton Fagg
506ff320f2
Fix build failure when not using fcntl with -Werror ( #1990 )
2020-11-06 15:39:59 -08:00
Victor Zverovich
a30b279bad
Apply clang-format and tweak comments
2020-11-04 17:17:23 -08:00
Alexey Ochapov
6a2495c840
-Wattributes visibility warning with some GCC versions ( #1975 )
2020-11-04 17:11:31 -08:00
Victor Zverovich
cba5970cd8
Remove migrated build configs
2020-11-04 10:03:00 -08:00
Victor Zverovich
689081d832
Merge branch 'release' of github.com:fmtlib/fmt
2020-11-04 07:46:02 -08:00
Victor Zverovich
49544ea943
Fuzz fallback formatter
2020-11-03 19:34:35 -08:00
Victor Zverovich
6b7bfed40c
Fix fallback float formatter at assymetric bounds ( #1976 )
2020-11-03 19:19:10 -08:00
Victor Zverovich
bcab36da3f
Update CI config
2020-11-03 16:01:26 -08:00
Victor Zverovich
1689e73e90
Move PR template
2020-11-03 14:52:47 -08:00
Victor Zverovich
0103408a5c
Update CI config
2020-11-03 14:39:43 -08:00
Victor Zverovich
38a16ecba2
Move build config to github actions
2020-11-03 13:35:37 -08:00
Victor Zverovich
205eb3a8f2
Update CI config
2020-11-03 13:27:15 -08:00
Victor Zverovich
fe61b8c630
Update CI config
2020-11-03 11:59:59 -08:00
Victor Zverovich
867b15d77c
Update CI config
2020-11-03 11:48:20 -08:00
Victor Zverovich
98cb9f9931
Update CI config
2020-11-03 11:43:00 -08:00
Victor Zverovich
95077d60c9
Update CI config
2020-11-03 11:41:25 -08:00
Victor Zverovich
bc49f094e7
Update CI config
2020-11-03 11:02:49 -08:00
Victor Zverovich
cef6dfb422
Update CI config
2020-11-03 10:46:03 -08:00
Victor Zverovich
c8703ba40b
Update CI config
2020-11-03 10:45:16 -08:00
Victor Zverovich
ab4405bea5
Update README.rst
2020-11-03 10:42:06 -08:00
Victor Zverovich
78a55e2898
Update CI config
2020-11-03 10:37:30 -08:00
Victor Zverovich
d0a2494a99
Update cmake.yml
2020-11-03 10:17:38 -08:00
Victor Zverovich
89d009ba6e
Update cmake.yml
2020-11-03 10:14:38 -08:00
Victor Zverovich
1f4ff47b41
Create cmake.yml
2020-11-03 10:04:28 -08:00
Jonathan Gopel
eb52ac7a35
🆕 Enable -Wshadow in pedantic mode
...
Problem:
- All `-Wshadow` warnings are fixed but there is nothing stopping them
from being reintroduced.
Solution:
- Fail pedantic builds on `-Wshadow` warnings. This allows CI to prevent
reoccurrence of the warning.
Notes:
- Not enabling `-Wshadow` for gcc versions 4 or lower because the
warning is much more aggressive there to the point that it's mostly
just noise.
2020-11-03 07:30:27 -08:00
Jonathan Gopel
e904e891bd
🎨 🐛 Rename all shadowed types and variables
2020-11-03 07:30:27 -08:00
darklukee
771292c328
Remove sizeof from unused variable silencer ( #1974 )
...
Using sizeof causes some compilers to complain:
'operand of sizeof is not a type, variable, or dereferenced pointer'
static_cast itself should be enough to silence unused variable warning
Co-authored-by: Łukasz Mitka <lukasz.mitka@aptiv.com>
2020-11-03 06:48:19 -08:00
Victor Zverovich
86bf6045c6
Merge branch 'release' of github.com:fmtlib/fmt
2020-11-02 06:27:49 -08:00
Victor Zverovich
e50ced88c6
Add a macro to workaround clang/gcc ABI incompatibility on ARM
2020-10-31 07:52:08 -07:00
Victor Zverovich
112755cf91
Remove FMT_SAFEBUFFERS ( #1966 )
2020-10-29 17:42:45 -07:00
Victor Zverovich
4081b2fe94
Fix ABI compatibility ( #1961 )
2020-10-29 11:29:47 -07:00
Tobias Hammer
2d9311e860
Remove accidental parenthesis ( #1968 )
...
fails only when FMT_BUILTIN_CTZLL is not defined
2020-10-29 07:08:06 -07:00
Jonathan Gopel
b3a4f28ad1
Fix implicit signedness conversion warning ( #1963 )
...
Problem:
- On Apple clang 11.0.3 (clang-1103.0.32.62), pedantic mode compilation
generates the following error:
test/std-format-test.cc:114:22: error: implicit conversion changes
signedness: 'int' to 'size_t' (aka 'unsigned long')
[-Werror,-Wsign-conversion]
width_arg_id = c - '0';
~ ~~^~~~~
Solution:
- Use a `to_unsigned` to make the conversion explicit. This is
guaranteed to be safe due to the check before the ASCII-to-int
conversion.
2020-10-29 06:26:18 -07:00
Vladislav Shchapov
97c8873214
Allocator::max_size support in basic_memory_buffer ( #1960 )
2020-10-29 06:17:00 -07:00
OptoCloud
bb68f6089b
Removed [-Wsign-conversion] warning in GCC
2020-10-28 06:02:17 -07:00
kitegi
f4ca065cfb
Range support
2020-10-28 05:35:37 -07:00
Victor Zverovich
cb224ecaa3
Instantiate to_decimal to make gcc lto happy ( #1955 )
2020-10-27 07:46:40 -07:00
Victor Zverovich
7977c2b4d0
Cleanup
2020-10-27 07:19:28 -07:00
Владислав Щапов
e54eb67639
Workaround bugs in gcc 8
2020-10-27 06:11:31 -07:00