packages feed

aihc-parser-1.0.0.2: test/Test/Fixtures/oracle/ViewPatterns/view-pattern-case-alternative.hs

{- ORACLE_TEST pass -}
{-# LANGUAGE ViewPatterns #-}

module ViewPatternCaseAlternative where

anyIdx :: a -> Maybe Int
anyIdx = undefined

f :: [a] -> Int
f x = case x of
  [anyIdx -> Just i] -> i
  _ -> 0