CurryInfo: icurry-3.2.0 / ICurry.Interpreter.addTGState

definition:
addTGState :: ICOptions -> State -> [TG.State] -> [TG.State]
addTGState icopts st states
  | optTermGraph icopts = case (tasks st) of
    -- also return state when only IReturn is currently in Tasks IBlock?
    -- or always return state and only append it in runWith if it changed
    tsk : _ -> if (not (null states)) && ((nstate) == (last states))
                then states
                else states ++ [nstate]
      where nstate = TG.State rgraph (currentNodeOfTask tsk) (results st) (fp tsk)
    []      -> states ++ [ TG.State rgraph 0 (results st) [] ]
  | otherwise = states
 where rgraph = reachableGraph (graph st) [graphRoot (graph st)]
       fp (Task _ _ fingerprint) = fingerprint
demand:
arguments 1 3
deterministic:
deterministic operation
failfree:
(_, _, {:})
indeterministic:
referentially transparent operation
infix:
no fixity defined
iotype:
{(_,_,_) |-> _}
name:
addTGState
precedence:
no precedence defined
result-values:
_
signature:
ICurry.Options.ICOptions -> State -> [TermGraph.XML.State]
-> [TermGraph.XML.State]
solution-complete:
operation might suspend on free variables
terminating:
possibly non-terminating
totally-defined:
possibly non-reducible on same data term