When pressing ctrl+b (go to declaration) inside a model with has_many IDEA jumps to a controller where a global variable with the same name is declared. This seems wrong. A better place to go to is the model that infact is referenced. Like this
class Library < ActiveRecord::Base
has_many :books
class Book < ActiveRecord::Base
has_one :library
Pressing ctrl+b with cursor on :books should jump to the Book class and the other way around.