From 0f7c70fd93db23ec866ae13aa2f146b7787afabf Mon Sep 17 00:00:00 2001 From: Laurenz Date: Sun, 4 Oct 2020 19:06:20 +0200 Subject: =?UTF-8?q?Separate=20state=20and=20constraints=20=F0=9F=A7=B6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/eval/value.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/eval/value.rs') diff --git a/src/eval/value.rs b/src/eval/value.rs index f6c1fcd7..f88c0704 100644 --- a/src/eval/value.rs +++ b/src/eval/value.rs @@ -12,7 +12,7 @@ use crate::geom::Linear; use crate::layout::{Command, Commands, Dir, LayoutContext, SpecAlign}; use crate::paper::Paper; use crate::syntax::{Ident, Span, SpanWith, Spanned, SynNode, SynTree}; -use crate::{DynFuture, Feedback, Pass}; +use crate::{DynFuture, Feedback}; /// A computational value. #[derive(Clone, PartialEq)] @@ -149,13 +149,13 @@ impl Debug for Value { pub struct FuncValue(pub Rc); /// The signature of executable functions. -type FuncType = dyn Fn(Span, DictValue, LayoutContext<'_>) -> DynFuture>; +type FuncType = dyn Fn(DictValue, &mut LayoutContext) -> DynFuture; impl FuncValue { /// Create a new function value from a rust function or closure. pub fn new(f: F) -> Self where - F: Fn(Span, DictValue, LayoutContext<'_>) -> DynFuture>, + F: Fn(DictValue, &mut LayoutContext) -> DynFuture, { Self(Rc::new(f)) } -- cgit v1.2.3