Fix doctest template

`saturating_add` example was not parameterized, but passed because the `u8` would saturate successfully
This commit is contained in:
Mihail Malo 2020-06-10 13:55:40 +03:00 committed by GitHub
parent bb8674837a
commit 5859f6e4f7
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -3309,7 +3309,8 @@ Basic usage:
``` ```
", $Feature, "assert_eq!(100", stringify!($SelfT), ".saturating_add(1), 101); ", $Feature, "assert_eq!(100", stringify!($SelfT), ".saturating_add(1), 101);
assert_eq!(200u8.saturating_add(127), 255);", $EndFeature, " assert_eq!((", stringify!($SelfT), "::MAX).saturating_add(127), ", stringify!($SelfT),
"::MAX);", $EndFeature, "
```"), ```"),
#[stable(feature = "rust1", since = "1.0.0")] #[stable(feature = "rust1", since = "1.0.0")]