Type safety of protocol calls

Kristian Høgsberg krh at bitplanet.net
Sun Feb 6 09:32:45 PST 2011


On Sun, Feb 6, 2011 at 11:57 AM, Chris Morgan <chmorgan at gmail.com> wrote:
> Hello.
>
> I ran into an issue figuring out how a resize event made it's way from
> window.c in the client to shell.c on the server. I think I figured out
> the mapping and sent a patch that performs the mapping between the two
> different types being used.

I saw the patch, but the window.h #defines are defined to match the
protocol enumeration where they overlap for convenience.  That's
perfectly legal in C, safe and convenient.. You may not like that
technique, but claiming that the protocol isn't typesafe for this
reason is a little disingenuous.

Kristian


More information about the wayland-devel mailing list