Skip to content

Commit 2ba4eb2

Browse files
committed
Auto merge of rust-lang#116208 - matthiaskrgr:the_loop_that_wasnt, r=GuillaumeGomez
rustdoc: while -> if we will always return once we step inside the while-loop thus `if` is sufficient here
2 parents b9dd2ce + 809ab64 commit 2ba4eb2

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/librustdoc/html/markdown.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1083,7 +1083,7 @@ impl<'a, 'tcx> TagIterator<'a, 'tcx> {
10831083
}
10841084

10851085
fn parse_in_attribute_block(&mut self) -> Option<LangStringToken<'a>> {
1086-
while let Some((pos, c)) = self.inner.next() {
1086+
if let Some((pos, c)) = self.inner.next() {
10871087
if c == '}' {
10881088
self.is_in_attribute_block = false;
10891089
return self.next();

0 commit comments

Comments
 (0)