-- |
-- Module:     Data.Vector.Algorithms.Quicksort.Predefined.UTripleSequentialMedian3or5ST
-- Copyright:  (c) Sergey Vinokurov 2023
-- License:    Apache-2.0 (see LICENSE)
-- Maintainer: serg.foo@gmail.com

module Data.Vector.Algorithms.Quicksort.Predefined.UTripleSequentialMedian3or5ST
  ( sortUTripleSequentialMedian3or5ST
  ) where

import Control.Monad.ST
import Data.Vector.Unboxed qualified as U

import Data.Vector.Algorithms.Quicksort.Parameterised

import Data.Vector.Algorithms.Quicksort.Predefined.SortTriple

import Data.Vector.Algorithms.Quicksort.Predefined.UTripleSequentialMedian3ST ()

{-# NOINLINE sortUTripleSequentialMedian3or5ST #-}
sortUTripleSequentialMedian3or5ST :: U.MVector s SortTriple -> ST s ()
sortUTripleSequentialMedian3or5ST :: forall s. MVector s SortTriple -> ST s ()
sortUTripleSequentialMedian3or5ST = Sequential
-> Median3or5 SortTriple
-> MVector (PrimState (ST s)) SortTriple
-> ST s ()
forall p med x (m :: * -> *) a (v :: * -> * -> *).
(Fork2 p x m, Median med a m (PrimState m), PrimMonad m, Ord a,
 MVector v a) =>
p -> med -> v (PrimState m) a -> m ()
sortInplaceFM Sequential
Sequential (forall a. Median3or5 a
forall {k} (a :: k). Median3or5 a
Median3or5 @SortTriple)