From bb906ca3966cc0bf4211c2b3720df489492b5bf9 Mon Sep 17 00:00:00 2001 From: Don Stewart Date: Mon, 30 Apr 2007 05:11:51 +0200 Subject: remove redundant call to 'delete' in 'shift' darcs-hash:20070430031151-9c5c1-7d66b13bc36af0e33af655f33ef287c8d4a379e7.gz --- StackSet.hs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/StackSet.hs b/StackSet.hs index f21306f..b455315 100644 --- a/StackSet.hs +++ b/StackSet.hs @@ -152,7 +152,7 @@ rotate o w = maybe w id $ do -- exception is thrown. -- shift :: (Integral i, Ord a) => i -> StackSet i j a -> StackSet i j a -shift n w = maybe w (\k -> insert k n (delete k w)) (peek w) +shift n w = maybe w (\k -> insert k n w) (peek w) -- | /O(log n)/. Insert an element onto the top of stack 'n'. -- If the element is already in the stack 'n', it is moved to the top. -- cgit v1.2.3