Don't be fooled by terrain= in comments.

This commit is contained in:
Eric S. Raymond 2007-05-03 15:35:42 +00:00
parent f57607ded4
commit e752b73b66

View file

@ -613,8 +613,8 @@ if __name__ == '__main__':
for (old, new) in step:
transformed = transformed.replace(old, new)
# Handle terrain_liked=, terrain=, valid_terrain=
spaceless = transformed.replace(" ", "")
if "terrain_liked=" in spaceless or "terrain=" in spaceless:
spaceless = transformed.replace(" ", "").replace("\t", "")
if spaceless and spaceless[0] != "#" and ("terrain_liked=" in spaceless or "terrain=" in spaceless):
(key, pre, value, post) = parse_attribute(transformed)
# We have to cope with the following cases...
# Old style: