File tree Expand file tree Collapse file tree 2 files changed +42
-0
lines changed Expand file tree Collapse file tree 2 files changed +42
-0
lines changed Original file line number Diff line number Diff line change 51
51
@end
52
52
53
53
54
+ // Don't conform to the protocol; that loads all protocol members.
55
+ @interface SimpleDoer (Category )
56
+ - (void )categoricallyDoSomeWork ;
57
+ - (void )categoricallyDoSomeWorkWithSpeed : (int )s ;
58
+ - (void )categoricallyDoSomeWorkWithSpeed : (int )s thoroughness : (int )t
59
+ NS_SWIFT_NAME(categoricallyDoVeryImportantWork(speed:thoroughness:));
60
+ - (void )categoricallyDoSomeWorkWithSpeed : (int )s alacrity : (int )a
61
+ NS_SWIFT_NAME(categoricallyDoSomeWorkWithSpeed(speed:levelOfAlacrity:));
62
+
63
+ // These we are generally trying to not-import, via laziness.
64
+ - (void )categoricallyGoForWalk ;
65
+ - (void )categoricallyTakeNap ;
66
+ - (void )categoricallyEatMeal ;
67
+ - (void )categoricallyTidyHome ;
68
+ - (void )categoricallyCallFamily ;
69
+ - (void )categoricallySingSong ;
70
+ - (void )categoricallyReadBook ;
71
+ - (void )categoricallyAttendLecture ;
72
+ - (void )categoricallyWriteLetter ;
73
+ @end
74
+
75
+
54
76
@protocol MirroredBase
55
77
+ (void )mirroredBaseClassMethod ;
56
78
- (void )mirroredBaseInstanceMethod ;
Original file line number Diff line number Diff line change
1
+ // REQUIRES: objc_interop
2
+ // REQUIRES: OS=macosx
3
+ // RUN: rm -rf %t && mkdir -p %t/stats-pre && mkdir -p %t/stats-post
4
+ //
5
+ // Prime module cache
6
+ // RUN: %target-swift-frontend -typecheck -I %S/Inputs/NamedLazyMembers -typecheck %s
7
+ //
8
+ // Check that named-lazy-member-loading reduces the number of Decls deserialized
9
+ // RUN: %target-swift-frontend -typecheck -I %S/Inputs/NamedLazyMembers -disable-named-lazy-member-loading -stats-output-dir %t/stats-pre %s
10
+ // RUN: %target-swift-frontend -typecheck -I %S/Inputs/NamedLazyMembers -stats-output-dir %t/stats-post %s
11
+ // RUN: %utils/process-stats-dir.py --evaluate-delta 'NumTotalClangImportedEntities < -10' %t/stats-pre %t/stats-post
12
+
13
+ import NamedLazyMembers
14
+
15
+ public func foo( d: SimpleDoer ) {
16
+ let _ = d. categoricallyDoSomeWork ( )
17
+ let _ = d. categoricallyDoSomeWork ( withSpeed: 10 )
18
+ let _ = d. categoricallyDoVeryImportantWork ( speed: 10 , thoroughness: 12 )
19
+ let _ = d. categoricallyDoSomeWorkWithSpeed ( speed: 10 , levelOfAlacrity: 12 )
20
+ }
You can’t perform that action at this time.
0 commit comments