class Gem::BasicSpecification

def to_fullpath path

def to_fullpath path
  if activated? then
    @paths_map ||= {}
    @paths_map[path] ||=
    begin
      fullpath = nil
      suffixes = Gem.suffixes
      suffixes.find do |suf|
        full_require_paths.find do |dir|
          File.file?(fullpath = "#{dir}/#{path}#{suf}")
        end
      end ? fullpath : nil
    end
  else
    nil
  end
end