match

abstract fun match(type: T): Boolean

Equivalent to nextIs, but eats the current token if true.