This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [patch 2/3] Implement support for PowerPC BookE ranged watchpoints


> +/* Return true if TYPE is scalar.  */
> +
> +int
> +is_scalar_type (struct type *type)
> +{
> +  CHECK_TYPEDEF (type);
> +
> +  while (TYPE_CODE (type) == TYPE_CODE_REF)
> +    {
> +      type = TYPE_TARGET_TYPE (type);
> +      CHECK_TYPEDEF (type);
> +    }

I suggest you make it explicit how TYPE_CODE_REF types are handled.
In certain cases, I think it might be making a difference (a REF
to a struct might have a different classification than the struct
in terms of argument passing, for instance).

-- 
Joel


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]