HPCC-12206 Avoid function call if no child expression

Signed-off-by: Gavin Halliday <gavin.halliday@lexisnexis.com>