The teacher will call on whoever answers the question.

Noun clause: who ever answers the question, the teacher will call,will call on who ever.



Function of clause object of preposition, subject, predicate noun, direct object