Skip to content

Instantly share code, notes, and snippets.

@bohde
Created January 2, 2016 15:12
Show Gist options
  • Save bohde/654d7e3547661610f2cf to your computer and use it in GitHub Desktop.
Save bohde/654d7e3547661610f2cf to your computer and use it in GitHub Desktop.
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE TypeOperators #-}
{-# LANGUAGE KindSignatures #-}
module Data.HdrHistogram.Config.Test where
import GHC.TypeLits (Nat, type (<=))
-- Is there a way to add constraints to these kinds? For example, 1 <= sig <= 7, or lowest <= highest.
-- I found https://hackage.haskell.org/package/base-4.7.0.1/docs/GHC-TypeLits.html#t:-60--61--63-, but don't know how to use it.
data Config (lowest :: Nat) (highest :: Nat) (sig :: Nat)
p :: Config 1 1024 3
p = undefined
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment