From 08a696bfb974d5acfb9eb9cf5de82b94544fac13 Mon Sep 17 00:00:00 2001 From: Niklas Adolfsson Date: Wed, 15 Sep 2021 16:47:27 +0200 Subject: [PATCH] replace `array_impl macro` with const generics --- types/src/traits.rs | 14 +------------- 1 file changed, 1 insertion(+), 13 deletions(-) diff --git a/types/src/traits.rs b/types/src/traits.rs index 2163bd9bf9..9ca34e2f4a 100644 --- a/types/src/traits.rs +++ b/types/src/traits.rs @@ -98,20 +98,8 @@ pub trait ToRpcParams: Serialize { } impl ToRpcParams for &[P] {} - impl ToRpcParams for Vec

{} - -macro_rules! array_impls { - ($($len:tt)+) => { - $( - impl ToRpcParams for [P; $len] {} - )+ - } -} - -array_impls! { - 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 -} +impl ToRpcParams for [P; N] where [P; N]: Serialize {} macro_rules! tuple_impls { ($($len:expr => ($($n:tt $name:ident)+))+) => {