Skip to content

Commit 1cf361d

Browse files
authored
set clippy to ignore internal mutability (#7)
1 parent 26cc201 commit 1cf361d

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

clippy.toml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
# prevents a false-positive lint on our types containing bytes::Bytes
2+
# https://rust-lang.github.io/rust-clippy/master/index.html#/mutable_key_type
3+
ignore-interior-mutability = ["bytes::Bytes", "circuit::netlist::NetRef"]

src/graph.rs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,6 @@ where
7070
{
7171
fn build(netlist: &'a Netlist<I>) -> Result<Self, String> {
7272
let mut net_fan_out: HashMap<Net, Vec<NetRef<I>>> = HashMap::new();
73-
#[allow(clippy::mutable_key_type)]
7473
let mut node_fan_out: HashMap<NetRef<I>, Vec<NetRef<I>>> = HashMap::new();
7574
let mut is_an_output: HashSet<Net> = HashSet::new();
7675

@@ -139,7 +138,6 @@ where
139138
I: Instantiable,
140139
{
141140
fn build(netlist: &'a Netlist<I>) -> Result<Self, String> {
142-
#[allow(clippy::mutable_key_type)]
143141
let mut comb_depth: HashMap<NetRef<I>, usize> = HashMap::new();
144142

145143
let mut nodes = Vec::new();

0 commit comments

Comments
 (0)