hdl.dsl: add Default(), an alias for Case() with no arguments.

Fixes #197.
This commit is contained in:
whitequark 2019-09-08 12:24:18 +00:00
parent eb04a2509e
commit 3f6abc0b7a
2 changed files with 21 additions and 1 deletions

View file

@ -289,6 +289,9 @@ class Module(_ModuleBuilderRoot, Elaboratable):
self._ctrl_context = "Switch"
self._statements = _outer_case
def Default(self):
return self.Case()
@contextmanager
def FSM(self, reset=None, domain="sync", name="fsm"):
self._check_context("FSM", context=None)