Skip to content

Commit 9f399ae

Browse files
committed
factor out duplicated lines that work with CPP
1 parent f691e0e commit 9f399ae

File tree

1 file changed

+2
-7
lines changed

1 file changed

+2
-7
lines changed

src/DFAMin.hs

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -163,21 +163,16 @@ groupEquivStates DFA { dfa_states = statemap }
163163
go r (a:q) = uncurry go $ List.foldl' go0 (a:r,q) xs
164164
where
165165
xs :: [EquivalenceClass]
166-
#if MIN_VERSION_containers(0, 6, 0)
167166
xs =
168167
[ x
169168
| preimageMap <- IM.elems bigmap
169+
#if MIN_VERSION_containers(0, 6, 0)
170170
, let x = IS.unions (IM.restrictKeys preimageMap a)
171-
, not (IS.null x)
172-
]
173171
#else
174-
xs =
175-
[ x
176-
| preimageMap <- IM.elems bigmap
177172
, let x = IS.unions [IM.findWithDefault IS.empty s preimageMap | s <- IS.toList a]
173+
#endif
178174
, not (IS.null x)
179175
]
180-
#endif
181176

182177
refineWith
183178
:: IntSet -- preimage set that bisects the input equivalence class

0 commit comments

Comments
 (0)