Eliminate redundant uses of format!.
https://github.com/rust-lang-nursery/rust-clippy/wiki#useless_format
This commit is contained in:
@@ -254,7 +254,7 @@ pub fn translate_module(
|
||||
.collect()
|
||||
}
|
||||
ParserState::EndSection => break,
|
||||
_ => return Err(String::from(format!("wrong content in code section"))),
|
||||
_ => return Err(String::from("wrong content in code section")),
|
||||
};
|
||||
let signature = signatures[functions[function_index as usize] as usize].clone();
|
||||
match translate_function_body(
|
||||
|
||||
@@ -283,7 +283,7 @@ pub fn parse_data_section(
|
||||
};
|
||||
match runtime.declare_data_initialization(memory_index as MemoryIndex, offset, data) {
|
||||
Ok(()) => (),
|
||||
Err(s) => return Err(SectionParsingError::WrongSectionContent(format!("{}", s))),
|
||||
Err(s) => return Err(SectionParsingError::WrongSectionContent(s)),
|
||||
};
|
||||
}
|
||||
match *parser.read() {
|
||||
|
||||
Reference in New Issue
Block a user