Project

General

Profile

Actions

Bug #1386

closed

Spurious class "ARGF.class" in ObjectSpace

Added by candlerb (Brian Candler) almost 15 years ago. Updated almost 13 years ago.

Status:
Rejected
Target version:
-
ruby -v:
ruby 1.9.1 (2008-12-16 revision 20768) [i686-linux]ruby 1.8.6 (2008-
Backport:

Description

=begin
$ ruby19 -e 'ObjectSpace.each_object(Class) { |c| puts c if c.to_s =~ /./ }'
ARGF.class

However this 'class' is not accessible by name:

$ ruby19 -e 'puts Object.const_get("ARGF.class")'
-e:1:in const_get': wrong constant name ARGF.class (NameError) from -e:1:in '
=end

Actions #1

Updated by candlerb (Brian Candler) almost 15 years ago

=begin
Sorry, I set the ruby -v field wrongly, but cannot edit it. It should have been:

$ ruby19 -v
ruby 1.9.1 (2008-12-16 revision 20768) [i686-linux]

=end

Actions #2

Updated by matz (Yukihiro Matsumoto) almost 15 years ago

  • Status changed from Open to Rejected
  • Assignee set to matz (Yukihiro Matsumoto)
  • ruby -v changed from ruby 1.8.6 (2008-03-03 patchlevel 114) [i686-linux] to ruby 1.9.1 (2008-12-16 revision 20768) [i686-linux]ruby 1.8.6 (2008-

=begin
We have never guaranteed that

c == Object.const_get(c.to_s)

where c is a class. So I don't consider this as a bug.

=end

Actions

Also available in: Atom PDF

Like0
Like0Like0