Replace let Some(..) = with .is_some()
Signed-off-by: wcampbell <wcampbell1995@gmail.com>
This commit is contained in:
parent
edeb631ad0
commit
e23acc341c
2 changed files with 2 additions and 2 deletions
|
@ -526,7 +526,7 @@ impl MetaItemKind {
|
||||||
fn list_from_tokens(tokens: TokenStream) -> Option<MetaItemKind> {
|
fn list_from_tokens(tokens: TokenStream) -> Option<MetaItemKind> {
|
||||||
let mut tokens = tokens.into_trees().peekable();
|
let mut tokens = tokens.into_trees().peekable();
|
||||||
let mut result = Vec::new();
|
let mut result = Vec::new();
|
||||||
while let Some(..) = tokens.peek() {
|
while tokens.peek().is_some() {
|
||||||
let item = NestedMetaItem::from_tokens(&mut tokens)?;
|
let item = NestedMetaItem::from_tokens(&mut tokens)?;
|
||||||
result.push(item);
|
result.push(item);
|
||||||
match tokens.next() {
|
match tokens.next() {
|
||||||
|
|
|
@ -165,7 +165,7 @@ fn build_drop_shim<'tcx>(tcx: TyCtxt<'tcx>, def_id: DefId, ty: Option<Ty<'tcx>>)
|
||||||
let mut body =
|
let mut body =
|
||||||
new_body(source, blocks, local_decls_for_sig(&sig, span), sig.inputs().len(), span);
|
new_body(source, blocks, local_decls_for_sig(&sig, span), sig.inputs().len(), span);
|
||||||
|
|
||||||
if let Some(..) = ty {
|
if ty.is_some() {
|
||||||
// The first argument (index 0), but add 1 for the return value.
|
// The first argument (index 0), but add 1 for the return value.
|
||||||
let dropee_ptr = Place::from(Local::new(1 + 0));
|
let dropee_ptr = Place::from(Local::new(1 + 0));
|
||||||
if tcx.sess.opts.debugging_opts.mir_emit_retag {
|
if tcx.sess.opts.debugging_opts.mir_emit_retag {
|
||||||
|
|
Loading…
Add table
Reference in a new issue