diff options
| author | Laurenz <laurmaedje@gmail.com> | 2021-01-30 16:19:57 +0100 |
|---|---|---|
| committer | Laurenz <laurmaedje@gmail.com> | 2021-01-30 16:19:57 +0100 |
| commit | 5943f552e512f940d4b76055d51215c23420f03a (patch) | |
| tree | 0e80936f8bda91fb03076b6548bbdace707f74f5 /tests | |
| parent | 67047047e82c564d7701c3505c85db6e34223763 (diff) | |
Capture variable by slot instead of value 🎣
Diffstat (limited to 'tests')
| -rw-r--r-- | tests/typeset.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/tests/typeset.rs b/tests/typeset.rs index cd58bdab..4b9d26a4 100644 --- a/tests/typeset.rs +++ b/tests/typeset.rs @@ -317,8 +317,8 @@ fn register_helpers(scope: &mut Scope, panics: Rc<RefCell<Vec<Panic>>>) { } }; - scope.define("f", ValueFunc::new("f", f)); - scope.define("test", ValueFunc::new("test", test)); + scope.def_const("f", ValueFunc::new("f", f)); + scope.def_const("test", ValueFunc::new("test", test)); } fn print_diag(diag: &Spanned<Diag>, map: &LineMap, lines: u32) { |
