Problem with Nov 21 1997 valops.c:call_function_by_hand change (revisited)

Jim Blandy
Wed May 20 06:58:00 GMT 1998

>> I used value_cast because I wanted to correctly pass arguments to
>> prototyped functions whose formal parameters had small integer types.
>> The present logic in value_arg_coerce always widens everything to an
>> int.  (ANSI C says no promotion should take place, but this isn't a
>> standards issue, it's an ABI issue.)  Do all ABI's really specify that
>> small integer arguments are always passed as int-sized values?
>Would you prefer the following approach to the problem ?

That logic seems to correspond more closely to the rules required,
yes.  It's fine with me.

More information about the Gdb mailing list