diff options
author | Sayamindu Dasgupta <sayamindu@gmail.com> | 2009-02-24 17:50:30 (GMT) |
---|---|---|
committer | Sayamindu Dasgupta <sayamindu@gmail.com> | 2009-02-24 17:50:30 (GMT) |
commit | 95cc52a7b3851b0804ab2d65484eb4ed8ab5d04d (patch) | |
tree | 493f4664bd3458c17e30a7815eae5a64fe2b184c | |
parent | 8f2f254589d7f3a6c09cbfd10c29b74ffa3fdfb1 (diff) |
More generic version of the previous patch, after discussion with upstream
-rw-r--r-- | translate-toolkit-1.3.0/translate/storage/poparser.py | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/translate-toolkit-1.3.0/translate/storage/poparser.py b/translate-toolkit-1.3.0/translate/storage/poparser.py index 958a3fc..ab7604e 100644 --- a/translate-toolkit-1.3.0/translate/storage/poparser.py +++ b/translate-toolkit-1.3.0/translate/storage/poparser.py @@ -99,9 +99,7 @@ def parse_comment(parse_state, unit): next_line = parse_state.next_line if len(next_line) > 0 and next_line[0] == '#': next_char = next_line[1] - if isspace(next_char): - append(unit.othercomments, parse_state.decode(next_line)) - elif next_char == '.': + if next_char == '.': append(unit.automaticcomments, parse_state.decode(next_line)) elif next_char == '|': # Read all the lines starting with #| @@ -124,7 +122,7 @@ def parse_comment(parse_state, unit): # elsewhere to ensure we reuse the normal unit parsing code return None else: - return None + append(unit.othercomments, parse_state.decode(next_line)) return parse_state.read_line() else: return None |