diff options
Diffstat (limited to 'common/kernel/nextpnr_types.cc')
| -rw-r--r-- | common/kernel/nextpnr_types.cc | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/common/kernel/nextpnr_types.cc b/common/kernel/nextpnr_types.cc index 82725d6f..8563eb27 100644 --- a/common/kernel/nextpnr_types.cc +++ b/common/kernel/nextpnr_types.cc @@ -177,4 +177,14 @@ void CellInfo::copyPortBusTo(IdString old_name, int old_offset, bool old_bracket } } +Loc CellInfo::getLocation() const +{ + if (pseudo_cell) { + return pseudo_cell->getLocation(); + } else { + NPNR_ASSERT(bel != BelId()); + return ctx->getBelLocation(bel); + } +} + NEXTPNR_NAMESPACE_END |
