From 2fd601f0381201cb27ee0b198a000f10d29e205a Mon Sep 17 00:00:00 2001 From: julio4 <30329843+julio4@users.noreply.github.com> Date: Mon, 6 Jan 2025 15:17:30 +0100 Subject: [PATCH] fix: remove FnOnceSnapImpl --- corelib/src/iter.cairo | 2 +- corelib/src/ops/function.cairo | 9 --------- 2 files changed, 1 insertion(+), 10 deletions(-) diff --git a/corelib/src/iter.cairo b/corelib/src/iter.cairo index f671ada0032..304c83baf3c 100644 --- a/corelib/src/iter.cairo +++ b/corelib/src/iter.cairo @@ -228,6 +228,6 @@ //! ``` //! //! [`map`]: Iterator::map -mod traits; mod adapters; +mod traits; pub use traits::{IntoIterator, Iterator}; diff --git a/corelib/src/ops/function.cairo b/corelib/src/ops/function.cairo index 27edda67ee2..1a9d8a37ce2 100644 --- a/corelib/src/ops/function.cairo +++ b/corelib/src/ops/function.cairo @@ -23,15 +23,6 @@ impl FnOnceImpl, +Fn> of FnOnce { } } -/// An implementation of `FnOnce` when `Fn` is implemented and the receiver is by-reference. -/// Makes sure we can always pass an `Fn` to a function that expects an `FnOnce`. -impl FnOnceSnapImpl, +Fn> of FnOnce<@T, Args> { - type Output = Fn::::Output; - fn call(self: @T, args: Args) -> Self::Output { - Fn::call(self, args) - } -} - /// The version of the call operator that takes a by-snapshot receiver. /// /// Instances of `Fn` can be called multiple times.