how is the above case resolved?
Drafters use three principal devices to resolve problems of potential uncertainty.  1. The beneficiary's eligibility to the trust., 2. The testator has to define  the way in which trustees should exercise their judgement, and 3. To give the trustees the power to give trust property to "anyone in the world" or to "anyone whom the trustees consider appropriate".
Three certainties
Drafters use three principal devices to resolve problems of potential uncertainty. These are:

The first device has been approved by the courts: in "Re Tuck's Settlement Trusts", Lord Denning allowed the court and trustees to engage a Chief Rabbi to determine whether a beneficiary's wife was "of the Jewish faith" which determined the beneficiary's eligibility to the trust. Though this condition was conceptually uncertain, owing to the court's inability to determine with certainty whether someone is of a particular faith, the trust document explicitly set out that a Chief Rabbi could determine it. Lord Denning stating "any conceptual uncertainty" was "cured by the Chief Rabbi clause".

The second device was condemned as ineffective by Jenkins J in "Re Coxen", when he wrote: 
As such, simply giving the trustees this power was not enough to defeat uncertainties. If, however, the testator "had sufficiently defined" the way in which trustees should exercise their judgement, it would be vali
inland revenue commissioners v broadway cottages trust 1955 ch 20 It states that if there are any potential beneficiaries who the trustees are not certain of, or the trustees cannot compile a complete list, the trust is void for uncertainty. what is this three certainties all about? It refers to a rule within English trusts law on the creation of express trusts that, to be valid, the trust instrument must show certainty of intention, subject matter and object. what is the above-mentioned instrument all about? It is an instrument in writing executed by a settlor used to constitute a trust. who is the settlor in this case? He is a trustor, or occasionally, a grantor or donor. who created these certainties? UNANSWERABLE list those three certainties. Certainty of intention", "Certainty of subject matter" and "Certainty of object". what does the first certainty state? To create an express trust without being aware that one is doing so, so long as the court can determine from the person's intention that a beneficial entitlement should be conferred which the law will enforce. what does the second certainty state? It is a requirement that the subject matter be certain — that the property intended to be in the trust be separated from other property, showing clarity in what is intended to be trust property. If there is no clear separation, the trust will fail. what does the third certainty state? There is a requirement that the beneficiaries of a trust, known as the objects, be certain. Within express trusts this is a particularly complex area, because the test used to determine certainty varies between fixed trusts, mere powers and discretionary trusts. what happens in the case of uncertainty? Where there is not sufficient clarity, the trust may be held void as uncertain and give rise to any the three uncertainities i.e."Conceptual uncertainty”, "Evidential uncertainty” and “Ascertainability"
wiki:9190491
Three certainties [SEP] Resolving uncertainties
Drafters use three principal devices to resolve problems of potential uncertainty. These are: The first device has been approved by the courts: in "Re Tuck's Settlement Trusts", Lord Denning allowed the court and trustees to engage a Chief Rabbi to determine whether a beneficiary's wife was "of the Jewish faith" which determined the beneficiary's eligibility to the trust. Though this condition was conceptually uncertain, owing to the court's inability to determine with certainty whether someone is of a particular faith, the trust document explicitly set out that a Chief Rabbi could determine it. Lord Denning stating "any conceptual uncertainty" was "cured by the Chief Rabbi clause".