dfa
dfa copied to clipboard
Minor: Creating DFA with outputs=None fails.
The following code fails, which is slightly unexpected:
dfa1 = DFA(
start=0,
inputs={0, 1},
outputs=None,
label=lambda s: (s % 4) == 3,
transition=lambda s, c: (s + c) % 4,
)
I would expect this to be the same as not setting any outputs. Setting an empty dictionary yields problems with the lstar library.
In principle this seems easy to fix. In the same way as how inputs can be optional.
Happy to shepherd a PR, but bandwidth limited until mid may