Skip to content

Commit

Permalink
clippy: Fix semicolon_if_nothing_returned lints
Browse files Browse the repository at this point in the history
  • Loading branch information
waywardmonkeys committed May 3, 2024
1 parent e320c7d commit f6020c6
Show file tree
Hide file tree
Showing 7 changed files with 12 additions and 12 deletions.
6 changes: 3 additions & 3 deletions fluent-bundle/benches/resolver.rs
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ fn resolver_bench(c: &mut Criterion) {
.add_resource(res.clone())
.expect("Couldn't add FluentResource to the FluentBundle");
add_functions(name, &mut bundle);
})
});
});
}
group.finish();
Expand All @@ -130,7 +130,7 @@ fn resolver_bench(c: &mut Criterion) {
}
assert!(errors.is_empty(), "Resolver errors: {:#?}", errors);
}
})
});
});
}
group.finish();
Expand All @@ -153,7 +153,7 @@ fn resolver_bench(c: &mut Criterion) {
}
assert!(errors.is_empty(), "Resolver errors: {:#?}", errors);
}
})
});
});
}
group.finish();
Expand Down
2 changes: 1 addition & 1 deletion fluent-fallback/src/cache.rs
Original file line number Diff line number Diff line change
Expand Up @@ -185,7 +185,7 @@ where
let pin = unsafe { Pin::new_unchecked(&self.stream) };
unsafe { PinMut::as_mut(&mut pin.borrow_mut()).get_unchecked_mut() }
.prefetch_async()
.await
.await;
}
}

Expand Down
2 changes: 1 addition & 1 deletion fluent-fallback/src/localization.rs
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@ where
{
pub async fn prefetch_async(&mut self) {
let bundles = self.bundles();
bundles.prefetch_async().await
bundles.prefetch_async().await;
}
}

Expand Down
2 changes: 1 addition & 1 deletion fluent-resmgr/src/resource_manager.rs
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,7 @@ impl ResourceManager {
Ok(resource) => {
if let Err(errs) = bundle.add_resource(resource) {
for error in errs {
errors.push(ResourceManagerError::Fluent(error))
errors.push(ResourceManagerError::Fluent(error));
}
}
}
Expand Down
2 changes: 1 addition & 1 deletion fluent-syntax/benches/parser.rs
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ fn parse_bench(c: &mut Criterion) {
for source in ctx {
parse_runtime(source.as_str()).expect("Parsing of the FTL failed.");
}
})
});
});
}

Expand Down
2 changes: 1 addition & 1 deletion fluent-syntax/src/parser/pattern.rs
Original file line number Diff line number Diff line change
Expand Up @@ -193,7 +193,7 @@ where
}
_ => {
text_element_type = TextElementType::NonBlank;
self.ptr += 1
self.ptr += 1;
}
}
}
Expand Down
8 changes: 4 additions & 4 deletions fluent-syntax/src/serializer.rs
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ impl Serializer {
Entry::ResourceComment(comment) => self.serialize_free_comment(comment, "###"),
Entry::Junk { content } => {
if self.options.with_junk {
self.serialize_junk(content.as_ref())
self.serialize_junk(content.as_ref());
}
}
};
Expand All @@ -103,7 +103,7 @@ impl Serializer {
}

fn serialize_junk(&mut self, junk: &str) {
self.writer.write_literal(junk)
self.writer.write_literal(junk);
}

fn serialize_free_comment<'s, S: Slice<'s>>(&mut self, comment: &Comment<S>, prefix: &str) {
Expand Down Expand Up @@ -232,7 +232,7 @@ impl Serializer {
match expr {
Expression::Inline(inline) => self.serialize_inline_expression(inline),
Expression::Select { selector, variants } => {
self.serialize_select_expression(selector, variants)
self.serialize_select_expression(selector, variants);
}
}
}
Expand Down Expand Up @@ -320,7 +320,7 @@ impl Serializer {
fn serialize_variant_key<'s, S: Slice<'s>>(&mut self, key: &VariantKey<S>) {
match key {
VariantKey::NumberLiteral { value } | VariantKey::Identifier { name: value } => {
self.writer.write_literal(value.as_ref())
self.writer.write_literal(value.as_ref());
}
}
}
Expand Down

0 comments on commit f6020c6

Please sign in to comment.