mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-06-13 11:41:04 +00:00
Switch to new proc-macro crate for implementing traits for tuples (#3598)
* Switch to new proc-macro crate for implementing traits for tuples * Switch back to stable `Cargo.lock` format * Reduce tuple number to match rusts default implementation
This commit is contained in:
@@ -266,21 +266,6 @@ pub enum Void {}
|
||||
#[doc(hidden)]
|
||||
pub use serde::{Serialize, Deserialize};
|
||||
|
||||
/// Programatically create derivations for tuples of up to 19 elements. You provide a second macro
|
||||
/// which is called once per tuple size, along with a number of identifiers, one for each element
|
||||
/// of the tuple.
|
||||
#[macro_export]
|
||||
macro_rules! for_each_tuple {
|
||||
($m:ident) => {
|
||||
for_each_tuple! { @IMPL $m !! A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, P, Q, R, S, }
|
||||
};
|
||||
(@IMPL $m:ident !!) => { $m! { } };
|
||||
(@IMPL $m:ident !! $h:ident, $($t:ident,)*) => {
|
||||
$m! { $h $($t)* }
|
||||
for_each_tuple! { @IMPL $m !! $($t,)* }
|
||||
}
|
||||
}
|
||||
|
||||
#[cfg(test)]
|
||||
mod tests {
|
||||
use super::*;
|
||||
|
||||
Reference in New Issue
Block a user