mirror of
https://github.com/apple/swift.git
synced 2025-12-21 12:14:44 +01:00
Add __FUNCTION__ as a magic literal identifier.
Add __FUNCTION__ to the repertoire of magic source-location-identifying tokens. Inside a function, it gives the function name; inside a property accessor, it gives the property name; inside special members like 'init', 'subscript', and 'deinit', it gives the keyword name, and at top level, it gives the module name. As a bit of future-proofing, stringify the full DeclName, even though we only ever give declarations simple names currently. Swift SVN r14710
This commit is contained in:
@@ -449,6 +449,8 @@ static uint8_t getRawStableDefaultArgumentKind(swift::DefaultArgumentKind kind)
|
||||
return serialization::DefaultArgumentKind::File;
|
||||
case swift::DefaultArgumentKind::Line:
|
||||
return serialization::DefaultArgumentKind::Line;
|
||||
case swift::DefaultArgumentKind::Function:
|
||||
return serialization::DefaultArgumentKind::Function;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user