indexed-list-literals-0.1.0.1: Type safe indexed list literals

Safe HaskellSafe
LanguageHaskell2010

Data.IndexedListLiterals

Synopsis

Documentation

class IndexedListLiterals (input :: Type) (length :: Nat) (output :: Type) | output length -> input, input -> output length where #

A type class which allows you to write tuples which can be transformed into a list the length of the list is also provided as a Nat

Minimal complete definition

toList

Methods

toList :: input -> [output] #

Instances

IndexedListLiterals (OneTuple a) 1 a # 

Methods

toList :: OneTuple a -> [a] #

IndexedListLiterals (a, a) 2 a # 

Methods

toList :: (a, a) -> [a] #

IndexedListLiterals (ZeroTuple Type a) 0 a # 

Methods

toList :: ZeroTuple Type a -> [a] #

IndexedListLiterals (a, a, a) 3 a # 

Methods

toList :: (a, a, a) -> [a] #

IndexedListLiterals (a, a, a, a) 4 a # 

Methods

toList :: (a, a, a, a) -> [a] #

IndexedListLiterals (a, a, a, a, a) 5 a # 

Methods

toList :: (a, a, a, a, a) -> [a] #

IndexedListLiterals (a, a, a, a, a, a) 6 a # 

Methods

toList :: (a, a, a, a, a, a) -> [a] #

IndexedListLiterals (a, a, a, a, a, a, a) 7 a # 

Methods

toList :: (a, a, a, a, a, a, a) -> [a] #

IndexedListLiterals (a, a, a, a, a, a, a, a) 8 a # 

Methods

toList :: (a, a, a, a, a, a, a, a) -> [a] #

IndexedListLiterals (a, a, a, a, a, a, a, a, a) 9 a # 

Methods

toList :: (a, a, a, a, a, a, a, a, a) -> [a] #

IndexedListLiterals (a, a, a, a, a, a, a, a, a, a) 10 a # 

Methods

toList :: (a, a, a, a, a, a, a, a, a, a) -> [a] #

IndexedListLiterals (a, a, a, a, a, a, a, a, a, a, a) 11 a # 

Methods

toList :: (a, a, a, a, a, a, a, a, a, a, a) -> [a] #

IndexedListLiterals (a, a, a, a, a, a, a, a, a, a, a, a) 12 a # 

Methods

toList :: (a, a, a, a, a, a, a, a, a, a, a, a) -> [a] #

IndexedListLiterals (a, a, a, a, a, a, a, a, a, a, a, a, a) 13 a # 

Methods

toList :: (a, a, a, a, a, a, a, a, a, a, a, a, a) -> [a] #

IndexedListLiterals (a, a, a, a, a, a, a, a, a, a, a, a, a, a) 14 a # 

Methods

toList :: (a, a, a, a, a, a, a, a, a, a, a, a, a, a) -> [a] #

IndexedListLiterals (a, a, a, a, a, a, a, a, a, a, a, a, a, a, a) 15 a # 

Methods

toList :: (a, a, a, a, a, a, a, a, a, a, a, a, a, a, a) -> [a] #

IndexedListLiterals (a, a, a, a, a, a, a, a, a, a, a, a, a, a, a, a) 16 a # 

Methods

toList :: (a, a, a, a, a, a, a, a, a, a, a, a, a, a, a, a) -> [a] #

IndexedListLiterals (a, a, a, a, a, a, a, a, a, a, a, a, a, a, a, a, a) 17 a # 

Methods

toList :: (a, a, a, a, a, a, a, a, a, a, a, a, a, a, a, a, a) -> [a] #

IndexedListLiterals (a, a, a, a, a, a, a, a, a, a, a, a, a, a, a, a, a, a) 18 a # 

Methods

toList :: (a, a, a, a, a, a, a, a, a, a, a, a, a, a, a, a, a, a) -> [a] #

IndexedListLiterals (a, a, a, a, a, a, a, a, a, a, a, a, a, a, a, a, a, a, a) 19 a # 

Methods

toList :: (a, a, a, a, a, a, a, a, a, a, a, a, a, a, a, a, a, a, a) -> [a] #

IndexedListLiterals (a, a, a, a, a, a, a, a, a, a, a, a, a, a, a, a, a, a, a, a) 20 a # 

Methods

toList :: (a, a, a, a, a, a, a, a, a, a, a, a, a, a, a, a, a, a, a, a) -> [a] #

type ILL = IndexedListLiterals #

An alias for IndexedListLiterals

data ZeroTuple a #

Intuitively the zero tuple is () or Void but this breaks the Functional Dependency "input -> output length" stopping reliable inference, so this constructor is used to preserve type information

Constructors

ZeroTuple 

Instances

IndexedListLiterals (ZeroTuple Type a) 0 a # 

Methods

toList :: ZeroTuple Type a -> [a] #