Last active
August 29, 2015 13:57
-
-
Save quux00/9435269 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
use std::str::StrVector; | |
struct A<'a> { | |
field: &'a StrVector | |
} | |
fn main() { | |
let vs = ~[~"one", ~"two", ~"three"]; | |
let cc = vs.concat(); | |
println!("{:?}", cc); // works | |
let a = A{field: & &vs}; // error: failed to find an implementation of | |
// trait std::str::StrVector for &~[~str] | |
println!("{:?}", a); | |
} | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment