src/Date.cpp
/*!
    Returns \c true if the specified \a year is a leap year; otherwise
    returns \c false.
*/
Returns \c true if the specified \a year is a leap year; otherwise
returns \c false.
Returns \ c true if the specified \ a year is a leap year ; otherwise returns \ c false .
bool Date::isLeapYear(int y)
{
    if (y < 1)
        ++y;
    return (y % 4 == 0 && y % 100 != 0) || y % 400 == 0;
}
bool Date :: isLeapYear ( int y ) { if ( y < 1 ) ++ y ; return ( y % 4 == 0 && y % 100 != 0 ) || y % 400 == 0 ; }
Returns \c true if the specified \a year is a leap year; otherwise
returns \c false.
Returns \ c true if the specified \ a year is a leap year ; otherwise returns \ c false .
// No year 0 in Gregorian calendar, so -1, -5, -9 etc are leap years