Project

General

Profile

Actions

Bug #12594

closed

The class does not inherit from a module the modules that were included after the inclusion

Bug #12594: The class does not inherit from a module the modules that were included after the inclusion

Added by faucct (Nikita Sokolov) over 9 years ago. Updated over 5 years ago.

Status:
Closed
Target version:
-
ruby -v:
2.3.0, 2.3.1
[ruby-core:76397]
Tags:

Description

Reproduced in ruby 2.3.0 and 2.3.1
You can see that the result changes if I swap places LimitedPeriod.include Period and Period.include Serialization.

module Serialization
end

module Period
end

Period.include Serialization

class LimitedPeriod
  include Period
end

LimitedPeriod < Serialization
# => true
module Serialization
end

module Period
end

class LimitedPeriod
  include Period
end

Period.include Serialization

LimitedPeriod < Serialization
# => false

Updated by faucct (Nikita Sokolov) about 9 years ago Actions #1 [ruby-core:76680]

  • Description updated (diff)

Updated by shyouhei (Shyouhei Urabe) about 9 years ago Actions #2 [ruby-core:76812]

I listed this issue to be looked at the yesterday's developer meeting but sadly no time was there to deeply inspect it. At a glance it seems possible now to reflect inclusion happened afterwards. It has a chance.

Updated by shyouhei (Shyouhei Urabe) about 9 years ago Actions #3 [ruby-core:77570]

  • Status changed from Open to Assigned
  • Assignee set to nobu (Nobuyoshi Nakada)

We at developer meeting looked at it again. Nobu thinks he can fix this so I'm assigning to him. He said to me this is low priority, though.

Updated by jeremyevans0 (Jeremy Evans) over 5 years ago Actions #4 [ruby-core:98618]

  • Status changed from Assigned to Closed
Actions

Also available in: PDF Atom