Skip to content

Commit

Permalink
Use mkNode in ApplyMerge.DoublyLinkedList
Browse files Browse the repository at this point in the history
  • Loading branch information
pgujjula committed May 9, 2024
1 parent bd2ec52 commit ea5b906
Showing 1 changed file with 2 additions and 9 deletions.
11 changes: 2 additions & 9 deletions src/ApplyMerge/DoublyLinkedList.hs
Original file line number Diff line number Diff line change
Expand Up @@ -51,15 +51,8 @@ initialFrontier ::
initialFrontier f as bs = do
list <- DoublyLinked.empty
position <- DoublyLinked.cons list (0 :: Int, 0 :: Int)
let c = f (NonEmpty.head as) (NonEmpty.head bs)
node =
Node
{ position = position,
value = c,
as = as,
bs = bs
}
pure $ Frontier $ MinPQueue.singleton c node
let node = mkNode f position as bs
pure $ Frontier $ MinPQueue.singleton node.value node

step ::
(Ord c) =>
Expand Down

0 comments on commit ea5b906

Please sign in to comment.