Skip to content

Commit 80dcad9

Browse files
authored
Be more specific about polymorphic return types
I no longer say "polymorphic" since it's a bit ambiguous here.
1 parent 26eab6a commit 80dcad9

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

library/std/src/primitive_docs.rs

+4-4
Original file line numberDiff line numberDiff line change
@@ -220,10 +220,10 @@ mod prim_bool {}
220220
/// }
221221
/// ```
222222
///
223-
/// The reason is that, in the first example, there are many possible types for `!` to coerce
224-
/// to, because the function's return value is polymorphic. However, in the second example, the
225-
/// other branch returns a `0` of type `u32`, which is a concrete type that `!` can be coerced to.
226-
/// See issue [#36375] for more information on this quirk of `!`.
223+
/// The reason is that, in the first example, there are many possible types that `!` could coerce
224+
/// to, because the function can return one of many concrete types. However, in the second example,
225+
/// the other branch returns a `0` of type `u32`, which is a concrete type that `!` can be coerced
226+
/// to. See issue [#36375] for more information on this quirk of `!`.
227227
///
228228
/// [#36375]: https://github.com/rust-lang/rust/issues/36375
229229
///

0 commit comments

Comments
 (0)