Remove unused pattern arrays