mirror of
https://github.com/ProvableHQ/leo.git
synced 2024-11-23 15:15:47 +03:00
clippy
This commit is contained in:
parent
936a35ebd2
commit
dc91b07e5c
@ -213,7 +213,7 @@ impl<'a> FromAst<'a, leo_ast::AssignStatement> for &'a Statement<'a> {
|
||||
let statement = scope.context.alloc_statement(Statement::Assign(AssignStatement {
|
||||
parent: Cell::new(None),
|
||||
span: Some(statement.span.clone()),
|
||||
operation: statement.operation.clone(),
|
||||
operation: statement.operation,
|
||||
target_variable: Cell::new(variable),
|
||||
target_accesses,
|
||||
value: Cell::new(value),
|
||||
@ -231,7 +231,7 @@ impl<'a> FromAst<'a, leo_ast::AssignStatement> for &'a Statement<'a> {
|
||||
impl<'a> Into<leo_ast::AssignStatement> for &AssignStatement<'a> {
|
||||
fn into(self) -> leo_ast::AssignStatement {
|
||||
leo_ast::AssignStatement {
|
||||
operation: self.operation.clone(),
|
||||
operation: self.operation,
|
||||
assignee: leo_ast::Assignee {
|
||||
identifier: self.target_variable.get().borrow().name.clone(),
|
||||
accesses: self
|
||||
|
@ -347,7 +347,7 @@ impl Canonicalizer {
|
||||
Statement::Assign(AssignStatement {
|
||||
assignee,
|
||||
value,
|
||||
operation: assign.operation.clone(),
|
||||
operation: assign.operation,
|
||||
span: assign.span.clone(),
|
||||
})
|
||||
}
|
||||
|
@ -325,7 +325,7 @@ pub trait ReconstructingReducer {
|
||||
value: Expression,
|
||||
) -> Result<AssignStatement, ReducerError> {
|
||||
Ok(AssignStatement {
|
||||
operation: assign.operation.clone(),
|
||||
operation: assign.operation,
|
||||
assignee,
|
||||
value,
|
||||
span: assign.span.clone(),
|
||||
|
@ -65,7 +65,7 @@ impl<'a, F: PrimeField, G: GroupType<F>> ConstrainedProgram<'a, F, G> {
|
||||
}
|
||||
}
|
||||
} else {
|
||||
for (i, item) in input.into_iter().enumerate() {
|
||||
for (i, item) in input.iter_mut().enumerate() {
|
||||
let namespace_string = format!(
|
||||
"evaluate dyn array assignment eq {} {}:{}",
|
||||
i, context.span.line_start, context.span.col_start
|
||||
|
@ -67,10 +67,8 @@ pub fn run_tests<T: Runner>(runner: &T, expectation_category: &str) {
|
||||
let mut outputs = vec![];
|
||||
|
||||
for (path, content) in tests.into_iter() {
|
||||
if !filter.is_empty() {
|
||||
if !path.contains(filter) {
|
||||
continue;
|
||||
}
|
||||
if !filter.is_empty() && !path.contains(filter) {
|
||||
continue;
|
||||
}
|
||||
let config = extract_test_config(&content);
|
||||
if config.is_none() {
|
||||
|
Loading…
Reference in New Issue
Block a user