This is an archive of the discontinued LLVM Phabricator instance.

[libc][NFC] Replace static inline and inline annotations with LIBC_INLINE.
ClosedPublic

Authored by sivachandra on Jan 19 2023, 12:45 PM.

Details

Summary

This is first of a few patches which will do similar mechanical changes.

LIBC_INLINE is a simple macro which is default defined as just inline.
The idea is that, different downstream contexts can define the macro as
suitable to their use case and context. For example, one can choose to
define LIBC_INLINE as [[clang::internal_linkage]] inline.

Diff Detail

Event Timeline

sivachandra created this revision.Jan 19 2023, 12:45 PM
Herald added projects: Restricted Project, Restricted Project. · View Herald TranscriptJan 19 2023, 12:45 PM
sivachandra requested review of this revision.Jan 19 2023, 12:45 PM

Fix incorrectly positioned LIBC_INLINE in a few places.

Remove an incorrect switch from static inline to LIBC_INLINE on a var decl.

lntue accepted this revision.Jan 19 2023, 5:53 PM
This revision is now accepted and ready to land.Jan 19 2023, 5:53 PM
abrachet added inline comments.
libc/src/__support/FPUtil/aarch64/FEnvImpl.h
54

I'm seeing build errors. I think these methods should have been kept static. WDYT?

sivachandra added inline comments.Jan 20 2023, 3:18 PM
libc/src/__support/FPUtil/aarch64/FEnvImpl.h
54

You are correct. The bot isn't showing them!! I will fix this ASAP.