It is sometimes possible to apply to HMRC for clearance before or after a transaction to provide reassurance on the planning to be undertaken.
It is often a great value to understand how HMRC will view certain transactions or valuations so that you can arrange your affairs robustly rather than paying the price later.