mirror of
https://github.com/ProvableHQ/leo.git
synced 2024-11-11 19:36:26 +03:00
clippy: remove a few redundant clones
Signed-off-by: ljedrz <ljedrz@gmail.com>
This commit is contained in:
parent
4f298510f9
commit
5e4f799685
@ -36,14 +36,7 @@ impl<F: Field + PrimeField, G: GroupType<F>> ConstrainedProgram<F, G> {
|
||||
index: RangeOrExpression,
|
||||
span: &Span,
|
||||
) -> Result<ConstrainedValue<F, G>, ExpressionError> {
|
||||
let array = match self.enforce_operand(
|
||||
cs,
|
||||
file_scope.clone(),
|
||||
function_scope.clone(),
|
||||
expected_type,
|
||||
array,
|
||||
span,
|
||||
)? {
|
||||
let array = match self.enforce_operand(cs, file_scope, function_scope, expected_type, array, span)? {
|
||||
ConstrainedValue::Array(array) => array,
|
||||
value => return Err(ExpressionError::undefined_array(value.to_string(), span.to_owned())),
|
||||
};
|
||||
|
@ -42,7 +42,7 @@ impl<F: Field + PrimeField, G: GroupType<F>> ConstrainedProgram<F, G> {
|
||||
|
||||
// Save a reference to the circuit we are mutating.
|
||||
let circuit_id_string = circuit_identifier.to_string();
|
||||
let declared_circuit_reference = new_scope(function_scope.clone(), &circuit_id_string);
|
||||
let declared_circuit_reference = new_scope(function_scope, &circuit_id_string);
|
||||
|
||||
(
|
||||
declared_circuit_reference,
|
||||
|
Loading…
Reference in New Issue
Block a user