summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJohan Dahlin <johan@gnome.org>2010-09-24 18:23:03 -0300
committerJohan Dahlin <johan@gnome.org>2010-09-24 18:25:28 -0300
commit30b06e8bb2c8f8d0d2422e9bad3b94c4aea89f08 (patch)
treeb36d35a379c8db828c0626371550faf65b50ffa4
parent096a5c5f9c0936c3b03a79c35497fb24c57da149 (diff)
downloadgobject-introspection-30b06e8bb2c8f8d0d2422e9bad3b94c4aea89f08.tar.gz
Print out line numbers
But disable the printing by default since it messes up the generated file. And fix a couple of typos
-rw-r--r--giscanner/annotationparser.py10
1 files changed, 7 insertions, 3 deletions
diff --git a/giscanner/annotationparser.py b/giscanner/annotationparser.py
index 673d0a0a..5237a988 100644
--- a/giscanner/annotationparser.py
+++ b/giscanner/annotationparser.py
@@ -136,7 +136,11 @@ class DocBlock(object):
for tag in tags:
lines.append(tag.to_gtk_doc_tag())
- comment = '/**\n'
+ comment = ''
+ #comment += '# %d \"%s\"\n' % (
+ # self.position.line,
+ # self.position.filename)
+ comment += '/**\n'
for line in lines:
line = line.rstrip()
if line:
@@ -323,7 +327,7 @@ class DocTag(object):
n_params=1)
else:
message.warn('invalid annotation option: %s' % (option, ),
- positions=self.position)
+ self.position)
class DocOptions(object):
@@ -540,7 +544,7 @@ class AnnotationParser(object):
tag_name = tag_name.lower()
tag = DocTag(block, tag_name)
tag.value = line[first_colonspace_index+2:]
- tag.filename = block.position.offset(lineno)
+ tag.position = block.position.offset(lineno)
block.tags[tag_name] = tag
else:
comment_lines.append(line)