Skip to content

Commit

Permalink
馃洜 Adjust encoding_name usage
Browse files Browse the repository at this point in the history
  • Loading branch information
ThePhD committed Nov 6, 2021
1 parent 283322a commit fb6c76b
Show file tree
Hide file tree
Showing 5 changed files with 8 additions and 8 deletions.
8 changes: 4 additions & 4 deletions include/ztd/text/basic_iconv.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,7 @@ namespace ztd { namespace text {
const ::std::size_t __initial_input_size = __initial_drain_size - __drain_size;
::std::size_t __input_size = __initial_input_size;
const ::std::size_t __clear_result = __base_t::_S_functions().__convert(
__desc, &__p_input, &__input_size, &__p_faux_drain, &__faux_drain_size);
__desc, &__p_input, &__input_size, &__p_faux_drain, &__faux_drain_size);
ZTD_TEXT_ASSERT(__clear_result == __txt_detail::__iconv::__conversion_success);
ZTD_TEXT_ASSERT(__input_size == 0);
}
Expand All @@ -127,7 +127,7 @@ namespace ztd { namespace text {
this->_M_reset_state(__desc);
constexpr ::std::size_t __max_input_size = 5;
// Are we going to a Unicode encoding?
if (!__idk_detail::__is_unicode_encoding_name(__to_name.base()) || __from_size > __max_input_size) {
if (!::ztd::is_unicode_encoding_name(__to_name.base()) || __from_size > __max_input_size) {
return true;
}
// Congratulations, welcome to the hell that is the GNU / libc implementation of iconv!
Expand Down Expand Up @@ -287,8 +287,8 @@ namespace ztd { namespace text {


bool contains_unicode_encoding() const noexcept {
return __idk_detail::__is_unicode_encoding_name(this->_M_from_name)
&& __idk_detail::__is_unicode_encoding_name(this->_M_to_name);
return ::ztd::is_unicode_encoding_name(this->_M_from_name)
&& ::ztd::is_unicode_encoding_name(this->_M_to_name);
}

//////
Expand Down
2 changes: 1 addition & 1 deletion include/ztd/text/detail/encoding_name.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@
#include <ztd/text/no_encoding.hpp>
#include <ztd/text/iconv_names.hpp>

#include <ztd/idk/detail/encoding_name.hpp>
#include <ztd/idk/encoding_name.hpp>
#include <ztd/idk/type_traits.hpp>

#include <string_view>
Expand Down
2 changes: 1 addition & 1 deletion include/ztd/text/detail/posix.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@

#include <ztd/text/version.hpp>

#include <ztd/idk/detail/encoding_name.hpp>
#include <ztd/idk/encoding_name.hpp>

#if ZTD_IS_ON(ZTD_PLATFORM_UNIX_I_) || ZTD_IS_ON(ZTD_PLATFORM_POSIX_I_)

Expand Down
2 changes: 1 addition & 1 deletion include/ztd/text/impl/execution_cuchar.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -215,7 +215,7 @@ namespace ztd { namespace text {
if (__index != ::std::string_view::npos) {
__adjusted_ctype_name = __adjusted_ctype_name.substr(__index);
}
return __idk_detail::__is_unicode_encoding_name(__adjusted_ctype_name);
return ::ztd::is_unicode_encoding_name(__adjusted_ctype_name);
#endif
}

Expand Down
2 changes: 1 addition & 1 deletion include/ztd/text/impl/wide_execution_cwchar.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -206,7 +206,7 @@ namespace ztd { namespace text {
if (__index != ::std::string_view::npos) {
__adjusted_ctype_name = __adjusted_ctype_name.substr(__index);
}
return __idk_detail::__is_unicode_encoding_name(__adjusted_ctype_name);
return ::ztd::is_unicode_encoding_name(__adjusted_ctype_name);
#else
return true;
#endif
Expand Down

0 comments on commit fb6c76b

Please sign in to comment.