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

if m.If(...): is silently dropped #284

Closed
Stary2001 opened this issue Dec 23, 2019 · 0 comments
Closed

if m.If(...): is silently dropped #284

Stary2001 opened this issue Dec 23, 2019 · 0 comments
Milestone

Comments

@Stary2001
Copy link

In some nMigen code I had if m.If(...) as a typo of with m.If(...): - this gets silently dropped.

<whitequark> Stary: the problem is that you're doing `if m.If():`
<whitequark> it should be `with m.If():`
<whitequark> `m.If()` itself just returns `None`, so the whole conditional is just ignored
<whitequark> I consider this a usability bug; please report an issue so I can make sure no one ever gets confused by this again
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants