Support simd_json (#105)
This PR adds support for the simd-json library whenever decoding or encoding JSON responses. This may be enabled independently of serenity and twilight support for SIMD acceleration. Co-authored-by: Kyle Simpson <kyleandrew.simpson@gmail.com>
This commit is contained in:
committed by
Kyle Simpson
parent
8cc7a22b0b
commit
cb0a74f511
@@ -107,6 +107,12 @@ pub use serenity_voice_model as model;
|
||||
#[cfg(feature = "driver")]
|
||||
pub use typemap_rev as typemap;
|
||||
|
||||
// Re-export serde-json APIs locally to minimise conditional config elsewhere.
|
||||
#[cfg(not(feature = "simd-json"))]
|
||||
pub(crate) use serde_json as json;
|
||||
#[cfg(feature = "simd-json")]
|
||||
pub(crate) use simd_json::serde as json;
|
||||
|
||||
#[cfg(feature = "driver")]
|
||||
pub use crate::{
|
||||
driver::Driver,
|
||||
|
||||
Reference in New Issue
Block a user