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

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

Issue 1515423002: [mojo] Add mojom parser support for native-only structs (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@pickle2
Patch Set: oops Created 5 years 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
Index: mojo/public/tools/bindings/pylib/mojom/generate/module.py
diff --git a/mojo/public/tools/bindings/pylib/mojom/generate/module.py b/mojo/public/tools/bindings/pylib/mojom/generate/module.py
index 8af874fa71ed335be679939450a7535e22a72ee4..dfde609d5fa9b14ddad9ef88822c05820fe71c92 100644
--- a/mojo/public/tools/bindings/pylib/mojom/generate/module.py
+++ b/mojo/public/tools/bindings/pylib/mojom/generate/module.py
@@ -202,6 +202,7 @@ class UnionField(Field): pass
class Struct(ReferenceKind):
ReferenceKind.AddSharedProperty('name')
+ ReferenceKind.AddSharedProperty('native_only')
ReferenceKind.AddSharedProperty('module')
ReferenceKind.AddSharedProperty('imported_from')
ReferenceKind.AddSharedProperty('fields')
@@ -214,6 +215,7 @@ class Struct(ReferenceKind):
spec = None
ReferenceKind.__init__(self, spec)
self.name = name
+ self.native_only = False
self.module = module
self.imported_from = None
self.fields = []
« no previous file with comments | « mojo/public/tools/bindings/pylib/mojom/generate/data.py ('k') | mojo/public/tools/bindings/pylib/mojom/parse/ast.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698