Changes between Version 1 and Version 2 of ViewPatterns
- Timestamp:
- 01/24/07 07:30:14 (6 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
ViewPatterns
v1 v2 257 257 has :: Eq a => a -> Set a -> Maybe (Set a) 258 258 has x (S xs) | x `elem` xs = Just (xs \\ x) 259 | otherwise = Nothing259 | otherwise = Nothing 260 260 261 261 delete :: a -> Set a -> Set a … … 318 318 f (snoc | x xs) = .. -- Use "|" instead of "->" 319 319 g (bits 3 | b bs) = ... 320 321 f ((x,xs) <- snoc) = ... -- More like pattern guards 320 322 }}} 321 323
