aboutsummaryrefslogtreecommitdiffstats
path: root/ice40
diff options
context:
space:
mode:
authorClifford Wolf <clifford@clifford.at>2018-06-02 12:57:19 +0200
committerClifford Wolf <clifford@clifford.at>2018-06-02 12:57:19 +0200
commitcdb31fdafc77331faf2b0f5a5d30af33f7e6b71f (patch)
tree8dc1d88f0345e1b2d8f55e16252baae5dcf31b29 /ice40
parent90c7e3b13d9e7f1791c9815734fccaca4f8b5fe8 (diff)
downloadnextpnr-cdb31fdafc77331faf2b0f5a5d30af33f7e6b71f.tar.gz
nextpnr-cdb31fdafc77331faf2b0f5a5d30af33f7e6b71f.tar.bz2
nextpnr-cdb31fdafc77331faf2b0f5a5d30af33f7e6b71f.zip
Use singular in type names (BelRange, WireIterator)
Signed-off-by: Clifford Wolf <clifford@clifford.at>
Diffstat (limited to 'ice40')
-rw-r--r--ice40/chip.h36
1 files changed, 18 insertions, 18 deletions
diff --git a/ice40/chip.h b/ice40/chip.h
index 397e2bf3..99fd5e25 100644
--- a/ice40/chip.h
+++ b/ice40/chip.h
@@ -134,12 +134,12 @@ namespace std
// -----------------------------------------------------------------------
-struct BelsIterator
+struct BelIterator
{
int cursor;
void operator++() { cursor++; }
- bool operator!=(const BelsIterator &other) const { return cursor != other.cursor; }
+ bool operator!=(const BelIterator &other) const { return cursor != other.cursor; }
BelId operator*() const {
BelId ret;
@@ -148,21 +148,21 @@ struct BelsIterator
}
};
-struct BelsRange
+struct BelRange
{
- BelsIterator b, e;
- BelsIterator begin() const { return b; }
- BelsIterator end() const { return e; }
+ BelIterator b, e;
+ BelIterator begin() const { return b; }
+ BelIterator end() const { return e; }
};
// -----------------------------------------------------------------------
-struct AllWiresIterator
+struct AllWireIterator
{
int cursor;
void operator++() { cursor++; }
- bool operator!=(const AllWiresIterator &other) const { return cursor != other.cursor; }
+ bool operator!=(const AllWireIterator &other) const { return cursor != other.cursor; }
WireId operator*() const {
WireId ret;
@@ -171,11 +171,11 @@ struct AllWiresIterator
}
};
-struct AllWiresRange
+struct AllWireRange
{
- AllWiresIterator b, e;
- AllWiresIterator begin() const { return b; }
- AllWiresIterator end() const { return e; }
+ AllWireIterator b, e;
+ AllWireIterator begin() const { return b; }
+ AllWireIterator end() const { return e; }
};
// -----------------------------------------------------------------------
@@ -285,17 +285,17 @@ struct Chip
return wire_data[wire.index].name;
}
- BelsRange getBels() const
+ BelRange getBels() const
{
- BelsRange range;
+ BelRange range;
range.b.cursor = 0;
range.e.cursor = num_bels;
return range;
}
- BelsRange getBelsByType(BelType type) const
+ BelRange getBelsByType(BelType type) const
{
- BelsRange range;
+ BelRange range;
// FIXME
#if 0
if (type == "TYPE_A") {
@@ -317,9 +317,9 @@ struct Chip
// FIXME: vector<GuiLine> getBelGuiLines(BelId bel) const;
// FIXME: vector<GuiLine> getWireGuiLines(WireId wire) const;
- AllWiresRange getWires() const
+ AllWireRange getWires() const
{
- AllWiresRange range;
+ AllWireRange range;
range.b.cursor = 0;
range.e.cursor = num_wires;
return range;