Trim dedented sections for arg detection (#793)

This commit is contained in:
Charlie Marsh 2022-11-17 12:55:55 -05:00 committed by GitHub
parent aafddae644
commit 6602f7f489
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 4 additions and 1 deletions

View File

@ -1359,7 +1359,10 @@ static GOOGLE_ARGS_REGEX: Lazy<Regex> =
fn args_section(checker: &mut Checker, definition: &Definition, context: &SectionContext) {
let mut args_sections: Vec<String> = vec![];
for line in textwrap::dedent(&context.following_lines.join("\n")).lines() {
for line in textwrap::dedent(&context.following_lines.join("\n"))
.trim()
.lines()
{
if line
.chars()
.next()