about summary refs log tree commit diff
path: root/compiler/rustc_llvm/llvm-wrapper/RustWrapper.cpp
diff options
context:
space:
mode:
authorflip1995 <philipp.krones@embecosm.com>2021-10-08 16:16:56 +0200
committerflip1995 <philipp.krones@embecosm.com>2021-10-08 16:16:56 +0200
commitb423b85ca99c2a085797e228ec405038bbd3308f (patch)
treeb7adcb3469429666e4d9dbb72271a889d272cd59 /compiler/rustc_llvm/llvm-wrapper/RustWrapper.cpp
parent78e73129baf65f4095002422303157d5e64e9479 (diff)
downloadrust-b423b85ca99c2a085797e228ec405038bbd3308f.tar.gz
rust-b423b85ca99c2a085797e228ec405038bbd3308f.zip
Don't trigger semicolon_if_nothing_returned in expanded code
Before this lint didn't trigger on macros. With rust-lang/rust#88175
this isn't enough anymore. In this PR a `WhileLoop` desugaring kind was
introduced. This overrides the span of expanded expressions when
lowering the while loop. So if a while loop is in a macro, the
expressions that it expands to are no longer marked with
`ExpnKind::Macro`, but with `ExpnKind::Desugaring`. In general, this is
the correct behavior and the same that is done for `ForLoop`s. It just
tripped up this lint.
Diffstat (limited to 'compiler/rustc_llvm/llvm-wrapper/RustWrapper.cpp')
0 files changed, 0 insertions, 0 deletions