events: Put pdu module behind an unstable feature flag

This commit is contained in:
Jonas Platte 2021-09-15 20:31:31 +02:00
parent 36bc8bf73a
commit 1df1256a86
No known key found for this signature in database
GPG Key ID: CC154DE0E30B7C67
4 changed files with 5 additions and 1 deletions

View File

@ -20,6 +20,7 @@ compat = ["ruma-events-macros/compat"]
markdown = ["pulldown-cmark"] markdown = ["pulldown-cmark"]
unstable-exhaustive-types = [] unstable-exhaustive-types = []
unstable-pdu = []
unstable-pre-spec = [] unstable-pre-spec = []
[dependencies] [dependencies]

View File

@ -161,6 +161,8 @@ pub mod forwarded_room_key;
pub mod fully_read; pub mod fully_read;
pub mod ignored_user_list; pub mod ignored_user_list;
pub mod key; pub mod key;
#[cfg(feature = "unstable-pdu")]
#[cfg_attr(docsrs, doc(cfg(feature = "unstable-pdu")))]
pub mod pdu; pub mod pdu;
pub mod policy; pub mod policy;
pub mod presence; pub mod presence;

View File

@ -1,4 +1,4 @@
#![cfg(not(feature = "unstable-pre-spec"))] #![cfg(all(feature = "unstable-pdu", not(feature = "unstable-pre-spec")))]
use std::{collections::BTreeMap, convert::TryInto}; use std::{collections::BTreeMap, convert::TryInto};

View File

@ -34,6 +34,7 @@ tracing = "0.1.26"
criterion = "0.3.3" criterion = "0.3.3"
maplit = "1.0.2" maplit = "1.0.2"
rand = "0.8.3" rand = "0.8.3"
ruma-events = { version = "0.24.5", path = "../ruma-events", features = ["unstable-pdu"] }
tracing-subscriber = "0.2.15" tracing-subscriber = "0.2.15"
[[bench]] [[bench]]