From: whitequark Date: Sun, 26 May 2019 17:10:56 +0000 (+0000) Subject: back.rtlil: allow specifying platform for convert(). X-Git-Tag: locally_working~243 X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=f17375a60b8a220ebdde19af03e1b92d92225c3c;p=nmigen.git back.rtlil: allow specifying platform for convert(). --- diff --git a/nmigen/back/rtlil.py b/nmigen/back/rtlil.py index 12415b3..1a1fabc 100644 --- a/nmigen/back/rtlil.py +++ b/nmigen/back/rtlil.py @@ -878,8 +878,8 @@ def convert_fragment(builder, fragment, hierarchy): return module.name, port_map -def convert(fragment, name="top", **kwargs): - fragment = ir.Fragment.get(fragment, platform=None).prepare(**kwargs) +def convert(fragment, name="top", platform=None, **kwargs): + fragment = ir.Fragment.get(fragment, platform).prepare(**kwargs) builder = _Builder() convert_fragment(builder, fragment, hierarchy=(name,)) return str(builder)