block_for_pc (funaddr);
- CHECK_TYPEDEF (val_type);
+ val_type = check_typedef (val_type);
if ((val_type == NULL)
|| (TYPE_CODE(val_type) == TYPE_CODE_ERROR))
return value_zero (builtin_type (exp->gdbarch)->builtin_int,
not_lval);
}
+ else if (TYPE_CODE (ftype) == TYPE_CODE_XMETHOD)
+ {
+ struct type *return_type
+ = result_type_of_xmethod (argvec[0], nargs, argvec + 1);
+
+ if (return_type == NULL)
+ error (_("Xmethod is missing return type."));
+ return value_zero (return_type, not_lval);
+ }
else if (TYPE_GNU_IFUNC (ftype))
return allocate_value (TYPE_TARGET_TYPE (TYPE_TARGET_TYPE (ftype)));
else if (TYPE_TARGET_TYPE (ftype))
/* $5.3.3/2 of the C++ Standard (n3290 draft) says of sizeof:
"When applied to a reference or a reference type, the result is
the size of the referenced type." */
- CHECK_TYPEDEF (type);
+ type = check_typedef (type);
if (exp->language_defn->la_language == language_cplus
&& TYPE_CODE (type) == TYPE_CODE_REF)
type = check_typedef (TYPE_TARGET_TYPE (type));