[libc] Remove LIBC_HAS_ATTRIBUTE macro (#86656)

Resolves #86547

Replace occurrences of the macro `LIBC_HAS_ATTRIBUTE` with `__has_attribute`.

GitOrigin-RevId: a3f21a32495abeaddfa64a9789cd8c1b3fdad87c
2 files changed