DOC: Add docs for default values

This commit is contained in:
bluss
2017-10-16 22:45:27 +02:00
parent 9156256501
commit ace20a9f43
2 changed files with 2 additions and 0 deletions
+1
View File
@@ -31,6 +31,7 @@ pub struct ArrayString<A: Array<Item=u8>> {
} }
impl<A: Array<Item=u8>> Default for ArrayString<A> { impl<A: Array<Item=u8>> Default for ArrayString<A> {
/// Return an empty `ArrayString`
fn default() -> ArrayString<A> { fn default() -> ArrayString<A> {
ArrayString::new() ArrayString::new()
} }
+1
View File
@@ -942,6 +942,7 @@ impl<A: Array> fmt::Debug for ArrayVec<A> where A::Item: fmt::Debug {
} }
impl<A: Array> Default for ArrayVec<A> { impl<A: Array> Default for ArrayVec<A> {
/// Return an empty array
fn default() -> ArrayVec<A> { fn default() -> ArrayVec<A> {
ArrayVec::new() ArrayVec::new()
} }