Rollup merge of #90742 - est31:add_assign, r=davidtwco
Use AddAssign impl
This commit is contained in:
commit
0a9c1be100
2 changed files with 2 additions and 2 deletions
|
@ -169,7 +169,7 @@ pub fn gather_comments(sm: &SourceMap, path: FileName, src: String) -> Vec<Comme
|
|||
if let Some(mut idx) = token_text.find('\n') {
|
||||
code_to_the_left = false;
|
||||
while let Some(next_newline) = &token_text[idx + 1..].find('\n') {
|
||||
idx = idx + 1 + next_newline;
|
||||
idx += 1 + next_newline;
|
||||
comments.push(Comment {
|
||||
style: CommentStyle::BlankLine,
|
||||
lines: vec![],
|
||||
|
|
|
@ -34,7 +34,7 @@ where
|
|||
let rv = f();
|
||||
let duration = start.elapsed();
|
||||
let mut accu = accu.lock();
|
||||
*accu = *accu + duration;
|
||||
*accu += duration;
|
||||
rv
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue