# 1.0.0[−][src]Function std::slice::from_raw_parts_mut

ⓘImportant traits for &'a [u8]

### Important traits for &'a [u8]

`impl<'a> Read for &'a [u8]impl<'a> Write for &'a mut [u8]`

    pub unsafe fn from_raw_parts_mut<'a, T>(data: *mut T, len: usize) -> &'a mut [T]

Performs the same functionality as `from_raw_parts`, except that a mutable slice is returned.

This function is unsafe for the same reasons as `from_raw_parts`, as well as not being able to provide a non-aliasing guarantee of the returned mutable slice. `data` must be non-null and aligned even for zero-length slices as with `from_raw_parts`. The total size of the slice must be no larger than `isize::MAX` bytes in memory.

See the documentation of `from_raw_parts` for more details.

# Help

## Keyboard Shortcuts

`?`
  Show this help dialog
`S`
  Focus the search field
`↑`
  Move up in search results
`↓`
  Move down in search results
`↹`
  Switch tab
`⏎`
  Go to active search result
`+`
  Expand all sections
`-`
  Collapse all sections

## Search Tricks

Prefix searches with a type followed by a colon (e.g., `fn:`) to restrict the search to a given type.

Accepted types are: `fn`, `mod`, `struct`, `enum`, `trait`, `type`, `macro`, and `const`.

Search functions by type signature (e.g., `vec -> usize` or `* -> vec`)

Search multiple things at once by splitting your query with comma (e.g., `str,u8` or `String,struct:Vec,test`)