Skip to content

Vec should implement From<&mut [T]> #41386

Closed
@adamcrume

Description

@adamcrume

Vec already has:

impl<'a, T> From<&'a [T]> for Vec<T> where T: Clone

but it should also have:

impl<'a, T> From<&'a mut [T]> for Vec<T> where T: Clone

A workaround is to use Vec::from(my_mut_ref as &[T]).

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions