3 public delegate Tuple
<D1
, DR1
> Parser
<D1
, DR1
> (D1 stream
);
5 static class Combinator
7 public static Parser
<L1
, LR1
> Lazy
<L1
, LR1
> (Func
<Parser
<L1
, LR1
>> func
)
12 public static Parser
<C1
, CR1
> Choice
<C1
, CR1
> (Parser
<C1
, CR1
> parsers
)
14 Parser
<C1
, CR1
> tail
= null;
16 Lazy (() => Choice (tail
));
21 public static void Main ()
23 Choice ((int l
) => Tuple
.Create (1, 2));