File tree Expand file tree Collapse file tree 3 files changed +6
-1
lines changed Expand file tree Collapse file tree 3 files changed +6
-1
lines changed Original file line number Diff line number Diff line change @@ -2319,7 +2319,7 @@ auto ClangImporter::Implementation::importFullName(
2319
2319
2320
2320
// Omit needless words.
2321
2321
StringScratchSpace omitNeedlessWordsScratch;
2322
- if (OmitNeedlessWords) {
2322
+ if (OmitNeedlessWords && !result. IsSubscriptAccessor ) {
2323
2323
// Check whether the module in which the declaration resides has a
2324
2324
// module prefix. If so, strip that prefix off when present.
2325
2325
if (D->getDeclContext ()->getRedeclContext ()->isFileContext () &&
Original file line number Diff line number Diff line change 15
15
-(nullable Class )typeOfNamedString : (nonnull NSString *)string ;
16
16
-(nullable Class )typeOfTypeNamed : (nonnull NSString *)string ;
17
17
-(void )appendWithContentsOfString : (nonnull NSString *)string ;
18
+ -(nonnull id )objectAtIndexedSubscript : (NSUInteger )idx ;
18
19
@end
Original file line number Diff line number Diff line change 287
287
// Look for preposition prior to "of".
288
288
// CHECK-OMIT-NEEDLESS-WORDS: func append(contentsOf _: String)
289
289
290
+ // Leave subscripts alone
291
+ // CHECK-OMIT-NEEDLESS-WORDS: subscript (_: UInt) -> AnyObject { get }
292
+ // CHECK-OMIT-NEEDLESS-WORDS: func objectAtIndexedSubscript(_: UInt) -> AnyObject
293
+
290
294
// Don't drop the 'error'.
291
295
// CHECK-ERRORS: func tryAndReturnError(_: ()) throws
You can’t perform that action at this time.
0 commit comments