diff options
author | Ian Jackson <ian.jackson@eu.citrix.com> | 2011-12-12 17:48:38 +0000 |
---|---|---|
committer | Ian Jackson <ian.jackson@eu.citrix.com> | 2011-12-12 17:48:38 +0000 |
commit | eee7480fdf1e874cc91b73e9646c487b5e02c99a (patch) | |
tree | 23008550e8df7875d0dc68be5966e40d3c2930c4 /tools/libxl/gentest.py | |
parent | 46f6034c3dcd0cf221914574e4528f25804a5857 (diff) | |
download | xen-eee7480fdf1e874cc91b73e9646c487b5e02c99a.tar.gz xen-eee7480fdf1e874cc91b73e9646c487b5e02c99a.tar.bz2 xen-eee7480fdf1e874cc91b73e9646c487b5e02c99a.zip |
libxl: idl: support new "private" type attribute
This provides for fields in libxl datatypes which are only present in
the C version of structures and are used only by libxl itself. This
is useful when a libxl datatype wants to contain fields which are used
by libxl internally and which are only present in the structure to
avoid additional memory allocation inconvenience.
Signed-off-by: Ian Jackson <ian.jackson@eu.citrix.com>
Acked-by: Ian Campbell <ian.campbell@citrix.com>
Committed-by: Ian Jackson <Ian.Jackson@eu.citrix.com>
Diffstat (limited to 'tools/libxl/gentest.py')
-rw-r--r-- | tools/libxl/gentest.py | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/tools/libxl/gentest.py b/tools/libxl/gentest.py index 05e77cce5e..ac7a400060 100644 --- a/tools/libxl/gentest.py +++ b/tools/libxl/gentest.py @@ -56,6 +56,8 @@ def gen_rand_init(ty, v, indent = " ", parent = None): s += "%s = rand() %% 2;\n" % v elif ty.typename in ["char *"]: s += "%s = rand_str();\n" % v + elif ty.private: + pass elif ty.typename in handcoded: raise Exception("Gen for handcoded %s" % ty.typename) else: |