diff options
| author | Laurenz <laurmaedje@gmail.com> | 2022-11-03 11:44:53 +0100 |
|---|---|---|
| committer | Laurenz <laurmaedje@gmail.com> | 2022-11-03 13:35:39 +0100 |
| commit | 37a7afddfaffd44cb9bc013c9506599267e08983 (patch) | |
| tree | 20e7d62d3c5418baff01a21d0406b91bf3096214 /src/model/dict.rs | |
| parent | 56342bd972a13ffe21beaf2b87ab7eb1597704b4 (diff) | |
Split crates
Diffstat (limited to 'src/model/dict.rs')
| -rw-r--r-- | src/model/dict.rs | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/src/model/dict.rs b/src/model/dict.rs index 3e4fd956..49e50aa0 100644 --- a/src/model/dict.rs +++ b/src/model/dict.rs @@ -10,8 +10,9 @@ use crate::syntax::Spanned; use crate::util::ArcExt; /// Create a new [`Dict`] from key-value pairs. -#[allow(unused_macros)] -macro_rules! dict { +#[macro_export] +#[doc(hidden)] +macro_rules! __dict { ($($key:expr => $value:expr),* $(,)?) => {{ #[allow(unused_mut)] let mut map = std::collections::BTreeMap::new(); @@ -20,6 +21,9 @@ macro_rules! dict { }}; } +#[doc(inline)] +pub use crate::__dict as dict; + /// A reference-counted dictionary with value semantics. #[derive(Default, Clone, PartialEq, Hash)] pub struct Dict(Arc<BTreeMap<Str, Value>>); |
