A trustee cannot enforce any claim against the trust property which he purchases after or in contemplation of his appointment as trustee; but he may be allowed by any competent court to charge to the trust property what he has in good faith paid for the claim, upon discharging the same.
SDCL 55-3-12