mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-09-23 02:24:08 +00:00
remove unnecessary lazy evaluations
This commit is contained in:
parent
7530d76f00
commit
cc80c5bd07
31 changed files with 50 additions and 51 deletions
|
@ -111,7 +111,7 @@ fn punctuation(
|
|||
let is_raw_ptr = (|| {
|
||||
let prefix_expr = parent.and_then(ast::PrefixExpr::cast)?;
|
||||
let expr = prefix_expr.expr()?;
|
||||
sema.type_of_expr(&expr)?.original.is_raw_ptr().then(|| ())
|
||||
sema.type_of_expr(&expr)?.original.is_raw_ptr().then_some(())
|
||||
})();
|
||||
if let Some(()) = is_raw_ptr {
|
||||
HlTag::Operator(HlOperator::Other) | HlMod::Unsafe
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue