mirror of
https://github.com/vlang/v.git
synced 2023-08-10 21:13:21 +03:00
time: fix date parsing tests in winter for regions using DST (#7304)
This commit is contained in:
@@ -24,7 +24,7 @@ fn make_unix_time(t C.tm) int {
|
||||
return int(C.timegm(&t))
|
||||
}
|
||||
|
||||
fn to_local_time(t Time) Time {
|
||||
pub fn (t Time) to_local_time() Time {
|
||||
loc_tm := C.tm{}
|
||||
C.localtime_r(time_t(&t.unix), &loc_tm)
|
||||
return convert_ctime(loc_tm, t.microsecond)
|
||||
|
||||
Reference in New Issue
Block a user