Both examples are fine; whether or not there are any other (recursive) functions, there could be, and that's all that's necessary for the relative clause to be grammatical. Similarly, there are certainly very many boys, and while many of them go to school, restricting it with that clause is still meaningful: you're referring to one of those particular boys.