You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The runes() method call crashes in code generated by the JS backend.
Reproduction Steps
foo:="hello馃巺".runes()
println(foo)
Expected Behavior
Expected both C and JS backends to produce the same output.
Current Behavior
$ v run runes.v # runs okay
[`h`, `e`, `l`, `l`, `o`, `馃巺`]
$ v -o runes.js runes.v && node runes.js
/home/justinas/vlang-testcases/runes.js:3963
let r = new rune(new u8('0')); r = new rune(s.str[i.val].charCodeAt())
^
TypeError: Cannot read properties of undefined (reading 'charCodeAt')
at string_runes (/home/justinas/vlang-testcases/runes.js:3963:62)
at js_main (/home/justinas/vlang-testcases/runes.js:6022:15)
at /home/justinas/vlang-testcases/runes.js:6079:25
Node.js v18.18.2
Possible Solution
No response
Additional Information/Context
No response
V version
V 0.4.4 ac2dcc2
Environment details (OS name and version, etc.)
NixOS 23.11 (Tapir)
Note
You can use the 馃憤 reaction to increase the issue's priority for developers.
Please note that only the 馃憤 reaction to the issue itself counts as a vote.
Other reactions and those to comments will not be taken into account.
The text was updated successfully, but these errors were encountered:
Describe the bug
The
runes()
method call crashes in code generated by the JS backend.Reproduction Steps
Expected Behavior
Expected both C and JS backends to produce the same output.
Current Behavior
Possible Solution
No response
Additional Information/Context
No response
V version
V 0.4.4 ac2dcc2
Environment details (OS name and version, etc.)
NixOS 23.11 (Tapir)
Note
You can use the 馃憤 reaction to increase the issue's priority for developers.
Please note that only the 馃憤 reaction to the issue itself counts as a vote.
Other reactions and those to comments will not be taken into account.
The text was updated successfully, but these errors were encountered: