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

Unified Diff: mojo/public/bindings/mojo_idl.py

Issue 65933002: Mojo: Unify the disparate source and header files into 3 (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Mistaken /n's Created 7 years, 1 month 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/bindings/mojo_idl.py
diff --git a/mojo/public/bindings/mojo_idl.py b/mojo/public/bindings/mojo_idl.py
index 4f149bc5fd34f6da65760009aaaafa9153bc5d06..567adf7113c414e78c71ad893e54d5e3df427124 100755
--- a/mojo/public/bindings/mojo_idl.py
+++ b/mojo/public/bindings/mojo_idl.py
@@ -6,6 +6,7 @@
"""The frontend for the Mojo bindings system."""
+import os
import sys
from optparse import OptionParser
from parser import mojo_parser
@@ -27,10 +28,11 @@ def Main():
sys.exit(1)
for filename in args:
+ name = os.path.splitext(os.path.basename(filename))[0]
# TODO(darin): There's clearly too many layers of translation here! We can
# at least avoid generating the serialized Mojom IR.
tree = mojo_parser.Parse(filename)
- mojom = mojo_translate.Translate(tree)
+ mojom = mojo_translate.Translate(tree, name)
module = mojom_data.ModuleFromData(mojom)
cpp = mojom_cpp_generator.CPPGenerator(
module, options.include_dir, options.output_dir)
« no previous file with comments | « mojo/public/bindings/generators/mojom_cpp_generator.py ('k') | mojo/public/bindings/parser/mojo_translate.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698