diff options
| author | athulappadan <a4athulappadan@gmail.com> | 2016-09-11 22:58:01 +0530 |
|---|---|---|
| committer | athulappadan <a4athulappadan@gmail.com> | 2016-09-11 22:58:01 +0530 |
| commit | 41881e85bd832127f2a6eee5821eaae353dea281 (patch) | |
| tree | 730da8b3d9bd50eec2c578ae76e9eca931942bb5 /src/libstd | |
| parent | 49e77dbf25ed6526fb5d37c32e55797fb04522f0 (diff) | |
| download | rust-41881e85bd832127f2a6eee5821eaae353dea281.tar.gz rust-41881e85bd832127f2a6eee5821eaae353dea281.zip | |
Documentation for default types modified
Diffstat (limited to 'src/libstd')
| -rw-r--r-- | src/libstd/collections/hash/map.rs | 2 | ||||
| -rw-r--r-- | src/libstd/collections/hash/set.rs | 2 | ||||
| -rw-r--r-- | src/libstd/ffi/c_str.rs | 2 |
3 files changed, 3 insertions, 3 deletions
diff --git a/src/libstd/collections/hash/map.rs b/src/libstd/collections/hash/map.rs index 48c54c16ed8..eb1653f18cb 100644 --- a/src/libstd/collections/hash/map.rs +++ b/src/libstd/collections/hash/map.rs @@ -1218,7 +1218,7 @@ impl<K, V, S> Default for HashMap<K, V, S> where K: Eq + Hash, S: BuildHasher + Default, { - /// Creates a `HashMap<K, V, S>`, with initial `Default` hasher. + /// Creates an empty `HashMap<K, V, S>`, with the `Default` value for the hasher. fn default() -> HashMap<K, V, S> { HashMap::with_hasher(Default::default()) } diff --git a/src/libstd/collections/hash/set.rs b/src/libstd/collections/hash/set.rs index b5652bcabf1..ff56747fee6 100644 --- a/src/libstd/collections/hash/set.rs +++ b/src/libstd/collections/hash/set.rs @@ -665,7 +665,7 @@ impl<T, S> Default for HashSet<T, S> where T: Eq + Hash, S: BuildHasher + Default, { - /// Creates a `HashSet<T, S>` with initial `Default` hasher. + /// Creates an empty `HashSet<T, S>` with the `Default` value for the hasher. fn default() -> HashSet<T, S> { HashSet::with_hasher(Default::default()) } diff --git a/src/libstd/ffi/c_str.rs b/src/libstd/ffi/c_str.rs index 044112ea136..0f7dc3889f0 100644 --- a/src/libstd/ffi/c_str.rs +++ b/src/libstd/ffi/c_str.rs @@ -339,7 +339,7 @@ impl<'a> Default for &'a CStr { #[stable(feature = "cstr_default", since = "1.10.0")] impl Default for CString { - /// Creates a new `CString`, by calling the `Default` of `CStr`, and then owns it. + /// Creates an empty `CString`. fn default() -> CString { let a: &CStr = Default::default(); a.to_owned() |
