(y)
| 15866 | } |
| 15867 | |
| 15868 | function createUTCDate (y) { |
| 15869 | var date; |
| 15870 | // the Date.UTC function remaps years 0-99 to 1900-1999 |
| 15871 | if (y < 100 && y >= 0) { |
| 15872 | var args = Array.prototype.slice.call(arguments); |
| 15873 | // preserve leap years using a full 400 year cycle, then reset |
| 15874 | args[0] = y + 400; |
| 15875 | date = new Date(Date.UTC.apply(null, args)); |
| 15876 | if (isFinite(date.getUTCFullYear())) { |
| 15877 | date.setUTCFullYear(y); |
| 15878 | } |
| 15879 | } else { |
| 15880 | date = new Date(Date.UTC.apply(null, arguments)); |
| 15881 | } |
| 15882 | |
| 15883 | return date; |
| 15884 | } |
| 15885 | |
| 15886 | // start-of-first-week - start-of-year |
| 15887 | function firstWeekOffset(year, dow, doy) { |
no outgoing calls
no test coverage detected