Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(49)

Unified Diff: mojo/public/tools/bindings/pylib/mojom/generate/pack.py

Issue 264293003: Adding whether a given field is filling a hole. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: mojo/public/tools/bindings/pylib/mojom/generate/pack.py
diff --git a/mojo/public/tools/bindings/pylib/mojom/generate/pack.py b/mojo/public/tools/bindings/pylib/mojom/generate/pack.py
index 019fe48286edbae8090d97ae13da9fe43437f679..2b2a449cff51c7a8f854f34ca44f43296f3075a3 100644
--- a/mojo/public/tools/bindings/pylib/mojom/generate/pack.py
+++ b/mojo/public/tools/bindings/pylib/mojom/generate/pack.py
@@ -51,6 +51,7 @@ class PackedField(object):
self.size = self.GetSizeForKind(field.kind)
self.offset = None
self.bit = None
+ self.in_hole = False
# Returns the pad necessary to reserve space for alignment of |size|.
@@ -106,6 +107,7 @@ class PackedStruct(object):
# Found hole.
src_field.offset = offset
src_field.bit = bit
+ src_field.in_hole = True
dst_fields.insert(i, src_field)
break
last_field = next_field
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698