| 143 | |
| 144 | template <typename T, typename Arg0, typename Arg1> |
| 145 | T Call(KernelContext*, Arg0 arg0, Arg1 arg1, Status*) const { |
| 146 | year_month_day from( |
| 147 | floor<days>(localizer_.template ConvertTimePoint<Duration>(arg0))); |
| 148 | year_month_day to(floor<days>(localizer_.template ConvertTimePoint<Duration>(arg1))); |
| 149 | return static_cast<T>((to.year() - from.year()).count()); |
| 150 | } |
| 151 | |
| 152 | Localizer localizer_; |
| 153 | }; |