[PATCH 1/2] Clarify the enum argument type
Bill Spitzak
spitzak at gmail.com
Thu Oct 1 13:43:08 PDT 2015
On Thu, Oct 1, 2015 at 12:09 PM, Nils Chr. Brause <nilschrbrause at gmail.com>
wrote:
> On Thu, Oct 1, 2015 at 9:00 PM, Bill Spitzak <spitzak at gmail.com> wrote:
> >
> >
> > On Thu, Oct 1, 2015 at 8:09 AM, Nils Chr. Brause <
> nilschrbrause at gmail.com>
> > wrote:
> >>
> >> Hi,
> >>
> >> I would recommend to also include the name of the interface, where the
> >> enum is defined, in the enum attribute, e.g:
> >> <arg name="format" type="uint" enum="wl_shm.format"/>
> >
> >
> > I believe popular opinion was that a "local" enum, belonging to the same
> > object as the message or event, should not require this prefix. One big
> > reason is so that the object can be renamed without having to edit it's
> > contents.
> >
> > And currently only such "local" enums are being used in the protocols, so
> > there is no need for parsers to support any such prefix yet, and no need
> to
> > figure out it's rules. Whether the ability to get enums from other
> objects,
> > or from some global space, does not have to be decided yet.
>
> There are "non-local" enums, e.g.
> wl_surface::set_buffer_transform::transform uses the enum
> wl_output::transform, or am I missing something important here?
>
It looks like you are right. Not sure what was done, I have not looked at
it for a long time now. However whatever is in the patch seems to work and
I would use that.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freedesktop.org/archives/wayland-devel/attachments/20151001/1bf85ce7/attachment-0001.html>
More information about the wayland-devel
mailing list