Skip to content

Integer#chr has different RangeError exception message compared to CRuby #2795

@postmodern

Description

@postmodern

I noticed a slight difference between TruffleRuby 22.3.0 and CRuby 3.0.4 while running my test suite against TruffleRuby. When Integer#chr tries to convert an invalid byte (ex: -1) into a character, the RangeError exception message is slightly different on TruffleRuby.

CRuby 3.0.4

-1.chr
# -1 out of char range (RangeError)

TruffleRuby 22.3.0

-1.chr
# -1 is outside of the valid character range (RangeError)

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions