diff options
| author | Pietro Albini <pietro@pietroalbini.org> | 2018-10-25 14:31:21 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2018-10-25 14:31:21 +0200 |
| commit | 401ee42893073af79f72482831ad1b43cea4dd0a (patch) | |
| tree | 8f0200fb37abd95525cfa1f0319f5d467fb85ccc /src/libstd | |
| parent | b3e57dbdf62f13ef49f54315e353f2f9ed4df66e (diff) | |
| parent | 538f65eb617f5d4596cf0d263e48998a70137ce1 (diff) | |
| download | rust-401ee42893073af79f72482831ad1b43cea4dd0a.tar.gz rust-401ee42893073af79f72482831ad1b43cea4dd0a.zip | |
Rollup merge of #55328 - raphlinus:copysign_typo, r=joshtriplett
Fix doc for new copysign functions Thanks to @LukasKalbertodt for catching this. Addresses a comment raised in #55169 after it was merged.
Diffstat (limited to 'src/libstd')
| -rw-r--r-- | src/libstd/f32.rs | 8 | ||||
| -rw-r--r-- | src/libstd/f64.rs | 8 |
2 files changed, 8 insertions, 8 deletions
diff --git a/src/libstd/f32.rs b/src/libstd/f32.rs index c3f225d1eb0..7d17aaf2f26 100644 --- a/src/libstd/f32.rs +++ b/src/libstd/f32.rs @@ -198,12 +198,12 @@ impl f32 { } } - /// Returns a number composed of the magnitude of one number and the sign of - /// another. + /// Returns a number composed of the magnitude of `self` and the sign of + /// `y`. /// /// Equal to `self` if the sign of `self` and `y` are the same, otherwise - /// equal to `-y`. If `self` is a `NAN`, then a `NAN` with the sign of `y` - /// is returned. + /// equal to `-self`. If `self` is a `NAN`, then a `NAN` with the sign of + /// `y` is returned. /// /// # Examples /// diff --git a/src/libstd/f64.rs b/src/libstd/f64.rs index da062dda77a..ecaaf8323ab 100644 --- a/src/libstd/f64.rs +++ b/src/libstd/f64.rs @@ -176,12 +176,12 @@ impl f64 { } } - /// Returns a number composed of the magnitude of one number and the sign of - /// another. + /// Returns a number composed of the magnitude of `self` and the sign of + /// `y`. /// /// Equal to `self` if the sign of `self` and `y` are the same, otherwise - /// equal to `-y`. If `self` is a `NAN`, then a `NAN` with the sign of `y` - /// is returned. + /// equal to `-self`. If `self` is a `NAN`, then a `NAN` with the sign of + /// `y` is returned. /// /// # Examples /// |
