Fix new 'unnecessary trailing semicolon' warnings
This commit is contained in:
parent
db0d0e8c43
commit
6f91c32da6
28 changed files with 39 additions and 39 deletions
|
@ -451,7 +451,7 @@ impl<'a, 'tcx, Bx: BuilderMethods<'a, 'tcx>> FunctionCx<'a, 'tcx, Bx> {
|
|||
Inhabited,
|
||||
ZeroValid,
|
||||
UninitValid,
|
||||
};
|
||||
}
|
||||
let panic_intrinsic = intrinsic.and_then(|i| match i {
|
||||
sym::assert_inhabited => Some(AssertIntrinsic::Inhabited),
|
||||
sym::assert_zero_valid => Some(AssertIntrinsic::ZeroValid),
|
||||
|
|
|
@ -2345,7 +2345,7 @@ impl<'tcx> LateLintPass<'tcx> for InvalidValue {
|
|||
enum InitKind {
|
||||
Zeroed,
|
||||
Uninit,
|
||||
};
|
||||
}
|
||||
|
||||
/// Information about why a type cannot be initialized this way.
|
||||
/// Contains an error message and optionally a span to point at.
|
||||
|
|
|
@ -1131,7 +1131,7 @@ impl<'a, 'tcx> ImproperCTypesVisitor<'a, 'tcx> {
|
|||
fn check_for_opaque_ty(&mut self, sp: Span, ty: Ty<'tcx>) -> bool {
|
||||
struct ProhibitOpaqueTypes<'a, 'tcx> {
|
||||
cx: &'a LateContext<'tcx>,
|
||||
};
|
||||
}
|
||||
|
||||
impl<'a, 'tcx> ty::fold::TypeVisitor<'tcx> for ProhibitOpaqueTypes<'a, 'tcx> {
|
||||
type BreakTy = Ty<'tcx>;
|
||||
|
|
|
@ -254,7 +254,7 @@ macro_rules! make_mir_visitor {
|
|||
macro_rules! basic_blocks {
|
||||
(mut) => (body.basic_blocks_mut().iter_enumerated_mut());
|
||||
() => (body.basic_blocks().iter_enumerated());
|
||||
};
|
||||
}
|
||||
for (bb, data) in basic_blocks!($($mutability)?) {
|
||||
self.visit_basic_block_data(bb, data);
|
||||
}
|
||||
|
@ -275,7 +275,7 @@ macro_rules! make_mir_visitor {
|
|||
macro_rules! type_annotations {
|
||||
(mut) => (body.user_type_annotations.iter_enumerated_mut());
|
||||
() => (body.user_type_annotations.iter_enumerated());
|
||||
};
|
||||
}
|
||||
|
||||
for (index, annotation) in type_annotations!($($mutability)?) {
|
||||
self.visit_user_type_annotation(
|
||||
|
@ -909,7 +909,7 @@ macro_rules! make_mir_visitor {
|
|||
macro_rules! basic_blocks {
|
||||
(mut) => (body.basic_blocks_mut());
|
||||
() => (body.basic_blocks());
|
||||
};
|
||||
}
|
||||
let basic_block = & $($mutability)? basic_blocks!($($mutability)?)[location.block];
|
||||
if basic_block.statements.len() == location.statement_index {
|
||||
if let Some(ref $($mutability)? terminator) = basic_block.terminator {
|
||||
|
|
|
@ -540,7 +540,7 @@ fn polymorphize<'tcx>(
|
|||
|
||||
struct PolymorphizationFolder<'tcx> {
|
||||
tcx: TyCtxt<'tcx>,
|
||||
};
|
||||
}
|
||||
|
||||
impl ty::TypeFolder<'tcx> for PolymorphizationFolder<'tcx> {
|
||||
fn tcx<'a>(&'a self) -> TyCtxt<'tcx> {
|
||||
|
|
|
@ -15,7 +15,7 @@ where
|
|||
|
||||
struct UsedParamsNeedSubstVisitor<'tcx> {
|
||||
tcx: TyCtxt<'tcx>,
|
||||
};
|
||||
}
|
||||
|
||||
impl<'tcx> TypeVisitor<'tcx> for UsedParamsNeedSubstVisitor<'tcx> {
|
||||
type BreakTy = ();
|
||||
|
|
|
@ -309,7 +309,7 @@ fn well_formed_types_in_env<'tcx>(
|
|||
InherentImpl,
|
||||
Fn,
|
||||
Other,
|
||||
};
|
||||
}
|
||||
|
||||
let node_kind = match node {
|
||||
Node::TraitItem(item) => match item.kind {
|
||||
|
|
|
@ -477,7 +477,7 @@ pub(super) fn check_opaque_for_inheriting_lifetimes(
|
|||
struct ProhibitOpaqueVisitor<'tcx> {
|
||||
opaque_identity_ty: Ty<'tcx>,
|
||||
generics: &'tcx ty::Generics,
|
||||
};
|
||||
}
|
||||
|
||||
impl<'tcx> ty::fold::TypeVisitor<'tcx> for ProhibitOpaqueVisitor<'tcx> {
|
||||
type BreakTy = Option<Ty<'tcx>>;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue