mirror of
https://github.com/vlang/v.git
synced 2023-08-10 21:13:21 +03:00
time: use i64 in unix()
This commit is contained in:
parent
1c847e04c8
commit
eb1ac5b30d
@ -4,7 +4,7 @@
|
|||||||
module time
|
module time
|
||||||
|
|
||||||
// unix returns a time struct from Unix time.
|
// unix returns a time struct from Unix time.
|
||||||
pub fn unix(abs int) Time {
|
pub fn unix(abs i64) Time {
|
||||||
// Split into day and time
|
// Split into day and time
|
||||||
mut day_offset := abs / seconds_per_day
|
mut day_offset := abs / seconds_per_day
|
||||||
if abs % seconds_per_day < 0 {
|
if abs % seconds_per_day < 0 {
|
||||||
|
Loading…
Reference in New Issue
Block a user