@Override
    protected void doExecute(ExecutionContext context) {
        FieldValue input = context.getCurrentValue();
        if (input instanceof Array || input instanceof WeightedSet) {
            FieldValue next = new ExecutionConverter(context, expression).convert(input);
            if (next == null)
                next = getOutputType().createFieldValue();
            context.setCurrentValue(next);
        } else if (input instanceof Struct || input instanceof Map) {
            context.setCurrentValue(new ExecutionConverter(context, expression).convert(input));
        } else {
            throw new IllegalArgumentException("Expected Array, Struct, WeightedSet or Map input, got " +
                                               input.getDataType().getName());
        }
    }
Verifies that each struct field is compatible with the expression.
This is symmetric in both verification directions since the expression just need to be compatible with
all the struct fields.
indexinglanguage/src/main/java/com/yahoo/vespa/indexinglanguage/expressions/ForEachExpression.java