Mercurial > touhou
diff examples/stdrenderer.rs @ 752:5e5e7136ac92
examples: Return a Result for load_file_into_vec()
author | Emmanuel Gil Peyrot <linkmauve@linkmauve.fr> |
---|---|
date | Wed, 29 Jan 2020 17:45:25 +0100 |
parents | 0fed350d1778 |
children | a662dddd4a2b |
line wrap: on
line diff
--- a/examples/stdrenderer.rs +++ b/examples/stdrenderer.rs @@ -118,11 +118,11 @@ fn main() { let anm_filename = Path::new(&args[2]); // Open the STD file. - let buf = load_file_into_vec(std_filename); + let buf = load_file_into_vec(std_filename).unwrap(); let (_, stage) = Stage::from_slice(&buf).unwrap(); // Open the ANM file. - let buf = load_file_into_vec(anm_filename); + let buf = load_file_into_vec(anm_filename).unwrap(); let (_, mut anms) = Anm0::from_slice(&buf).unwrap(); let anm0 = anms.pop().unwrap();