Skip to content

Commit

Permalink
export JsonArray and JsonObject
Browse files Browse the repository at this point in the history
  • Loading branch information
samuelcolvin committed Sep 19, 2023
1 parent 0895b8c commit 7afa273
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -16,4 +16,4 @@ pub use lazy_index_map::LazyIndexMap;
pub use number_decoder::{NumberAny, NumberDecoder, NumberDecoderRange, NumberInt};
pub use parse::{Parser, Peak};
pub use string_decoder::{StringDecoder, StringDecoderRange};
pub use value::JsonValue;
pub use value::{JsonArray, JsonObject, JsonValue};
6 changes: 4 additions & 2 deletions src/value.rs
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,11 @@ pub enum JsonValue {
BigInt(BigInt),
Float(f64),
String(String),
Array(Box<SmallVec<[JsonValue; 8]>>),
Object(Box<LazyIndexMap<String, JsonValue>>),
Array(JsonArray),
Object(JsonObject),
}
pub type JsonArray = Box<SmallVec<[JsonValue; 8]>>;
pub type JsonObject = Box<LazyIndexMap<String, JsonValue>>;

#[cfg(feature = "python")]
impl pyo3::ToPyObject for JsonValue {
Expand Down

0 comments on commit 7afa273

Please sign in to comment.