|
1 | 1 | #pragma once
|
2 | 2 |
|
3 | 3 | #include "fly/fly.hpp"
|
| 4 | +#include "fly/traits/concepts.hpp" |
4 | 5 | #include "fly/types/string/detail/classifier.hpp"
|
5 | 6 | #include "fly/types/string/detail/format_specifier.hpp"
|
6 | 7 | #include "fly/types/string/detail/stream_util.hpp"
|
|
11 | 12 | #include <array>
|
12 | 13 | #include <charconv>
|
13 | 14 | #include <cmath>
|
14 |
| -#include <concepts> |
15 | 15 | #include <iomanip>
|
16 | 16 | #include <limits>
|
17 | 17 | #include <sstream>
|
@@ -127,7 +127,7 @@ struct Formatter<T, CharType> : public detail::BasicFormatSpecifier<CharType>
|
127 | 127 | view = view_like_type(value).substr(0, value_size);
|
128 | 128 | }
|
129 | 129 |
|
130 |
| - if constexpr (std::same_as<string_type, string_like_type>) |
| 130 | + if constexpr (fly::SameAs<string_type, string_like_type>) |
131 | 131 | {
|
132 | 132 | for (const auto &ch : view)
|
133 | 133 | {
|
@@ -448,7 +448,7 @@ struct Formatter<T, CharType> : public detail::BasicFormatSpecifier<CharType>
|
448 | 448 | }
|
449 | 449 | }
|
450 | 450 |
|
451 |
| - if constexpr (std::same_as<string_type, std::string>) |
| 451 | + if constexpr (fly::SameAs<string_type, std::string>) |
452 | 452 | {
|
453 | 453 | for (const char *it = begin; it != result.ptr; ++it)
|
454 | 454 | {
|
@@ -564,7 +564,7 @@ struct Formatter<T, CharType> : public detail::BasicFormatSpecifier<CharType>
|
564 | 564 |
|
565 | 565 | auto append_number = [this, &context, &result]()
|
566 | 566 | {
|
567 |
| - if constexpr (std::same_as<string_type, std::string>) |
| 567 | + if constexpr (fly::SameAs<string_type, std::string>) |
568 | 568 | {
|
569 | 569 | for (auto ch : result.m_digits)
|
570 | 570 | {
|
|
0 commit comments