summaryrefslogtreecommitdiff
path: root/src/model/dict.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/model/dict.rs')
-rw-r--r--src/model/dict.rs8
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>>);