title: Two dimensional vectors in Rust
body: <blockquote>
  <p>Editor's note: This question predates Rust <strong>0.1</strong> (tagged 2013-07-03) and is not syntactically valid Rust 1.0 code. Answers may still contain valuable information.</p>
  </blockquote>
  <p>Does anyone know how to create mutable two-dimensional vectors in Rust and pass them to a function to be manipulated?</p>
  <p>This is what I tried so far:</p>
  <pre><code>extern crate std;
  
  fn promeni(rec: &amp;[u8]) {
      rec[0][1] = 0x01u8;
  }
  
  fn main() {
      let mut rec = ~[[0x00u8,0x00u8],
          [0x00u8,0x00u8]
      ];
      io::println(u8::str(rec[0][1]));
      promeni(rec);
      io::println(u8::str(rec[0][1]));
  }
  </code></pre>