diff options
| author | Esteban Küber <esteban@kuber.com.ar> | 2025-09-02 00:02:16 +0000 | 
|---|---|---|
| committer | Esteban Küber <esteban@kuber.com.ar> | 2025-09-02 00:02:16 +0000 | 
| commit | ff60e5c3f3a00fcf03fc4d50432cd76f2a890a9f (patch) | |
| tree | 8f277a9ecece22a5b40afc3f032598087f68345d /compiler/rustc_mir_transform/src | |
| parent | f5b5e67f0f512d30cc6a5dab0ed6cf55c3905db5 (diff) | |
| download | rust-ff60e5c3f3a00fcf03fc4d50432cd76f2a890a9f.tar.gz rust-ff60e5c3f3a00fcf03fc4d50432cd76f2a890a9f.zip | |
Suggest parentheses around if-expressions
```
error[E0308]: mismatched types
  --> $DIR/expr-as-stmt-2.rs:15:15
   |
LL |     if true { true } else { false } && true;
   |     ----------^^^^-----------------
   |     |         |
   |     |         expected `()`, found `bool`
   |     expected this to be `()`
   |
help: parentheses are required to parse this as an expression
   |
LL |     (if true { true } else { false }) && true;
   |     +                               +
```
Diffstat (limited to 'compiler/rustc_mir_transform/src')
0 files changed, 0 insertions, 0 deletions
