mirror of
https://github.com/fmtlib/fmt.git
synced 2025-11-27 04:39:44 +01:00
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
This commit is contained in:
@@ -402,8 +402,8 @@ struct formatter<
|
||||
auto out = ctx.out();
|
||||
*out++ = prefix;
|
||||
int i = 0;
|
||||
auto it = std::begin(range);
|
||||
auto end = std::end(range);
|
||||
auto it = detail::range_begin(range);
|
||||
auto end = detail::range_end(range);
|
||||
for (; it != end; ++it) {
|
||||
if (i > 0) out = detail::write_delimiter(out);
|
||||
if (custom_specs_) {
|
||||
|
||||
Reference in New Issue
Block a user