Ralph S. wrote:
Marnen Laibow-Koser wrote:
Ralph S. wrote:
Windows development environment.
How is that relevant?
I don’t know! How files are handled might be different on different
I suppose. But in this case, no. So far as I know, there’s no
significant difference in Ruby source code handling between OSes, except
perhaps for case-sensitivity issues. (That said, I don’t use Windows,
so it’s conceivably that I’m not aware of something.)
Is there a convenient way to find out which source module
What’s a source module?
A file with source code in it, Marnen.
The term “module” is never used in that sense by Ruby developers.
Ask a silly question …
The word “module” … like “include” … varies in meaning depending on
“Module” has exactly one meaning in a Ruby context, and that wasn’t it.
If you mean “file”, then say it.
defined/defines the class Devise::Mapping ?
Yes. Use grep. Or look in the rdoc.
And remember that it might be defined in more than one place, since
modules and classes can be reopened.
If, in a debugger, I enter the name of a block, the source file (er,
and line number is displayed. I like that. It’s very useful.
Yup. The reason I didn’t originally suggest the debugger is that I was
trying to come up with a suggestion that didn’t require knowing where to
put a breakpoint.
I was hoping that there might have been a way (perhaps an array of names
and line numbers of source files?), that Ruby/Rails would keep track of
all the places that a class had been constructed from?
I doubt it, but I’m not enough of a Ruby internals geek to say for sure.