mirror of
https://github.com/apple/swift.git
synced 2026-06-20 15:42:51 +02:00
8713c13bef
For a given function, we might end up emitting it's definition as object code, serialized SIL, or both. The @export, @inlinable, and @inline(always) attributes provide control of this behavior at the declaration level. Centralize the query function that will look for each of these attributes and map down to a specific "code generation model", whose 3 options follow the naming from SE-0497: interface, inlinable, and implementation. Use this one computation to back the queries for "always emit into client", "never emit into client", and "inlinable" so we can't get inconsistent results from places that are doing one-off checks for these attributes.