From 4b1365729b58eb5ac10ba7cff0f6259fb812e895 Mon Sep 17 00:00:00 2001 From: Rob Rix Date: Fri, 4 Aug 2017 10:08:50 -0400 Subject: [PATCH] Strictify state fields. --- src/Data/Syntax/Assignment.hs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/Data/Syntax/Assignment.hs b/src/Data/Syntax/Assignment.hs index 08ee991b3..ca80b94ce 100644 --- a/src/Data/Syntax/Assignment.hs +++ b/src/Data/Syntax/Assignment.hs @@ -312,10 +312,10 @@ runAssignment toNode source = (\ assignment state -> disamb Left (Right . minimu -- | State kept while running 'Assignment's. data State ast grammar = State - { stateOffset :: Int -- ^ The offset into the Source thus far reached, measured in bytes. - , statePos :: Info.Pos -- ^ The (1-indexed) line/column position in the Source thus far reached. - , stateErrorCounter :: Int -- ^ Monotonic counter tracking the number of error handlers invoked. - , stateNodes :: [ast] -- ^ The remaining nodes to assign. Note that 'children' rules recur into subterms, and thus this does not necessarily reflect all of the terms remaining to be assigned in the overall algorithm, only those “in scope.” + { stateOffset :: !Int -- ^ The offset into the Source thus far reached, measured in bytes. + , statePos :: !Info.Pos -- ^ The (1-indexed) line/column position in the Source thus far reached. + , stateErrorCounter :: !Int -- ^ Monotonic counter tracking the number of error handlers invoked. + , stateNodes :: ![ast] -- ^ The remaining nodes to assign. Note that 'children' rules recur into subterms, and thus this does not necessarily reflect all of the terms remaining to be assigned in the overall algorithm, only those “in scope.” } deriving (Eq, Show)