mirror of
https://github.com/apple/swift.git
synced 2025-12-14 20:36:38 +01:00
Final tweaks from review comments.
This commit is contained in:
@@ -916,8 +916,8 @@ private:
|
||||
assert(Range.getByteLength() > 1);
|
||||
if (Range.str().front() == '`') {
|
||||
assert(Range.getByteLength() > 3);
|
||||
assert(Range.str().consume_front("`_") ||
|
||||
Range.str().consume_front("`$"));
|
||||
assert(Range.str().starts_with("`_") ||
|
||||
Range.str().starts_with("`$"));
|
||||
auto AfterBacktick = Loc.getAdvancedLoc(2);
|
||||
reportRef(Wrapped, AfterBacktick, Info, std::nullopt);
|
||||
} else {
|
||||
|
||||
@@ -6,7 +6,7 @@ struct `Struct With Spaces` {}
|
||||
|
||||
func test01() {
|
||||
#^GLOBAL_NAME^#
|
||||
// GLOBAL_NAME: Decl[FreeFunction]/CurrModule: `func with spaces`()[#Void#]; name=`func with spaces`()
|
||||
// GLOBAL_NAME-DAG: Decl[FreeFunction]/CurrModule: `func with spaces`()[#Void#]; name=`func with spaces`()
|
||||
// GLOBAL_NAME-DAG: Decl[TypeAlias]/CurrModule: `Space Alias`[#`Struct With Spaces`#]; name=`Space Alias`
|
||||
// GLOBAL_NAME-DAG: Decl[Struct]/CurrModule: `Struct With Spaces`[#`Struct With Spaces`#]; name=`Struct With Spaces`
|
||||
}
|
||||
@@ -19,14 +19,14 @@ struct S {
|
||||
|
||||
func test02(_ x: S) {
|
||||
x.#^MEMBER_NAME^#
|
||||
// MEMBER_NAME: Decl[InstanceVar]/CurrNominal: `name with spaces :)`[#Int#]; name=`name with spaces :)`
|
||||
// MEMBER_NAME-DAG: Decl[InstanceVar]/CurrNominal: `name with spaces :)`[#Int#]; name=`name with spaces :)`
|
||||
// MEMBER_NAME-DAG: Decl[InstanceMethod]/CurrNominal: `some.method`({#`argument label!`: Int#})[#Void#]; name=`some.method`(`argument label!`:)
|
||||
// MEMBER_NAME-DAG: Decl[InstanceMethod]/CurrNominal: f({#x: `Struct With Spaces`#})[#Void#]; name=f(x:)
|
||||
}
|
||||
|
||||
struct S2<`Generic Param`> {
|
||||
var x: #^TYPE_NAME^#
|
||||
// TYPE_NAME: Decl[GenericTypeParam]/Local: `Generic Param`[#Generic Param#]; name=`Generic Param`
|
||||
// TYPE_NAME-DAG: Decl[GenericTypeParam]/Local: `Generic Param`[#Generic Param#]; name=`Generic Param`
|
||||
// TYPE_NAME-DAG: Keyword[Self]/CurrNominal: Self[#S2<Generic Param>#]; name=Self
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user