Refine docs.

This commit is contained in:
Stephen Chung
2020-10-27 11:30:38 +08:00
parent 4add90b215
commit 01663a6581
17 changed files with 163 additions and 152 deletions

View File

@@ -798,7 +798,7 @@ fn optimize(
// Add back the last statement unless it is a lone No-op
if let Some(stmt) = last_stmt {
if !result.is_empty() || !matches!(stmt, Stmt::Noop(_)) {
if !result.is_empty() || !stmt.is_noop() {
result.push(stmt);
}
}