(self, res, value_repr, hms)
| 1038 | return hms_idx |
| 1039 | |
| 1040 | def _assign_hms(self, res, value_repr, hms): |
| 1041 | # See GH issue #427, fixing float rounding |
| 1042 | value = self._to_decimal(value_repr) |
| 1043 | |
| 1044 | if hms == 0: |
| 1045 | # Hour |
| 1046 | res.hour = int(value) |
| 1047 | if value % 1: |
| 1048 | res.minute = int(60*(value % 1)) |
| 1049 | |
| 1050 | elif hms == 1: |
| 1051 | (res.minute, res.second) = self._parse_min_sec(value) |
| 1052 | |
| 1053 | elif hms == 2: |
| 1054 | (res.second, res.microsecond) = self._parsems(value_repr) |
| 1055 | |
| 1056 | def _could_be_tzname(self, hour, tzname, tzoffset, token): |
| 1057 | return (hour is not None and |
no test coverage detected