Commit 362420c
committed
Fix complex blocks warning when running clippy
```
warning: in a `match` scrutinee, avoid complex blocks or closures with blocks; instead, move the block or closure higher and bind it with a `let`
--> src/dialect/postgresql.rs:233:74
|
233 | match parser.maybe_parse(|parser| -> Result<ObjectName, ParserError> {
| __________________________________________________________________________^
234 | | parser.expect_keyword(Keyword::CREATE)?;
235 | | parser.expect_keyword(Keyword::TYPE)?;
236 | | let name = parser.parse_object_name(false)?;
... |
239 | | Ok(name)
240 | | }) {
| |_____^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#blocks_in_conditions
= note: `#[warn(clippy::blocks_in_conditions)]` on by default
```1 parent ee90373 commit 362420c
1 file changed
+4
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
230 | 230 | | |
231 | 231 | | |
232 | 232 | | |
233 | | - | |
| 233 | + | |
234 | 234 | | |
235 | 235 | | |
236 | 236 | | |
237 | 237 | | |
238 | 238 | | |
239 | 239 | | |
240 | | - | |
| 240 | + | |
| 241 | + | |
| 242 | + | |
241 | 243 | | |
242 | 244 | | |
243 | 245 | | |
| |||
0 commit comments