Reviewers: dcarney,
Message:
Committed patchset #1 manually as r17820 (presubmit successful).
Description:
Experimental lexer generator: fix build after jinja2 came along.
[email protected]
BUG=
Committed: https://code.google.com/p/v8/source/detail?r=17820
Please review this at https://codereview.chromium.org/75153003/
SVN Base: https://v8.googlecode.com/svn/branches/experimental/parser
Affected files (+3, -0 lines):
M tools/lexer_generator/code_generator.py
Index: tools/lexer_generator/code_generator.py
diff --git a/tools/lexer_generator/code_generator.py
b/tools/lexer_generator/code_generator.py
index
34f6f5ffa733fb179814b8dd71ae77b7c9a24021..4c6b033540b8425a50c56697c6ccaffb0a10a866
100644
--- a/tools/lexer_generator/code_generator.py
+++ b/tools/lexer_generator/code_generator.py
@@ -27,6 +27,8 @@
from dfa import Dfa
import jinja2
+import os
+import sys
class CodeGenerator:
@@ -50,6 +52,7 @@ class CodeGenerator:
assert(default_action and default_action.match_action())
default_action = default_action.match_action()
+
sys.path.append(os.path.dirname(os.path.dirname(os.path.abspath(__file__))))
template_env = jinja2.Environment(
loader = jinja2.PackageLoader('lexer_generator', '.'),
undefined = jinja2.StrictUndefined)
--
--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev
---
You received this message because you are subscribed to the Google Groups "v8-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.