option package:attoparsec

option x p tries to apply action p. If p fails without consuming input, it returns the value x, otherwise the value returned by p.
priority  = option 0 (digitToInt <$> digit)