module GHC.CmmToLlvm.Version.Bounds
  ( supportedLlvmVersionLowerBound
  , supportedLlvmVersionUpperBound
  )
where

import GHC.Prelude ()

import GHC.CmmToLlvm.Version.Type

import qualified Data.List.NonEmpty as NE

-- | The (inclusive) lower bound on the LLVM Version that is currently supported.
supportedLlvmVersionLowerBound :: LlvmVersion
supportedLlvmVersionLowerBound :: LlvmVersion
supportedLlvmVersionLowerBound = NonEmpty Int -> LlvmVersion
LlvmVersion (Int
13 Int -> [Int] -> NonEmpty Int
forall a. a -> [a] -> NonEmpty a
NE.:| [])

-- | The (not-inclusive) upper bound  bound on the LLVM Version that is currently supported.
supportedLlvmVersionUpperBound :: LlvmVersion
supportedLlvmVersionUpperBound :: LlvmVersion
supportedLlvmVersionUpperBound = NonEmpty Int -> LlvmVersion
LlvmVersion (Int
20 Int -> [Int] -> NonEmpty Int
forall a. a -> [a] -> NonEmpty a
NE.:| [])