let rec derive_eps =
function
| Slist0 _ | Slist0sep (_, _) | Sopt _ -> true
| Stry s -> derive_eps s
| Stree t -> tree_derive_eps t
| Slist1 _ | Slist1sep (_, _) | Stoken _ | Skeyword _ ->
false
| Smeta (_, _, _) | Snterm _ | Snterml (_, _) | Snext |
Sself -> false
and tree_derive_eps =
function
| LocAct (_, _) -> true
| Node { node = s; brother = bro; son = son } ->
((derive_eps s) && (tree_derive_eps son)) ||
(tree_derive_eps bro)
| DeadEnd -> false