lookup_child_selector (exp->gdbarch, sel));
 }
 
+/* Helper function that implements the body of BINOP_CONCAT.  */
+
+static struct value *
+eval_op_concat (struct type *expect_type, struct expression *exp,
+               enum noside noside,
+               enum exp_opcode op, struct value *arg1, struct value *arg2)
+{
+  if (noside == EVAL_SKIP)
+    return eval_skip_value (exp);
+  if (binop_user_defined_p (op, arg1, arg2))
+    return value_x_binop (arg1, arg2, op, OP_NULL, noside);
+  else
+    return value_concat (arg1, arg2);
+}
+
 struct value *
 evaluate_subexp_standard (struct type *expect_type,
                          struct expression *exp, int *pos,
     case BINOP_CONCAT:
       arg1 = evaluate_subexp_with_coercion (exp, pos, noside);
       arg2 = evaluate_subexp_with_coercion (exp, pos, noside);
-      if (noside == EVAL_SKIP)
-       return eval_skip_value (exp);
-      if (binop_user_defined_p (op, arg1, arg2))
-       return value_x_binop (arg1, arg2, op, OP_NULL, noside);
-      else
-       return value_concat (arg1, arg2);
+      return eval_op_concat (expect_type, exp, noside, op, arg1, arg2);
 
     case BINOP_ASSIGN:
       arg1 = evaluate_subexp (nullptr, exp, pos, noside);