diff --git a/src/extract_doc.rs b/src/extract_doc.rs index 5b75c47..d92ceac 100644 --- a/src/extract_doc.rs +++ b/src/extract_doc.rs @@ -55,13 +55,13 @@ pub fn extract_doc_from_source_str(source: &str) -> Result, ExtractD str.chars().all(char::is_whitespace) } - let x = string + let comment_lines = string .lines() .enumerate() .filter(|(i, l)| !(*i == 0 && empty_line(l))) - .map(|(_, l)| l); + .map(|(_, l)| l.to_owned()); - lines.extend(x.map(ToOwned::to_owned)); + lines.extend(comment_lines); } } } diff --git a/tools/codecov.sh b/tools/codecov.sh index 615cd55..f9586ab 100755 --- a/tools/codecov.sh +++ b/tools/codecov.sh @@ -36,7 +36,7 @@ done # TODO it seems the `--force-clean` is not working. cargo clean -cargo tarpaulin --force-clean --ignore-panics --engine llvm --timeout 1200 --out $output_format +cargo tarpaulin --force-clean --ignore-panics --engine llvm --timeout 1200 --out $output_format --all-features if [ "$output_format" == "html" ]; then echo