If a named beneficiary dies before the testator (one who signs a will and gives something to the benficiary under his/her will) sometimes the will considers that and says the beneficiary's gift is to go to the beneficiary's heirs; other times it doesn't and goes back to the testator's estate to be distributed elsewhere. So it really depends on what the will says exactly.
DISCLAIMER: this is not legal advice and should not be relied upon as such.