Skip to content

Commit 94a9159

Browse files
committed
glib: Remove unnecessary forwarding of attributes in glib::wrapper! for BoxedInline
1 parent 9e7db4b commit 94a9159

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

glib/src/boxed_inline.rs

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ macro_rules! glib_boxed_inline_wrapper {
2929
impl $(<$($generic $(: $bound $(+ $bound2)*)?),+>)? std::marker::Copy for $name $(<$($generic),+>)? {}
3030

3131
$crate::glib_boxed_inline_wrapper!(
32-
@generic_impl [$($attr)*] $name $(<$($generic $(: $bound $(+ $bound2)*)?),+>)?, $ffi_name,
32+
@generic_impl $name $(<$($generic $(: $bound $(+ $bound2)*)?),+>)?, $ffi_name,
3333
@copy ptr unsafe { let copy = $crate::ffi::g_malloc(std::mem::size_of::<$ffi_name>()) as *mut $ffi_name; std::ptr::copy_nonoverlapping(ptr, copy, 1); copy },
3434
@free ptr unsafe { $crate::ffi::g_free(ptr as *mut _); },
3535
@init _ptr (), @copy_into dest src std::ptr::copy_nonoverlapping(src, dest, 1), @clear _ptr ()
@@ -61,7 +61,7 @@ macro_rules! glib_boxed_inline_wrapper {
6161
impl $(<$($generic $(: $bound $(+ $bound2)*)?),+>)? std::marker::Copy for $name $(<$($generic),+>)? {}
6262

6363
$crate::glib_boxed_inline_wrapper!(
64-
@generic_impl [$($attr)*] $name $(<$($generic $(: $bound $(+ $bound2)*)?),+>)?, $ffi_name,
64+
@generic_impl $name $(<$($generic $(: $bound $(+ $bound2)*)?),+>)?, $ffi_name,
6565
@copy $copy_arg $copy_expr, @free $free_arg $free_expr,
6666
@init _ptr (), @copy_into dest src std::ptr::copy_nonoverlapping(src, dest, 1), @clear _ptr ()
6767
);
@@ -99,7 +99,7 @@ macro_rules! glib_boxed_inline_wrapper {
9999
}
100100

101101
$crate::glib_boxed_inline_wrapper!(
102-
@generic_impl [$($attr)*] $name $(<$($generic $(: $bound $(+ $bound2)*)?),+>)?, $ffi_name,
102+
@generic_impl $name $(<$($generic $(: $bound $(+ $bound2)*)?),+>)?, $ffi_name,
103103
@copy ptr unsafe { let copy = $crate::ffi::g_malloc(std::mem::size_of::<$ffi_name>()) as *mut $ffi_name; let c = |$copy_into_arg_dest, $copy_into_arg_src| $copy_into_expr; c(copy, ptr); copy },
104104
@free ptr unsafe { let c = |$clear_arg| $clear_expr; c(ptr); $crate::ffi::g_free(ptr as *mut _); },
105105
@init $init_arg $init_expr, @copy_into $copy_into_arg_dest $copy_into_arg_src $copy_into_expr, @clear $clear_arg $clear_expr
@@ -140,15 +140,15 @@ macro_rules! glib_boxed_inline_wrapper {
140140
}
141141

142142
$crate::glib_boxed_inline_wrapper!(
143-
@generic_impl [$($attr)*] $name $(<$($generic $(: $bound $(+ $bound2)*)?),+>)?, $ffi_name,
143+
@generic_impl $name $(<$($generic $(: $bound $(+ $bound2)*)?),+>)?, $ffi_name,
144144
@copy $copy_arg $copy_expr, @free $free_arg $free_expr,
145145
@init $init_arg $init_expr, @copy_into $copy_into_arg_dest $copy_into_arg_src $copy_into_expr, @clear $clear_arg $clear_expr
146146
);
147147

148148
$crate::glib_boxed_inline_wrapper!(@value_impl $name $(<$($generic $(: $bound $(+ $bound2)*)?),+>)?, $ffi_name $(, @type_ $get_type_expr)?);
149149
};
150150

151-
(@generic_impl [$($attr:meta)*] $name:ident $(<$($generic:ident $(: $bound:tt $(+ $bound2:tt)*)?),+>)?, $ffi_name:ty,
151+
(@generic_impl $name:ident $(<$($generic:ident $(: $bound:tt $(+ $bound2:tt)*)?),+>)?, $ffi_name:ty,
152152
@copy $copy_arg:ident $copy_expr:expr, @free $free_arg:ident $free_expr:expr,
153153
@init $init_arg:ident $init_expr:expr, @copy_into $copy_into_arg_dest:ident $copy_into_arg_src:ident $copy_into_expr:expr, @clear $clear_arg:ident $clear_expr:expr) => {
154154

0 commit comments

Comments
 (0)