We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
proc main()= var a: cstring echo a.len static: main() main()
c: vm: 0 rt: 0 js: vm: 0 rt: TypeError: Cannot read property 'length' of null
c: vm: 0 rt: 0 js: vm: 0 rt: 0
cstring("") != nil
isNil
The text was updated successfully, but these errors were encountered:
cstring.default
nil
""
a.length => a != null ? a.length : 0 in jsgen with a temp should do it
a.length
a != null ? a.length : 0
Sorry, something went wrong.
ditto: low/high(cstring(nil)) in JS backend
cstring(nil)
add(a, b)
Successfully merging a pull request may close this issue.
Example
Current Output
c:
vm: 0
rt: 0
js:
vm: 0
rt: TypeError: Cannot read property 'length' of null
Expected Output
c:
vm: 0
rt: 0
js:
vm: 0
rt: 0
Additional Information
cstring("") != nil
fails at CT;isNil
sometimes returns false for nil cstring #15730The text was updated successfully, but these errors were encountered: