It is a dynamic error if the match pattern matches anything other than an element node and the value of the position option is "first-child" or "last-child".