All of lore.kernel.org
 help / color / mirror / Atom feed
From: Nick Rosbrook <rosbrookn@gmail.com>
To: xen-devel@lists.xenproject.org
Cc: george.dunlap@citrix.com, Nick Rosbrook <rosbrookn@ainfosec.com>,
	Ian Jackson <iwj@xenproject.org>, Wei Liu <wl@xen.org>,
	Anthony PERARD <anthony.perard@citrix.com>
Subject: [RFC v2 1/7] libxl: remove extra whitespace from gentypes.py
Date: Tue,  2 Mar 2021 20:46:13 -0500	[thread overview]
Message-ID: <7a75b14f66acac499a0b17ab1c5595549421bac7.1614734296.git.rosbrookn@ainfosec.com> (raw)
In-Reply-To: <cover.1614734296.git.rosbrookn@ainfosec.com>
In-Reply-To: <cover.1614734296.git.rosbrookn@ainfosec.com>

No functional change, just remove the extra whitespace from gentypes.py.

Signed-off-by: Nick Rosbrook <rosbrookn@ainfosec.com>
---
 tools/libs/light/gentypes.py | 14 +++++++-------
 1 file changed, 7 insertions(+), 7 deletions(-)

diff --git a/tools/libs/light/gentypes.py b/tools/libs/light/gentypes.py
index 9a45e45acc..37de0f68b3 100644
--- a/tools/libs/light/gentypes.py
+++ b/tools/libs/light/gentypes.py
@@ -40,7 +40,7 @@ def libxl_C_type_define(ty, indent = ""):
     elif isinstance(ty, idl.Aggregate):
         if isinstance(ty, idl.KeyedUnion):
             s += libxl_C_instance_of(ty.keyvar.type, ty.keyvar.name) + ";\n"
-            
+
         if ty.typename is None:
             s += "%s {\n" % ty.kind
         else:
@@ -48,7 +48,7 @@ def libxl_C_type_define(ty, indent = ""):
 
         for f in ty.fields:
             if isinstance(ty, idl.KeyedUnion) and f.type is None: continue
-            
+
             x = libxl_C_instance_of(f.type, f.name)
             if f.const:
                 x = "const " + x
@@ -164,7 +164,7 @@ def libxl_init_members(ty, nesting = 0):
         return [f for f in ty.fields if not f.const and isinstance(f.type,idl.KeyedUnion)]
     else:
         return []
-    
+
 def libxl_C_type_do_init(ty, pass_arg, need_zero=True, indent="    "):
     s=indent
     if ty.init_val is not None:
@@ -229,20 +229,20 @@ def libxl_C_type_member_init(ty, field):
         raise Exception("Only KeyedUnion is supported for member init")
 
     ku = field.type
-    
+
     s = ""
     s += "void %s(%s, %s)\n" % (ty.init_fn + "_" + ku.keyvar.name,
                                 ty.make_arg("p", passby=idl.PASS_BY_REFERENCE),
                                 ku.keyvar.type.make_arg(ku.keyvar.name))
     s += "{\n"
-    
+
     if ku.keyvar.init_val is not None:
         init_val = ku.keyvar.init_val
     elif ku.keyvar.type.init_val is not None:
         init_val = ku.keyvar.type.init_val
     else:
         init_val = None
-        
+
     (nparent,fexpr) = ty.member(ty.pass_arg("p"), ku.keyvar, isref=True)
     if init_val is not None:
         s += "    assert(%s == %s);\n" % (fexpr, init_val)
@@ -732,7 +732,7 @@ if __name__ == '__main__':
         f.write(libxl_C_type_copy(ty, "dst", "src"))
         f.write("}\n")
         f.write("\n")
-        
+
     for ty in [t for t in types if t.copy_deprecated_fn]:
         f.write("int %s(libxl_ctx *ctx, %s)\n" % (ty.copy_deprecated_fn,
             ty.make_arg("p", passby=idl.PASS_BY_REFERENCE)))
-- 
2.17.1



  reply	other threads:[~2021-03-03  1:46 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-03-03  1:46 [RFC v2 0/7] add function support to IDL Nick Rosbrook
2021-03-03  1:46 ` Nick Rosbrook [this message]
2021-05-04 14:39   ` [RFC v2 1/7] libxl: remove extra whitespace from gentypes.py Anthony PERARD
2021-03-03  1:46 ` [RFC v2 2/7] libxl: add Function class to IDL Nick Rosbrook
2021-03-03  1:46 ` [RFC v2 3/7] libxl: add PASS_BY_CONST_REFERENCE to idl Nick Rosbrook
2021-03-03  1:46 ` [RFC v2 4/7] libxl: add DeviceFunction classes to IDL Nick Rosbrook
2021-03-03  1:46 ` [RFC v2 5/7] libxl: add device function definitions to libxl_types.idl Nick Rosbrook
2021-05-04 15:43   ` Anthony PERARD
2021-05-04 17:26     ` Nick Rosbrook
2021-03-03  1:46 ` [RFC v2 6/7] libxl: implement device add/remove/destroy functions generation Nick Rosbrook
2021-05-04 15:02   ` Anthony PERARD
2021-05-04 17:29     ` Nick Rosbrook
2021-03-03  1:46 ` [RFC v2 7/7] libxl: replace LIBXL_DEFINE_DEVICE* macro usage with generated code Nick Rosbrook
2021-03-03  9:48 ` [RFC v2 0/7] add function support to IDL Ian Jackson
2021-03-03 13:41   ` Nick Rosbrook
2021-04-21 21:28     ` Nick Rosbrook
2021-05-04 15:46 ` Anthony PERARD
2021-05-04 17:31   ` Nick Rosbrook

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=7a75b14f66acac499a0b17ab1c5595549421bac7.1614734296.git.rosbrookn@ainfosec.com \
    --to=rosbrookn@gmail.com \
    --cc=anthony.perard@citrix.com \
    --cc=george.dunlap@citrix.com \
    --cc=iwj@xenproject.org \
    --cc=rosbrookn@ainfosec.com \
    --cc=wl@xen.org \
    --cc=xen-devel@lists.xenproject.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.