Skip to content

[Bug]: "Code" function behaves inconsistently with constant and non-constant parameter #993

@oskostenko

Description

@oskostenko

Contact Details

No response

Compiler version

v1.18.1

What happened?

print code("a") * 3      ' prints "291"

dim char as string = "a"
print code(char) * 3     ' prints "35" (which is 291 truncated to byte size)

I'd expect that in both cases the result is the same.

Error and Warning messages

Code of Conduct

  • I agree to follow this project's Code of Conduct

Metadata

Metadata

Assignees

Labels

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions