mirror of
https://github.com/vlang/v.git
synced 2023-08-10 21:13:21 +03:00
fmt: add a space around single-line unsafe expressions (#7505)
This commit is contained in:
@@ -66,8 +66,8 @@ fn parse_iso8601_time(s string) ?(int, int, int, int, i64, bool) {
|
|||||||
plus_min_z := `a`
|
plus_min_z := `a`
|
||||||
offset_hour := 0
|
offset_hour := 0
|
||||||
offset_minute := 0
|
offset_minute := 0
|
||||||
mut count := unsafe {C.sscanf(charptr(s.str), '%2d:%2d:%2d.%6d%c%2d:%2d', &hour, &minute,
|
mut count := unsafe { C.sscanf(charptr(s.str), '%2d:%2d:%2d.%6d%c%2d:%2d', &hour,
|
||||||
&second, µsecond, charptr(&plus_min_z), &offset_hour, &offset_minute)}
|
&minute, &second, µsecond, charptr(&plus_min_z), &offset_hour, &offset_minute) }
|
||||||
// Missread microsecond ([Sec Hour Minute].len == 3 < 4)
|
// Missread microsecond ([Sec Hour Minute].len == 3 < 4)
|
||||||
if count < 4 {
|
if count < 4 {
|
||||||
count = unsafe { C.sscanf(charptr(s.str), '%2d:%2d:%2d%c%2d:%2d', &hour, &minute,
|
count = unsafe { C.sscanf(charptr(s.str), '%2d:%2d:%2d%c%2d:%2d', &hour, &minute,
|
||||||
|
|||||||
Reference in New Issue
Block a user