Replace non-template getSubField with template version when PVField is of a known, derived type.
As per #34,but only do for derived classes. Avoid getSubField<PVField> as the dynamic_pointer_cast is not (as you might think) a null op. Especially avoid in the offset version as this can lead to several unnecessary pointer casts (see discussion in #34). In #34 there are sometimes more appropriate types for the template argument so use these.
Replace non-template getSubField with template version when PVField is of a known, derived type.
As per #34,but only do for derived classes. Avoid getSubField<PVField> as the dynamic_pointer_cast is not (as you might think) a null op. Especially avoid in the offset version as this can lead to several unnecessary pointer casts (see discussion in #34). In #34 there are sometimes more appropriate types for the template argument so use these.