matthew-j-code wrote:

> How does this interact with libc++, and non-Linux targets?

The '*' is emitted for both libc++ and libstdc++, but no comparison method for 
libc++ is effected by including '*'. Libc++ has 3 implemented methods for 
comparison of typeinfo name, the default for internal-linkage types is pointer 
only comparison, which differs from libstdc++ strcmp (which is where the error 
stems from). 

libcxx/include/typeinfo : (EFL default)
``` 
_LIBCPP_HIDE_FROM_ABI _LIBCPP_ALWAYS_INLINE static bool __eq(__type_name_t 
__lhs, __type_name_t __rhs) _NOEXCEPT {
    return __lhs == __rhs;
  }
 ```
 
 libcxx/include/typeinfo : (COFF default)
 ```
  _LIBCPP_HIDE_FROM_ABI _LIBCPP_ALWAYS_INLINE static bool __eq(__type_name_t 
__lhs, __type_name_t __rhs) _NOEXCEPT {
    return __lhs == __rhs || __builtin_strcmp(__lhs, __rhs) == 0;
  }
  ```
 

https://github.com/llvm/llvm-project/pull/220864
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to