doc: Vec::from_raw_parts.

Also more explicit raw pointer handling in unsafe examples.
doc: Normalize example style

Remove unnecessary `use std::vec::Vec`. Use ``` code blocks
with rust as default instead of spelling it out.