Skip to content

Conversation

@smundhra-git
Copy link

[libcxx] Replace _LIBCPP_HIDDEN with _LIBCPP_HIDE_FROM_ABI in char_traits::eq

This removes the TODO comment and makes the eq function consistent
with the lt function below it, which already uses _LIBCPP_HIDE_FROM_ABI.

@smundhra-git smundhra-git requested a review from a team as a code owner December 7, 2025 08:36
@github-actions
Copy link

github-actions bot commented Dec 7, 2025

Thank you for submitting a Pull Request (PR) to the LLVM Project!

This PR will be automatically labeled and the relevant teams will be notified.

If you wish to, you can add reviewers by using the "Reviewers" section on this page.

If this is not working for you, it is probably because you do not have write permissions for the repository. In which case you can instead tag reviewers by name in a comment by using @ followed by their GitHub username.

If you have received no comments on your PR for a week, you can request a review by "ping"ing the PR by adding a comment “Ping”. The common courtesy "ping" rate is once a week. Please remember that you are asking for valuable time from other developers.

If you have further questions, they may be answered by the LLVM GitHub User Guide.

You can also ask questions in a comment on this PR, on the LLVM Discord or on the forums.

@llvmbot llvmbot added the libc++ libc++ C++ Standard Library. Not GNU libstdc++. Not libc++abi. label Dec 7, 2025
@llvmbot
Copy link
Member

llvmbot commented Dec 7, 2025

@llvm/pr-subscribers-libcxx

Author: Shlok Mundhra (smundhra-git)

Changes

[libcxx] Replace _LIBCPP_HIDDEN with _LIBCPP_HIDE_FROM_ABI in char_traits::eq

This removes the TODO comment and makes the eq function consistent
with the lt function below it, which already uses _LIBCPP_HIDE_FROM_ABI.


Full diff: https://github.com/llvm/llvm-project/pull/171020.diff

1 Files Affected:

  • (modified) libcxx/include/__string/char_traits.h (+1-2)
diff --git a/libcxx/include/__string/char_traits.h b/libcxx/include/__string/char_traits.h
index 8292750919427..70b0f92639873 100644
--- a/libcxx/include/__string/char_traits.h
+++ b/libcxx/include/__string/char_traits.h
@@ -93,8 +93,7 @@ struct char_traits<char> {
     __c1 = __c2;
   }
 
-  // TODO: Make this _LIBCPP_HIDE_FROM_ABI
-  static inline _LIBCPP_HIDDEN _LIBCPP_CONSTEXPR bool eq(char_type __c1, char_type __c2) _NOEXCEPT {
+  static inline _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR bool eq(char_type __c1, char_type __c2) _NOEXCEPT {
     return __c1 == __c2;
   }
   static inline _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR bool lt(char_type __c1, char_type __c2) _NOEXCEPT {

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

libc++ libc++ C++ Standard Library. Not GNU libstdc++. Not libc++abi.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants