diff options
| author | Simon Vandel Sillesen <simon.vandel@gmail.com> | 2020-09-19 23:53:18 +0200 |
|---|---|---|
| committer | Simon Vandel Sillesen <simon.vandel@gmail.com> | 2020-09-20 14:45:46 +0200 |
| commit | 25302740231152bccebc391e893d48ef9f3ca50a (patch) | |
| tree | 2b06528ac7bd8d8e5f3ef5dfa53c486f2c1a7908 /compiler | |
| parent | 0e06456ecbe244291f1feef7c24b7165f028e0d0 (diff) | |
| download | rust-25302740231152bccebc391e893d48ef9f3ca50a.tar.gz rust-25302740231152bccebc391e893d48ef9f3ca50a.zip | |
correct comment
Diffstat (limited to 'compiler')
| -rw-r--r-- | compiler/rustc_mir/src/transform/early_otherwise_branch.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/compiler/rustc_mir/src/transform/early_otherwise_branch.rs b/compiler/rustc_mir/src/transform/early_otherwise_branch.rs index e60cc8c1348..d44bd1e3495 100644 --- a/compiler/rustc_mir/src/transform/early_otherwise_branch.rs +++ b/compiler/rustc_mir/src/transform/early_otherwise_branch.rs @@ -21,7 +21,7 @@ use std::{borrow::Cow, fmt::Debug}; /// let y: Option<()>; /// let discriminant_x = // get discriminant of x /// let discriminant_y = // get discriminant of y -/// if discriminant_x != discriminant_y {1} else {0} +/// if discriminant_x != discriminant_y || discriminant_x == None {1} else {0} /// ``` pub struct EarlyOtherwiseBranch; |
