summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorClifford Wolf <clifford@clifford.at>2014-07-19 15:32:39 +0200
committerClifford Wolf <clifford@clifford.at>2014-07-19 15:32:39 +0200
commit1c288adcc03db49375dd0e214bbbc0b8b9099436 (patch)
treea1acbbba46d9b59d934bb2ddf953834229690a34
parent26f982ac0b69deb3cb9eda69e5cf687a69de4606 (diff)
Some "const" cleanups in SigMap
-rw-r--r--kernel/sigtools.h8
1 files changed, 4 insertions, 4 deletions
diff --git a/kernel/sigtools.h b/kernel/sigtools.h
index ae6a00f8..56497bb8 100644
--- a/kernel/sigtools.h
+++ b/kernel/sigtools.h
@@ -407,12 +407,12 @@ struct SigMap
}
// internal helper function
- void map_bit(RTLIL::SigChunk &c)
+ void map_bit(RTLIL::SigChunk &c) const
{
assert(c.width == 1);
bitDef_t bit(c.wire, c.offset);
if (c.wire && bits.count(bit) > 0)
- c = bits[bit]->chunk;
+ c = bits.at(bit)->chunk;
}
void add(RTLIL::SigSpec from, RTLIL::SigSpec to)
@@ -459,7 +459,7 @@ struct SigMap
unregister_bit(c);
}
- void apply(RTLIL::SigSpec &sig)
+ void apply(RTLIL::SigSpec &sig) const
{
sig.expand();
for (auto &c : sig.chunks)
@@ -467,7 +467,7 @@ struct SigMap
sig.optimize();
}
- RTLIL::SigSpec operator()(RTLIL::SigSpec sig)
+ RTLIL::SigSpec operator()(RTLIL::SigSpec sig) const
{
apply(sig);
return sig;