error patter in case statement