view agda/regex.agda @ 146:6663205ed308

...
author Shinji KONO <kono@ie.u-ryukyu.ac.jp>
date Wed, 30 Dec 2020 12:07:07 +0900
parents b3f05cd08d24
children
line wrap: on
line source

module regex where

data Regex ( Σ : Set) : Set  where
  ε     : Regex Σ                -- empty
  φ     : Regex  Σ               -- fail
  _*    : Regex  Σ  → Regex  Σ 
  _&_   : Regex  Σ  → Regex  Σ → Regex Σ
  _||_  : Regex  Σ  → Regex  Σ → Regex Σ
  <_>   : Σ → Regex  Σ

infixr 40 _&_ _||_