mirror of
https://github.com/apple/swift.git
synced 2025-12-21 12:14:44 +01:00
Rename some macros based on the PR review comments.
- use the SWIFT prefix for all macros - make names of some macros shorter
This commit is contained in:
@@ -2493,11 +2493,11 @@ swift_getResilientMetadata(GenericMetadata *pattern);
|
||||
/// metadata)
|
||||
/// return metadata
|
||||
/// }
|
||||
RT_ENTRY_VISIBILITY
|
||||
SWIFT_RT_ENTRY_VISIBILITY
|
||||
extern "C" const Metadata *
|
||||
swift_getGenericMetadata(GenericMetadata *pattern,
|
||||
const void *arguments)
|
||||
CALLING_CONVENTION(RegisterPreservingCC);
|
||||
SWIFT_CC(RegisterPreservingCC);
|
||||
|
||||
// Callback to allocate a generic class metadata object.
|
||||
SWIFT_RUNTIME_EXPORT
|
||||
@@ -2531,12 +2531,12 @@ swift_allocateGenericValueMetadata(GenericMetadata *pattern,
|
||||
/// never form part of the uniquing key for the conformance, which
|
||||
/// is ultimately a statement about the user model of overlapping
|
||||
/// conformances.
|
||||
RT_ENTRY_VISIBILITY
|
||||
SWIFT_RT_ENTRY_VISIBILITY
|
||||
extern "C" const WitnessTable *
|
||||
swift_getGenericWitnessTable(GenericWitnessTable *genericTable,
|
||||
const Metadata *type,
|
||||
void * const *instantiationArgs)
|
||||
CALLING_CONVENTION(RegisterPreservingCC);
|
||||
SWIFT_CC(RegisterPreservingCC);
|
||||
|
||||
/// \brief Fetch a uniqued metadata for a function type.
|
||||
SWIFT_RUNTIME_EXPORT
|
||||
@@ -2738,11 +2738,11 @@ swift_getExistentialMetatypeMetadata(const Metadata *instanceType);
|
||||
|
||||
/// \brief Fetch a uniqued metadata for an existential type. The array
|
||||
/// referenced by \c protocols will be sorted in-place.
|
||||
RT_ENTRY_VISIBILITY
|
||||
SWIFT_RT_ENTRY_VISIBILITY
|
||||
extern "C" const ExistentialTypeMetadata *
|
||||
swift_getExistentialTypeMetadata(size_t numProtocols,
|
||||
const ProtocolDescriptor **protocols)
|
||||
CALLING_CONVENTION(RegisterPreservingCC);
|
||||
SWIFT_CC(RegisterPreservingCC);
|
||||
|
||||
/// \brief Perform a checked dynamic cast of a value to a target type.
|
||||
///
|
||||
@@ -2760,13 +2760,13 @@ swift_getExistentialTypeMetadata(size_t numProtocols,
|
||||
///
|
||||
/// \return true if the cast succeeded. Depending on the flags,
|
||||
/// swift_dynamicCast may fail rather than return false.
|
||||
RT_ENTRY_VISIBILITY
|
||||
SWIFT_RT_ENTRY_VISIBILITY
|
||||
extern "C" bool
|
||||
swift_dynamicCast(OpaqueValue *dest, OpaqueValue *src,
|
||||
const Metadata *srcType,
|
||||
const Metadata *targetType,
|
||||
DynamicCastFlags flags)
|
||||
CALLING_CONVENTION(RegisterPreservingCC);
|
||||
SWIFT_CC(RegisterPreservingCC);
|
||||
|
||||
/// \brief Checked dynamic cast to a Swift class type.
|
||||
///
|
||||
@@ -2775,10 +2775,10 @@ swift_dynamicCast(OpaqueValue *dest, OpaqueValue *src,
|
||||
/// a Swift class type.
|
||||
///
|
||||
/// \returns the object if the cast succeeds, or null otherwise.
|
||||
RT_ENTRY_VISIBILITY
|
||||
SWIFT_RT_ENTRY_VISIBILITY
|
||||
extern "C" const void *
|
||||
swift_dynamicCastClass(const void *object, const ClassMetadata *targetType)
|
||||
CALLING_CONVENTION(RegisterPreservingCC);
|
||||
SWIFT_CC(RegisterPreservingCC);
|
||||
|
||||
/// \brief Unconditional, checked dynamic cast to a Swift class type.
|
||||
///
|
||||
|
||||
Reference in New Issue
Block a user