js: add initial support for runes (#12077)

This commit is contained in:
playX 2021-10-06 10:43:49 +03:00 committed by GitHub
parent 115493781b
commit b2945e916f
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
10 changed files with 88 additions and 25 deletions

View file

@ -652,12 +652,13 @@ fn test_rune_keys() {
println(m)
assert '$m' == '{`!`: 2, `%`: 3, `@`: 7}'
/*
mut a := []rune{}
for k, v in m {
a << k
a << rune(v) + `0`
}
assert a == [`!`, `2`, `%`, `3`, `@`, `7`]
assert a == [`!`, `2`, `%`, `3`, `@`, `7`]*/
}
fn test_eq() {