Index: mojo/public/tools/bindings/pylib/mojom/parse/lexer.py |
diff --git a/mojo/public/tools/bindings/pylib/mojom/parse/lexer.py b/mojo/public/tools/bindings/pylib/mojom/parse/lexer.py |
index 28e86eccc235c7617138af0af1d73a84ff80ae96..f4769e73737eaa2b9a874da6847f9a24c4367462 100644 |
--- a/mojo/public/tools/bindings/pylib/mojom/parse/lexer.py |
+++ b/mojo/public/tools/bindings/pylib/mojom/parse/lexer.py |
@@ -279,8 +279,8 @@ class Lexer(object): |
# Ignore C and C++ style comments |
def t_COMMENT(self, t): |
r'(/\*(.|\n)*?\*/)|(//.*(\n[ \t]*//.*)*)' |
- pass |
+ t.lexer.lineno += t.value.count("\n") |
def t_error(self, t): |
- msg = 'Illegal character %s' % repr(t.value[0]) |
+ msg = "Illegal character %s" % repr(t.value[0]) |
self._error(msg, t) |