Project

General

Profile

Actions

Bug #2292

closed

不正なマルチバイトStringのinspect結果にゴミが入る

Added by nobu (Nobuyoshi Nakada) over 14 years ago. Updated almost 13 years ago.

Status:
Closed
Assignee:
-
Target version:
-
ruby -v:
ruby 1.8.8dev (2009-10-27 ruby_1_8 25514) [i386-darwin9.6.0]
[ruby-dev:39550]

Description

=begin
短いUTF-8文字列をinspectすると結果に"\0"が入ります。

$ ./ruby -v -e '$KCODE="u";s="\xe3\x81".inspect;$KCODE="n";p s'
ruby 1.8.8dev (2009-10-27 ruby_1_8 25514) [i386-darwin9.6.0]
""\343\201\000""
=end

Actions

Also available in: Atom PDF

Like0
Like0