Operators

Safe Haskell | Safe-Inferred
Language | Haskell2010

Operators

Description

Test operators with or without fixity declarations

Synopsis

- (+-) :: a -> a -> a
- (*/) :: a -> a -> a
- foo :: a -> a -> a
- data Foo
  - = Foo `Bar` Foo
  - | Foo :- Foo
- pattern (:+) :: a -> a -> [a]
- data a <-> b where
  - (:<->) :: a -> b -> a <-> b
- type family a ++ b
- data family a ** b
- class a ><> b | a -> b where
  - type a <>< b :: *
  - data a ><< b
  - (>><), (<<>) :: a -> b -> ()
  - (**>), (**<), (>**), (<**) :: a -> a -> ()
- type (>-<) a b = a <-> b

# Documentation

(+-) :: a -> a -> a #

Operator with no fixity

(*/) :: a -> a -> a infixr 7 #

Operator with infixr 7

foo :: a -> a -> a infixl 3 #

Named function with infixl 3

data Foo #

Data type with operator constructors

Constructors

Foo `Bar` Foo infixl 3 | Has infixl 3
Foo :- Foo infixr 5 | Has infixr 5

pattern (:+) :: a -> a -> [a] infixr 3 #

Pattern synonym, infixr 3

data a <-> b where infixl 6 #

Type name, infixl 6 and GADT constructor

Constructors

(:<->) :: a -> b -> a <-> b infixr 6 |

type family a ++ b infix 3 #

Type family with fixity

data family a ** b infix 9 #

Data family with fixity

class a ><> b | a -> b where infixr 1 #

Class with fixity, including associated types

Associated Types

type a <>< b :: * infixl 2 #

data a ><< b infixl 3 #

Methods

(>><) :: a -> b -> () infixr 4 #

(<<>) :: a -> b -> () infixl 5 #

(**>) :: a -> a -> () infixr 8 #

Multiple fixities

(**<) :: a -> a -> () infixl 8 #

Multiple fixities

(>**) :: a -> a -> () infixr 8 #

Multiple fixities

(<**) :: a -> a -> () infixl 8 #

Multiple fixities

type (>-<) a b = a <-> b infixl 6 #

Type synonym with fixity