ULONGEST elt_size = type_length_units (elt_type);
ULONGEST elt_offs = elt_size * (index - lowerbound);
- if (index < lowerbound || (!TYPE_ARRAY_UPPER_BOUND_IS_UNDEFINED (array_type)
- && elt_offs >= type_length_units (array_type)))
+ if (index < lowerbound
+ || (!TYPE_ARRAY_UPPER_BOUND_IS_UNDEFINED (array_type)
+ && elt_offs >= type_length_units (array_type))
+ || (VALUE_LVAL (array) != lval_memory
+ && TYPE_ARRAY_UPPER_BOUND_IS_UNDEFINED (array_type)))
{
if (type_not_associated (array_type))
error (_("no such vector element (vector not associated)"));
}
throw_error (NOT_FOUND_ERROR,
_("member function %s not found"), tstr);
-#ifdef lint
- return call_function_by_hand (argvec[0], 2 - static_memfuncp, argvec + 1);
-#endif
}
/* We know that arg1 is a structure, so try to find a unary user
}
throw_error (NOT_FOUND_ERROR,
_("member function %s not found"), tstr);
-
- return 0; /* For lint -- never reached */
}
\f
return value_strcmp (arg1, arg2) == 0;
}
else
- {
- error (_("Invalid type combination in equality test."));
- return 0; /* For lint -- never reached. */
- }
+ error (_("Invalid type combination in equality test."));
}
/* Compare values based on their raw contents. Useful for arrays since
|| (TYPE_CODE (type) == TYPE_CODE_ARRAY && TYPE_VECTOR (type)))
return value_from_contents (type, value_contents (arg1));
else
- {
- error (_("Argument to positive operation not a number."));
- return 0; /* For lint -- never reached. */
- }
+ error (_("Argument to positive operation not a number."));
}
struct value *
return val;
}
else
- {
- error (_("Argument to negate operation not a number."));
- return 0; /* For lint -- never reached. */
- }
+ error (_("Argument to negate operation not a number."));
}
struct value *