void::Void?
#2812
Replies: 2 comments 1 reply
-
Both of them are crates that you can depend on if you really need to name the type! The crates are:
But it is usually not necessary to name these types. Can you give more context on what you are actually trying to do? |
Beta Was this translation helpful? Give feedback.
0 replies
-
basically I want to create a trait that defines a function that accepts an event as a parameter |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
So, I got the type for event error which seems to be "
libp2p_swarm::SwarmEvent<blink_impl::behavior::BehaviourEvent, libp2p_core::either::EitherError<libp2p_core::either::EitherError<libp2p_core::either::EitherError<libp2p_core::either::EitherError<libp2p_core::either::EitherError<libp2p_gossipsub::error::GossipsubHandlerError, std::io::error::Error>, std::io::error::Error>, either::Either<libp2p_swarm::handler::ConnectionHandlerUpgrErr<libp2p_core::either::EitherError<libp2p_relay::v2::protocol::inbound_hop::FatalUpgradeError, libp2p_relay::v2::protocol::outbound_stop::FatalUpgradeError>>, void::Void>>, void::Void>, libp2p_ping::handler::Failure>>"
I cannot find out what should I use in place of void::Void, or what is either::Either
Since I want to specify the type in a function signature.
Can you guys help me to figure this out?
Thanks.
Beta Was this translation helpful? Give feedback.
All reactions