* src/DateParser.py: handle non-matching dates as strings properly
svn: r5269
This commit is contained in:
parent
2b60db6940
commit
278b7751ba
@ -1,3 +1,6 @@
|
||||
2005-10-04 Don Allingham <don@gramps-project.org>
|
||||
* src/DateParser.py: handle non-matching dates as strings properly
|
||||
|
||||
2005-10-04 Stefan Bjork <skalman@acc.umu.se>
|
||||
* src/dates/Date_sv.py: Fixes. No differences from english version
|
||||
on test data.
|
||||
|
@ -550,6 +550,7 @@ class DateParser:
|
||||
|
||||
(text,cal) = self.match_calendar(text,cal)
|
||||
(text,qual) = self.match_quality(text,qual)
|
||||
|
||||
if self.match_span(text,cal,qual,date):
|
||||
return
|
||||
if self.match_range(text,cal,qual,date):
|
||||
@ -559,9 +560,11 @@ class DateParser:
|
||||
if self.match_modifier(text,cal,qual,bc,date):
|
||||
return
|
||||
|
||||
|
||||
try:
|
||||
subdate = self._parse_subdate(text,self.parser[cal])
|
||||
if subdate == Date.EMPTY and text != "":
|
||||
date.set_as_text(text)
|
||||
return
|
||||
except:
|
||||
date.set_as_text(text)
|
||||
return
|
||||
|
Loading…
x
Reference in New Issue
Block a user