Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Minor: Creating DFA with outputs=None fails. #5

Open
sjunges opened this issue Apr 15, 2022 · 1 comment
Open

Minor: Creating DFA with outputs=None fails. #5

sjunges opened this issue Apr 15, 2022 · 1 comment

Comments

@sjunges
Copy link
Contributor

sjunges commented Apr 15, 2022

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.

@mvcisback
Copy link
Owner

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

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants