Make rustfmt in CI happy

This commit is contained in:
Víctor Manuel Jáquez Leal 2018-11-23 15:27:48 +01:00
parent 8eb4b879fc
commit ec8727c3ca

View file

@ -438,9 +438,8 @@ impl<O: IsA<Pad>> PadExtManual for O {
{
#[cfg_attr(feature = "cargo-clippy", allow(type_complexity))]
unsafe {
let func_box: Box<
Fn(&Pad, &Option<::Object>) -> bool + Send + Sync + 'static,
> = Box::new(func);
let func_box: Box<Fn(&Pad, &Option<::Object>) -> bool + Send + Sync + 'static> =
Box::new(func);
ffi::gst_pad_set_activate_function_full(
self.to_glib_none().0,
Some(trampoline_activate_function),
@ -1031,10 +1030,8 @@ unsafe extern "C" fn trampoline_activatemode_function(
active: glib_ffi::gboolean,
) -> glib_ffi::gboolean {
#[cfg_attr(feature = "cargo-clippy", allow(transmute_ptr_to_ref))]
let func: &&(Fn(&Pad, &Option<::Object>, ::PadMode, bool) -> bool
+ Send
+ Sync
+ 'static) = transmute((*pad).activatemodedata);
let func: &&(Fn(&Pad, &Option<::Object>, ::PadMode, bool) -> bool + Send + Sync + 'static) =
transmute((*pad).activatemodedata);
func(
&from_glib_borrow(pad),
@ -1106,10 +1103,8 @@ unsafe extern "C" fn trampoline_event_full_function(
event: *mut ffi::GstEvent,
) -> ffi::GstFlowReturn {
#[cfg_attr(feature = "cargo-clippy", allow(transmute_ptr_to_ref))]
let func: &&(Fn(&Pad, &Option<::Object>, ::Event) -> ::FlowReturn
+ Send
+ Sync
+ 'static) = transmute((*pad).eventdata);
let func: &&(Fn(&Pad, &Option<::Object>, ::Event) -> ::FlowReturn + Send + Sync + 'static) =
transmute((*pad).eventdata);
func(
&from_glib_borrow(pad),
@ -1187,10 +1182,8 @@ unsafe extern "C" fn trampoline_query_function(
query: *mut ffi::GstQuery,
) -> glib_ffi::gboolean {
#[cfg_attr(feature = "cargo-clippy", allow(transmute_ptr_to_ref))]
let func: &&(Fn(&Pad, &Option<::Object>, &mut ::QueryRef) -> bool
+ Send
+ Sync
+ 'static) = transmute((*pad).querydata);
let func: &&(Fn(&Pad, &Option<::Object>, &mut ::QueryRef) -> bool + Send + Sync + 'static) =
transmute((*pad).querydata);
func(
&from_glib_borrow(pad),