ruby-core

Mailing list archive

[#35027] [Ruby 1.9-Bug#4352][Open] [patch] Fix eval(s, b) backtrace; make eval(s, b) consistent with eval(s) — "James M. Lawrence" <redmine@...>

Bug #4352: [patch] Fix eval(s, b) backtrace; make eval(s, b) consistent w=

16 messages 2011/02/01

[#35114] [Ruby 1.9-Bug#4373][Open] http.rb:677: [BUG] Segmentation fault — Christian Fazzini <redmine@...>

Bug #4373: http.rb:677: [BUG] Segmentation fault

59 messages 2011/02/06

[#35171] [Ruby 1.9-Bug#4386][Open] encoding: directive does not affect regex expressions — mathew murphy <redmine@...>

Bug #4386: encoding: directive does not affect regex expressions

9 messages 2011/02/09

[#35237] [Ruby 1.9-Bug#4400][Open] nested at_exit hooks run in strange order — Suraj Kurapati <redmine@...>

Bug #4400: nested at_exit hooks run in strange order

12 messages 2011/02/15

[ruby-core:35155] Re: [Ruby 1.9-Bug#4340] Encoding of result string for String#gsub is not consistent

From: Nobuyoshi Nakada <nobu@...>
Date: 2011-02-08 22:12:55 UTC
List: ruby-core #35155
Hi,

At Wed, 9 Feb 2011 04:41:14 +0900,
mathew wrote in [ruby-core:35154]:
>> Can I ask why regexps are not affected by
>> # encoding: UTF-8
>> declarations?
> 
> Nobody?
> 
> I still can't think of a reason, so what am I missing?

It does affect.

$ ruby -e '#encoding:utf-8' -e 'p /\u3042/.encoding'
#<Encoding:UTF-8>
$ ruby -e '#encoding:cp932' -e 'p /\x81\x42/.encoding'
#<Encoding:Windows-31J>
$ ruby -e '#encoding:euc-jp' -e 'p /\xa1\xa2/.encoding'
#<Encoding:EUC-JP>

-- 
Nobu Nakada

In This Thread

Prev Next