Skip to content
New issue

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

Symbol#inspect differs from MRI Ruby #2896

Closed
k77ch7 opened this issue Apr 30, 2015 · 0 comments
Closed

Symbol#inspect differs from MRI Ruby #2896

k77ch7 opened this issue Apr 30, 2015 · 0 comments

Comments

@k77ch7
Copy link
Contributor

k77ch7 commented Apr 30, 2015

The following symbol_test.rb differs from MRI Ruby. The different result occurs in the case of UTF8 string symbol.

symbol_test.rb

# encoding: utf-8

p :"Ãa1".inspect
p :"a1".inspect
p :"1".inspect

MRI Ruby 1.9.3, 2.0.0, 2.1.4 and 2.2,1

$ ruby ~/development/symbol_test.rb
":Ãa1"
":a1"
":\"1\""

JRuby master and 1_7 branch

$ jruby ~/development/symbol_test.rb
":\"Ãa1\""
":a1"
":\"1\""

My env

jruby 9.0.0.0-SNAPSHOT (2.2.2) 2015-04-30 1cade78 Java HotSpot(TM) 64-Bit Server VM 25.5-b02 on 1.8.0_05-b13 +jit [darwin-x86_64]

jruby 1.7.20-SNAPSHOT (1.9.3p551) 2015-04-30 5fd659d on Java HotSpot(TM) 64-Bit Server VM 1.8.0_05-b13 +jit [darwin-x86_64]

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants