Where are the environments constant defined?

Hi, constants defined in environment.rb are application wide.

But how and where are they stored ? I mean which is the class or module
to which they are attached ?

Thanks

On Nov 28, 3:43 pm, Bob M. [email protected]
wrote:

Hi, constants defined in environment.rb are application wide.

But how and where are they stored ? I mean which is the class or module
to which they are attached ?

Object. (and there’s nothing special about environment.rb. If you
define a constant outside of a class or module then it will get set at
the top level (bearing in mind that ruby’s constant resolution only
really cares about lexical scope)

Fred

Thanks a lot Fred ! I was totally unaware about this…

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs