Adding type pattern