mirror of
https://github.com/vlang/v.git
synced 2023-08-10 21:13:21 +03:00
fix a few warnings
Good find, @eyelash .
This commit is contained in:
@@ -115,7 +115,7 @@ pub fn digits(_n, base int) []int {
|
||||
sign = -1
|
||||
n = -n
|
||||
}
|
||||
mut res := []int
|
||||
mut res := []int{}
|
||||
for n != 0 {
|
||||
res << (n % base) * sign
|
||||
n /= base
|
||||
|
||||
Reference in New Issue
Block a user