Commit 040a372
committed
Reject
`arc.clone()` leaves the code somewhat ambiguous to whether we're
doing an expensive deep-clone operation or if we're doing a
(relatively) cheap pointer-copy-and-atomic-increment operation.
More importantly, it leaves entirely unclear what the semantics of
the object we just created are - does updating it update the
original or leave it be?
Thus, here we require `Arc::clone` via clippy enforcement in CIArc.clone() syntax in favor of Arc::clone
1 parent ae51f25 commit 040a372
1 file changed
+2
-0
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2 | 2 | | |
3 | 3 | | |
4 | 4 | | |
| 5 | + | |
| 6 | + | |
5 | 7 | | |
6 | 8 | | |
7 | 9 | | |
| |||
0 commit comments