Skip to content
Commit 9f837416 authored by Vlad Zahorodnii's avatar Vlad Zahorodnii
Browse files

Introduce resource_cast<> helper function

Getting the object associated with the particular wl_resource is not
difficult, but it involves a pretty reasonable amount of boilerplate
code.

This change, introduces a helper function with an intend to reduce the
amount of boilerplate code.

It can be used as resource_cast<const ObjectPrivate *>(resource) or
just simply resource_cast<ObjectPrivate *>(resource).
parent 1c412b0f
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment