mirror of
https://github.com/vlang/v.git
synced 2025-08-03 17:57:59 -04:00
builtin: fix warnings for ./v doc -m -f html vlib/builtin/
This commit is contained in:
parent
2c7b42030a
commit
ca620f4965
@ -102,11 +102,13 @@ pub fn i64_tos(buf &u8, len int, n0 i64, base int) string {
|
||||
n = -n
|
||||
}
|
||||
|
||||
b[i--] = 0
|
||||
b[i] = 0
|
||||
i--
|
||||
|
||||
for {
|
||||
c := (n % base) + 48
|
||||
b[i--] = if c > 57 { c + 7 } else { c }
|
||||
b[i] = if c > 57 { c + 7 } else { c }
|
||||
i--
|
||||
if i < 0 {
|
||||
panic('buffer to small')
|
||||
}
|
||||
@ -119,7 +121,8 @@ pub fn i64_tos(buf &u8, len int, n0 i64, base int) string {
|
||||
if i < 0 {
|
||||
panic('buffer to small')
|
||||
}
|
||||
b[i--] = 45
|
||||
b[i] = 45
|
||||
i--
|
||||
}
|
||||
offset := i + 1
|
||||
b.str = b.str + offset
|
||||
|
Loading…
x
Reference in New Issue
Block a user