[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-devel] Re: [PATCH V6 1/3] libxl: Introduce libxl_internal_types.idl.
On Thu, 2011-06-30 at 18:30 +0100, Anthony PERARD wrote: > Signed-off-by: Anthony PERARD <anthony.perard@xxxxxxxxxx> > --- > tools/libxl/Makefile | 16 +++++++++------- > tools/libxl/gentypes.py | 15 ++++++++------- > tools/libxl/libxl_internal.h | 1 + > tools/libxl/{libxl.idl => libxl_types.idl} | 0 This is going to need changes to at least tools/python/Makefile and tools/ocaml/libs/xl/Makefile as well. Probably best to split the rename into another patch. [...] > diff --git a/tools/libxl/libxl_types_internal.idl > b/tools/libxl/libxl_types_internal.idl > new file mode 100644 > index 0000000..d993298 > --- /dev/null > +++ b/tools/libxl/libxl_types_internal.idl > @@ -0,0 +1,10 @@ > + > +libxl__qmp_message_type = Enumeration("qmp_message_type", [ > + (1, "QMP"), > + (2, "return"), > + (3, "error"), > + (4, "event"), > + (5, "invalid"), > + ], > + namespace = "libxl__") I wonder if the IDL infrastructure should export a way to set the default namespace? So we'd end up with: default_namespace = "libxl__" libxl__qmp_message_type = Enumeration("...", [....]) libxl__another_internal_type = Struct(...) We could use the same in libxl_types.idl and change the default to be no namespace, making the whole thing a tiny bit more generic. I expect that scoping will require the actual syntax to use the module e.g. libxltypes.default_namespace = "libxl__" or maybe a function call is cleaner libxltypes.default_namespace("libxl__") Ian. _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxxxxxxxx http://lists.xensource.com/xen-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |