diff options
author | gatecat <gatecat@ds0.me> | 2022-08-10 18:58:22 +0100 |
---|---|---|
committer | gatecat <gatecat@ds0.me> | 2022-08-10 18:58:22 +0100 |
commit | c60fb94b6c45ca74632e972995555170063b3a03 (patch) | |
tree | b6bc6fe3cecc6962e12e61b9febb5c85e06960ed /nexus/pack.cc | |
parent | a20d21bd135aceb9155eaee714488d1d76c60898 (diff) | |
download | nextpnr-c60fb94b6c45ca74632e972995555170063b3a03.tar.gz nextpnr-c60fb94b6c45ca74632e972995555170063b3a03.tar.bz2 nextpnr-c60fb94b6c45ca74632e972995555170063b3a03.zip |
refactor: Use IdString::in instead of || chains
Signed-off-by: gatecat <gatecat@ds0.me>
Diffstat (limited to 'nexus/pack.cc')
-rw-r--r-- | nexus/pack.cc | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/nexus/pack.cc b/nexus/pack.cc index e727364d..3d293f69 100644 --- a/nexus/pack.cc +++ b/nexus/pack.cc @@ -1981,11 +1981,11 @@ struct NexusPacker pool<IdString> changed_cells; for (auto net : changed_nets) { for (auto &user : ctx->nets.at(net)->users) - if (user.port == id_CLKI || user.port == id_REFCK) + if (user.port.in(id_CLKI, id_REFCK)) changed_cells.insert(user.cell->name); auto &drv = ctx->nets.at(net)->driver; if (iter == 1 && drv.cell != nullptr) { - if (drv.cell->type == id_OSC_CORE && (drv.port == id_HFCLKOUT || drv.port == id_LFCLKOUT)) + if (drv.cell->type == id_OSC_CORE && (drv.port.in(id_HFCLKOUT, id_LFCLKOUT))) changed_cells.insert(drv.cell->name); if (drv.cell->type == id_DCC && drv.port == id_CLKO) changed_cells.insert(drv.cell->name); |