es 1.4 compat
add explicit return type to defs except trival ones