1
0
mirror of https://github.com/vlang/v.git synced 2023-08-10 21:13:21 +03:00

js,strconv: port some functions to JS backend, improve rune.str() (#12460)

This commit is contained in:
playX
2021-11-14 22:06:58 +03:00
committed by GitHub
parent 460f4523aa
commit e3d98b1b28
5 changed files with 185 additions and 82 deletions

View File

@@ -18,14 +18,14 @@ pub fn (c rune) repeat(count int) string {
return c.str()
}
res := ''
#res.str = String.fromCharCode(c.val)
#res.str = String.fromCharCode(Number(c.val))
return res.repeat(count)
}
pub fn (c rune) str() string {
res := ''
#res.str = String.fromCharCode(c.val)
#res.str = String.fromCharCode(Number(c.val))
return res
}