Silence some warnings
This commit is contained in:
parent
43e23af700
commit
cc30c20293
@ -283,6 +283,7 @@ fn codegen_fn_content(fx: &mut FunctionCx<'_, '_, impl Backend>) {
|
||||
|
||||
fn trans_stmt<'tcx>(
|
||||
fx: &mut FunctionCx<'_, 'tcx, impl Backend>,
|
||||
#[allow(unused_variables)]
|
||||
cur_block: Block,
|
||||
stmt: &Statement<'tcx>,
|
||||
) {
|
||||
|
@ -124,10 +124,10 @@ impl<'tcx> DebugContext<'tcx> {
|
||||
ty::Uint(_) => primitive(&mut self.dwarf, gimli::DW_ATE_unsigned),
|
||||
ty::Int(_) => primitive(&mut self.dwarf, gimli::DW_ATE_signed),
|
||||
ty::Float(_) => primitive(&mut self.dwarf, gimli::DW_ATE_float),
|
||||
ty::Ref(_, pointee_ty, mutbl)
|
||||
ty::Ref(_, pointee_ty, _mutbl)
|
||||
| ty::RawPtr(ty::TypeAndMut {
|
||||
ty: pointee_ty,
|
||||
mutbl,
|
||||
mutbl: _mutbl,
|
||||
}) => {
|
||||
let type_id = new_entry(&mut self.dwarf, gimli::DW_TAG_pointer_type);
|
||||
|
||||
|
@ -44,6 +44,7 @@ macro intrinsic_match {
|
||||
$(
|
||||
$($($name:tt).*)|+ $(if $cond:expr)?, $(<$($subst:ident),*>)? ($($a:ident $arg:ident),*) $content:block;
|
||||
)*) => {
|
||||
let _ = $substs; // Silence warning when substs is unused.
|
||||
match $intrinsic {
|
||||
$(
|
||||
$(intrinsic_pat!($($name).*))|* $(if $cond)? => {
|
||||
|
@ -17,7 +17,7 @@ pub(super) fn codegen_simd_intrinsic_call<'tcx>(
|
||||
intrinsic_match! {
|
||||
fx, intrinsic, substs, args,
|
||||
_ => {
|
||||
fx.tcx.sess.fatal(&format!("Unknown SIMD intrinsic {}", intrinsic));
|
||||
fx.tcx.sess.span_fatal(span, &format!("Unknown SIMD intrinsic {}", intrinsic));
|
||||
};
|
||||
|
||||
simd_cast, (c a) {
|
||||
@ -104,7 +104,7 @@ pub(super) fn codegen_simd_intrinsic_call<'tcx>(
|
||||
}
|
||||
};
|
||||
|
||||
simd_insert, (c base, o idx, v val) {
|
||||
simd_insert, (c base, o idx, v _val) {
|
||||
let idx_const = if let Some(idx_const) = crate::constant::mir_operand_get_const_val(fx, idx) {
|
||||
idx_const
|
||||
} else {
|
||||
|
@ -155,7 +155,7 @@ impl<'a> OptimizeContext<'a> {
|
||||
|
||||
pub(super) fn optimize_function<T: std::fmt::Debug>(
|
||||
ctx: &mut Context,
|
||||
clif_comments: &mut crate::pretty_clif::CommentWriter,
|
||||
_clif_comments: &mut crate::pretty_clif::CommentWriter,
|
||||
name: T,
|
||||
) {
|
||||
combine_stack_addr_with_load_store(&mut ctx.func);
|
||||
|
Loading…
Reference in New Issue
Block a user