Change implementation of intersectBy
|Reported by:||daniel.is.fischer||Owned by:|
|Type of failure:||None/Unknown||Difficulty:|
|Test Case:||Blocked By:|
Currently, intersectBy eq xs  takes O(length xs) time to calculate and returns _|_ on (x : _|_). The proposed change,
intersectBy :: (a -> a -> Bool) -> [a] -> [a] -> [a] intersectBy _  _ =  intersectBy _ _  =  intersectBy eq xs ys = [x | x <- xs, any (eq x) ys]
makes this an O(1) operation and returns  for infinite or partial (... : _|_) lists xs. The first equation is necessary to retain intersectBy _  _|_ = .