mirror of
https://github.com/notohh/rustlings.git
synced 2024-11-24 14:37:32 -05:00
Fix capacity
This commit is contained in:
parent
766f3c50ec
commit
455d87cadd
1 changed files with 1 additions and 1 deletions
|
@ -172,7 +172,7 @@ pub trait RunnableExercise {
|
||||||
/// The output is written to the `output` buffer after clearing it.
|
/// The output is written to the `output` buffer after clearing it.
|
||||||
fn run_solution(&self, output: Option<&mut Vec<u8>>, target_dir: &Path) -> Result<bool> {
|
fn run_solution(&self, output: Option<&mut Vec<u8>>, target_dir: &Path) -> Result<bool> {
|
||||||
let name = self.name();
|
let name = self.name();
|
||||||
let mut bin_name = String::with_capacity(name.len());
|
let mut bin_name = String::with_capacity(name.len() + 4);
|
||||||
bin_name.push_str(name);
|
bin_name.push_str(name);
|
||||||
bin_name.push_str("_sol");
|
bin_name.push_str("_sol");
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue