| ... | @@ -113,22 +113,30 @@ pub const Time = extern struct { | ... | @@ -113,22 +113,30 @@ pub const Time = extern struct { |
| 113 | /// 0 - 59 | 113 | /// 0 - 59 |
| 114 | second: u8, | 114 | second: u8, |
| 115 | | 115 | |
| | 116 | _pad1: u8, |
| | 117 | |
| 116 | /// 0 - 999999999 | 118 | /// 0 - 999999999 |
| 117 | nanosecond: u32, | 119 | nanosecond: u32, |
| 118 | | 120 | |
| 119 | /// The time's offset in minutes from UTC. | 121 | /// The time's offset in minutes from UTC. |
| 120 | /// Allowed values are -1440 to 1440 or unspecified_timezone | 122 | /// Allowed values are -1440 to 1440 or unspecified_timezone |
| 121 | timezone: i16, | 123 | timezone: i16, |
| 122 | daylight: packed struct { | 124 | daylight: packed struct(u8) { |
| 123 | _pad1: u6, | | |
| 124 | | | |
| 125 | /// If true, the time has been adjusted for daylight savings time. | 125 | /// If true, the time has been adjusted for daylight savings time. |
| 126 | in_daylight: bool, | 126 | in_daylight: bool, |
| 127 | | 127 | |
| 128 | /// If true, the time is affected by daylight savings time. | 128 | /// If true, the time is affected by daylight savings time. |
| 129 | adjust_daylight: bool, | 129 | adjust_daylight: bool, |
| | 130 | |
| | 131 | _: u6, |
| 130 | }, | 132 | }, |
| 131 | | 133 | |
| | 134 | _pad2: u8, |
| | 135 | |
| | 136 | comptime { |
| | 137 | std.debug.assert(@sizeOf(Time) == 16); |
| | 138 | } |
| | 139 | |
| 132 | /// Time is to be interpreted as local time | 140 | /// Time is to be interpreted as local time |
| 133 | pub const unspecified_timezone: i16 = 0x7ff; | 141 | pub const unspecified_timezone: i16 = 0x7ff; |
| 134 | | 142 | |