Changeset 5928 for src/Pugs/Junc.hs
- Timestamp:
- 07/31/05 08:24:37 (3 years ago)
- svk:copy_cache_prev:
- 8084
- Files:
-
- 1 modified
-
src/Pugs/Junc.hs (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
src/Pugs/Junc.hs
r5890 r5928 66 66 sameType (VJunc (MkJunc t' _ _)) = t == t' 67 67 sameType _ = False 68 69 {-|70 Check if the specified value is a 'Pugs.Internals.VJunc' of one of the specified71 junctive types. If it is, return it as a 'Pugs.Internals.VJunc'.72 -}73 juncTypeIs :: Val -- ^ Value to test74 -> [JuncType] -- ^ Types to check against75 -> Maybe VJunc -- ^ Returns 'Nothing' if the test fails76 juncTypeIs v ts77 | (VJunc j) <- v78 , juncType j `elem` ts79 = Just j80 | otherwise81 = Nothing82 68 83 69 {-|
