class Solargraph::RbsMap::CoreMap
Ruby core pins
Constants
- FILLS_DIRECTORY
Public Class Methods
Public Instance Methods
Source
# File lib/solargraph/rbs_map/core_map.rb, line 19 def pins return @pins if @pins @pins = [] cache = PinCache.deserialize_core if cache @pins.replace cache else @pins.concat conversions.pins # Avoid RBS::DuplicatedDeclarationError by loading in a different EnvironmentLoader fill_loader = RBS::EnvironmentLoader.new(core_root: nil, repository: RBS::Repository.new(no_stdlib: false)) fill_loader.add(path: Pathname(FILLS_DIRECTORY)) fill_conversions = Conversions.new(loader: fill_loader) @pins.concat fill_conversions.pins @pins.concat RbsMap::CoreFills::ALL processed = ApiMap::Store.new(pins).pins.reject { |p| p.is_a?(Solargraph::Pin::Reference::Override) } @pins.replace processed PinCache.serialize_core @pins end @pins end
@return [Enumerable<Pin::Base>]
Private Instance Methods
Source
# File lib/solargraph/rbs_map/core_map.rb, line 53 def conversions @conversions ||= Conversions.new(loader: loader) end
@return [Conversions]
Source
# File lib/solargraph/rbs_map/core_map.rb, line 48 def loader @loader ||= RBS::EnvironmentLoader.new(repository: RBS::Repository.new(no_stdlib: false)) end
@return [RBS::EnvironmentLoader]