Intelligent people may have less need for religious beliefs and practices, as some of the functions of religiosity can be given by intelligence instead. Such functions include the presentation of a sense that the world is orderly and predictable, a sense of personal control and self-regulation and a sense of enhancing self-esteem and belongingness.
By "losing out on such education," those children would have a higher probability of developing intelligence.