diff --git a/nac3core/src/toplevel/test.rs b/nac3core/src/toplevel/test.rs index 54893d36..cac627af 100644 --- a/nac3core/src/toplevel/test.rs +++ b/nac3core/src/toplevel/test.rs @@ -939,7 +939,7 @@ fn test_analyze(source: Vec<&str>, res: Vec<&str>) { indoc! {" class A: def fun(self): - 1 + 2 + pass "}, indoc!{" class B: diff --git a/nac3core/src/typecheck/type_inferencer/mod.rs b/nac3core/src/typecheck/type_inferencer/mod.rs index 8e32922e..8c1f68be 100644 --- a/nac3core/src/typecheck/type_inferencer/mod.rs +++ b/nac3core/src/typecheck/type_inferencer/mod.rs @@ -128,7 +128,7 @@ impl<'a> fold::Fold<()> for Inferencer<'a> { } } ast::StmtKind::AnnAssign { .. } | ast::StmtKind::Expr { .. } => {} - ast::StmtKind::Break | ast::StmtKind::Continue => {} + ast::StmtKind::Break | ast::StmtKind::Continue | ast::StmtKind::Pass => {} ast::StmtKind::Return { value } => match (value, self.function_data.return_type) { (Some(v), Some(v1)) => { self.unify(v.custom.unwrap(), v1, &v.location)?;