Skip to content

Commit

Permalink
Also hash mem::discriminant in hash_stmt
Browse files Browse the repository at this point in the history
  • Loading branch information
flip1995 committed May 14, 2019
1 parent f11b236 commit 4b4d734
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions clippy_lints/src/utils/hir_utils.rs
Original file line number Diff line number Diff line change
Expand Up @@ -578,6 +578,8 @@ impl<'a, 'tcx: 'a> SpanlessHash<'a, 'tcx> {
}

pub fn hash_stmt(&mut self, b: &Stmt) {
std::mem::discriminant(&b.node).hash(&mut self.s);

match b.node {
StmtKind::Local(ref local) => {
if let Some(ref init) = local.init {
Expand Down

0 comments on commit 4b4d734

Please sign in to comment.