Cleaned up match verification code

Made it possible to remove type specification