Skip to content

Commit 015e477

Browse files
committed
Silence mismatched_lifetime_syntaxes lint
1 parent c63cfcc commit 015e477

File tree

4 files changed

+5
-5
lines changed

4 files changed

+5
-5
lines changed

src/abi/anchor.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -220,7 +220,7 @@ struct TypeManager<'a> {
220220
}
221221

222222
impl TypeManager<'_> {
223-
fn new(ns: &Namespace, contract_no: usize) -> TypeManager {
223+
fn new(ns: &Namespace, contract_no: usize) -> TypeManager<'_> {
224224
TypeManager {
225225
namespace: ns,
226226
added_types: HashSet::new(),

src/codegen/encoding/buffer_validator.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ pub(crate) struct BufferValidator<'a> {
2525
}
2626

2727
impl BufferValidator<'_> {
28-
pub fn new(buffer_size_var: usize, types: &[Type]) -> BufferValidator {
28+
pub fn new(buffer_size_var: usize, types: &[Type]) -> BufferValidator<'_> {
2929
BufferValidator {
3030
buffer_length: Expression::Variable {
3131
loc: Loc::Codegen,

src/codegen/subexpression_elimination/anticipated_expressions.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ impl<'a> AnticipatedExpressions<'a> {
4242
dag: &Vec<Vec<usize>>,
4343
reverse_dag: Vec<Vec<usize>>,
4444
traversing_order: Vec<(usize, bool)>,
45-
) -> AnticipatedExpressions {
45+
) -> AnticipatedExpressions<'_> {
4646
let mut depth: Vec<u16> = vec![u16::MAX; dag.len()];
4747
AnticipatedExpressions::blocks_depth(dag, 0, 0, &mut depth);
4848
AnticipatedExpressions {

src/sema/diagnostics.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,11 +27,11 @@ impl Diagnostics {
2727
self.contents.len()
2828
}
2929

30-
pub fn iter(&self) -> Iter<Diagnostic> {
30+
pub fn iter(&self) -> Iter<'_, Diagnostic> {
3131
self.contents.iter()
3232
}
3333

34-
pub fn iter_mut(&mut self) -> IterMut<Diagnostic> {
34+
pub fn iter_mut(&mut self) -> IterMut<'_, Diagnostic> {
3535
self.contents.iter_mut()
3636
}
3737

0 commit comments

Comments
 (0)