From 1acdf45274b6e4cf9a3f0db187efd34eef894aa4 Mon Sep 17 00:00:00 2001 From: Danil Date: Tue, 12 Dec 2023 08:48:31 +0100 Subject: [PATCH] fmt Signed-off-by: Danil --- crates/cheatcodes/src/lib.rs | 14 +++++++------- crates/zkforge/bin/cmd/create.rs | 5 ++++- 2 files changed, 11 insertions(+), 8 deletions(-) diff --git a/crates/cheatcodes/src/lib.rs b/crates/cheatcodes/src/lib.rs index b7a401c07..e2e874cac 100644 --- a/crates/cheatcodes/src/lib.rs +++ b/crates/cheatcodes/src/lib.rs @@ -57,13 +57,6 @@ pub(crate) trait Cheatcode: CheatcodeDef { #[inline] fn apply_traced(&self, ccx: &mut CheatsCtxt) -> Result { - let span = trace_span(self); - let _enter = span.enter(); - trace_call(); - let result = self.apply_full(ccx); - trace_return(&result); - return result; - // Separate functions to avoid inline and monomorphization bloat. fn trace_span(cheat: &T) -> tracing::Span { if enabled!(tracing::Level::TRACE) { @@ -86,6 +79,13 @@ pub(crate) trait Cheatcode: CheatcodeDef { } ); } + + let span = trace_span(self); + let _enter = span.enter(); + trace_call(); + let result = self.apply_full(ccx); + trace_return(&result); + return result } } diff --git a/crates/zkforge/bin/cmd/create.rs b/crates/zkforge/bin/cmd/create.rs index e31568d86..1ffb01d5f 100644 --- a/crates/zkforge/bin/cmd/create.rs +++ b/crates/zkforge/bin/cmd/create.rs @@ -549,7 +549,10 @@ where /// Create a deployment tx using the provided tokens as constructor /// arguments - pub fn _deploy_tokens(self, params: Vec) -> Result, ContractError> + pub fn _deploy_tokens( + self, + params: Vec, + ) -> Result, ContractError> where B: Clone, {