quarter calculation by reussandras@gmail.com

git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@36368 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
Richard Frith-MacDonald 2013-03-16 08:23:19 +00:00
parent e2d806f6a3
commit 56fe24c831
2 changed files with 7 additions and 1 deletions

View file

@ -68,7 +68,8 @@ static UCalendarDateFields _NSCalendarUnitToDateField (NSCalendarUnit unit)
// FIXME: Is this right???
return UCAL_DAY_OF_WEEK_IN_MONTH;
// ICU doesn't include a quarter DateField...
if (unit & NSQuarterCalendarUnit)
return (UCAL_MONTH + 2) / 3;
return -1;
}
#endif /* GS_USE_ICU */