Implementation of common traits for MaybeOwnedVector
auto merge of #15241 : arjantop/rust/maybeownedvector-improvements, r=alexcrichton