Preparation for sharing

- rustfmt
- clippy
- comments
- README
This commit is contained in:
2023-05-25 19:14:24 +01:00
parent e99ade92ba
commit bc2714aad8
144 changed files with 3734 additions and 3243 deletions

View File

@@ -1,13 +1,16 @@
#[allow(unused)] // for the doc comments
use crate::foreign::Atomic;
/// A macro that generates the straightforward, syntactically invariant part of implementing
/// [Atomic]. Implemented fns are [Atomic::as_any], [Atomic::definitely_eq] and [Atomic::hash].
///
/// A macro that generates the straightforward, syntactically invariant part of
/// implementing [Atomic]. Implemented fns are [Atomic::as_any],
/// [Atomic::definitely_eq] and [Atomic::hash].
///
/// It depends on [Eq] and [Hash]
#[macro_export]
macro_rules! atomic_defaults {
() => {
fn as_any(&self) -> &dyn std::any::Any { self }
fn as_any(&self) -> &dyn std::any::Any {
self
}
};
}
}