mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2025-01-13 07:56:17 +01:00
glib-mkenums: Fix parsing of multiline comments
... in glib-mkenums python port. https://bugzilla.gnome.org/show_bug.cgi?id=779332 https://bugzilla.gnome.org/show_bug.cgi?id=783198
This commit is contained in:
parent
69bfd1a771
commit
29f9fe041b
@ -64,7 +64,7 @@ def parse_entries(file, file_name):
|
||||
for line in file:
|
||||
# read lines until we have no open comments
|
||||
while re.search(r'/\*([^*]|\*(?!/))*$', line):
|
||||
line = file.readline()
|
||||
line += file.readline()
|
||||
|
||||
# strip comments w/o options
|
||||
line = re.sub(r'''/\*(?!<)
|
||||
@ -315,7 +315,7 @@ def process_file(curfilename):
|
||||
for line in curfile:
|
||||
# read lines until we have no open comments
|
||||
while re.search(r'/\*([^*]|\*(?!/))*$', line):
|
||||
line = curfile.readline()
|
||||
line += curfile.readline()
|
||||
|
||||
# strip comments w/o options
|
||||
line = re.sub(r'''/\*(?!<)
|
||||
|
Loading…
Reference in New Issue
Block a user