- Sort Score
- Result 10 results
- Languages All
Results 1 - 2 of 2 for Nanosecond (0.04 sec)
-
src/archive/tar/strconv_test.go
} } if ok && !ts.Equal(v.want) { t.Errorf("parsePAXTime(%q): got (%ds %dns), want (%ds %dns)", v.in, ts.Unix(), ts.Nanosecond(), v.want.Unix(), v.want.Nanosecond()) } } } func TestFormatPAXTime(t *testing.T) { vectors := []struct { sec, nsec int64 want string }{ {1350244992, 0, "1350244992"},
Registered: Tue Sep 09 11:13:09 UTC 2025 - Last Modified: Mon Sep 08 17:08:20 UTC 2025 - 15K bytes - Viewed (0) -
src/archive/tar/strconv.go
// formatPAXTime converts ts into a time of the form %d.%d as described in the // PAX specification. This function is capable of negative timestamps. func formatPAXTime(ts time.Time) (s string) { secs, nsecs := ts.Unix(), ts.Nanosecond() if nsecs == 0 { return strconv.FormatInt(secs, 10) } // If seconds is negative, then perform correction. sign := "" if secs < 0 { sign = "-" // Remember sign
Registered: Tue Sep 09 11:13:09 UTC 2025 - Last Modified: Mon Sep 08 17:08:20 UTC 2025 - 9.1K bytes - Viewed (0)