summaryrefslogtreecommitdiff
path: root/src/library
diff options
context:
space:
mode:
authorLaurenz <laurmaedje@gmail.com>2020-10-04 20:22:11 +0200
committerLaurenz <laurmaedje@gmail.com>2020-10-04 20:22:11 +0200
commitef8aa763faa59fd62c90c6d6245e8d2c5eece35e (patch)
treed36192af0c770b076a5004ba8bcae3c2df728c75 /src/library
parenta41d7ab47dda1e30465bdf91fd02bca0e634a38d (diff)
Shorten some names ↔
Diffstat (limited to 'src/library')
-rw-r--r--src/library/mod.rs8
1 files changed, 1 insertions, 7 deletions
diff --git a/src/library/mod.rs b/src/library/mod.rs
index c6dfb758..66fc5d59 100644
--- a/src/library/mod.rs
+++ b/src/library/mod.rs
@@ -22,18 +22,12 @@ macro_rules! std {
/// Create a scope with all standard library functions.
pub fn _std() -> Scope {
let mut std = Scope::new();
- $(std.insert($name, wrap!($func));)*
+ $(std.set($name, ValueFunc::new(|args, ctx| Box::pin($func(args, ctx))));)*
std
}
};
}
-macro_rules! wrap {
- ($func:expr) => {
- ValueFunc::new(|args, ctx| Box::pin($func(args, ctx)))
- };
-}
-
std! {
"align" => align,
"box" => boxed,