Skip to content

Instantly share code, notes, and snippets.

@shiver
shiver / builder.rs
Created May 24, 2017 00:55
Rust Builder Pattern
#[derive(Debug)]
struct Builder<'a> {
args: Vec<&'a str>
}
impl<'a> Builder<'a> {
fn new() -> Builder<'a> {
Builder {
args: Vec::new()
}

Keybase proof

I hereby claim:

  • I am shiver on github.
  • I am rvally (https://keybase.io/rvally) on keybase.
  • I have a public key whose fingerprint is 08E6 D314 19F7 5BBB 1A11 DFBD F12C 5CDF 9C66 025F

To claim this, I am signing this object: