lavina/crates/proto-xmpp/src/lib.rs

38 lines
750 B
Rust
Raw Normal View History

#![feature(
2023-11-20 16:19:12 +00:00
coroutines,
coroutine_trait,
type_alias_impl_trait,
impl_trait_in_assoc_type
)]
2023-03-11 15:07:02 +00:00
pub mod bind;
pub mod client;
2023-03-27 21:45:44 +00:00
pub mod disco;
pub mod muc;
2023-03-12 21:50:28 +00:00
pub mod roster;
pub mod sasl;
2023-03-12 13:15:13 +00:00
pub mod session;
pub mod stanzaerror;
pub mod stream;
pub mod tls;
mod prelude;
pub mod xml;
// Implemented as a macro instead of a fn due to borrowck limitations
macro_rules! skip_text {
($reader: ident, $buf: ident) => {
loop {
use quick_xml::events::Event;
$buf.clear();
let res = $reader.read_event_into_async($buf).await?;
if let Event::Text(_) = res {
continue;
} else {
break res;
}
}
};
}
pub(crate) use skip_text;