@@ -1042,7 +1042,7 @@ groupsRollingBy cmp f (Stream step state) =
1042 res <- step (adaptState gst) stt
1042 res <- step (adaptState gst) stt
1043 case res of
1043 case res of
1044 Yield x s -> do
1044 Yield x s -> do
1045− if cmp x prev
1045+ if cmp prev x
1047 acc' <- fstep acc x
1047 acc' <- fstep acc x
1048 go SPEC x s acc'
1048 go SPEC x s acc'
@@ -1061,7 +1061,7 @@ groupsRollingBy cmp f (Stream step state) =
1061 res <- step (adaptState gst) stt
1061 res <- step (adaptState gst) stt
1062 case res of
1062 case res of
1063 Yield x s -> do
1063 Yield x s -> do
1064− if cmp x prevv
1064+ if cmp prevv x
1066 acc' <- fstep acc x
1066 acc' <- fstep acc x
1067 go SPEC x s acc'
1067 go SPEC x s acc'