anchor.diff:              | Arbitrary(name) -> failwith unsupportedCaseMsg
           | _ -> failwith unexpectedNodeMsg
   
  -    let rec build 
  -            (node: GraphNode) 
  -            (operands: list<FSA<State>>) 
  -            (automata: FSAMap) 
  -            (unionNodes: Map<GraphNode, list<FSAMap>>) =
  -        let processSuccessors node operands automata unionNodes =
  +    let rec build (node: GraphNode) (state: BuildState) =
  +        let processSuccessors node (state: BuildState) =
               ddg.Graph.OutEdges(node)
               |> List.ofSeq
               |> List.map (fun e -> e.Target)
  -            |> List.fold (fun (_, un) succ -> build succ operands automata un) (automata, unionNodes)
  -
  -        let processNodeAndSuccessors (node: GraphNode) operands automata unionNodes =
  -            let operands', automata' = processNodeByType node.Type operands automata
  -            processSuccessors node operands' automata' unionNodes
  +            |> List.fold (fun st succ -> build succ { state with UnionNodes = st.UnionNodes }) state
  +
  +        let processNodeAndSuccessors (node: GraphNode) (state: BuildState) =
  +            let operands', automata' = processNodeByType node.Type state.Operands state.Automata
  +            let state' = { state with Operands = operands'; Automata = automata' }
  +            processSuccessors node state'
   
           let entriesNum = ddg.Graph.InEdges(node) |> List.ofSeq |> List.length
  -        let optTraversedEntries = Map.tryFind node unionNodes
  -        let traversedEntries = automata :: Option.getOrElse optTraversedEntries []
  +        let optTraversedEntries = Map.tryFind node state.UnionNodes
  +        let traversedEntries = state.Automata :: Option.getOrElse optTraversedEntries []
           let traversedNum = List.length traversedEntries
           let allEntriesTraversed =
               entriesNum = 0 ||
  
positive.code:         go (Map.toList a1) a2 Map.empty
  
      let fixpointAchieved (oldFsaMap: FSAMap) (widenedFsaMap: FSAMap) =
          let rec go (oldFsaList: list<string * FSA<State>>) (widenedFsaMap: FSAMap) =
              match oldFsaList with
              | [] -> true
              | (varName, oldFsa) :: tl ->
  
negative.code: //                | None -> 
  //                    // just start processing body
                  failwith unsupportedCaseMsg
              | _ -> processNodeAndSuccessors node state
      
      let finalState = build ddg.Root BuildStateFuncs.empty
      let nfsa = Map.find ddg.VarName finalState.Automata
      nfsa.NfaToDfa
  