Merge casevalsimpl and casewild into casesimpl.