Skip to content

Commit f76bfcc

Browse files
committed
Mention that the hint is redundant with polymorphic items
1 parent 90d0bf6 commit f76bfcc

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

content/inside-rust/call-for-testing-hint-mostly-unused.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -71,6 +71,10 @@ substantial swath of the API). Always do performance analysis when considering
7171
this hint, and only apply it if it applies obvious and substantial wins for
7272
your users.
7373

74+
If most of the items in your crate are polymorphic (generic), this hint may be
75+
redundant, as Rust already defers compilation of polymorphic items until they
76+
get monomorphized with specific types.
77+
7478
Also note that this only provides a performance win if you are rebuilding the
7579
dependency. If you're only rebuilding the top-level crate, this won't help.
7680

0 commit comments

Comments
 (0)