Sha256: 9bd57105eebe8d02b70242959d4258640506785f2729e5da26960e1d838f60b0
Contents?: true
Size: 596 Bytes
Versions: 10
Compression:
Stored size: 596 Bytes
Contents
# frozen_string_literal: true module RuboCop # The RuboCop's built-in LSP module. module LSP module_function # Returns true when LSP is enabled, false when disabled. # # @return [Boolean] def enabled? @enabled ||= false end # Enable LSP. # # @return [void] def enable @enabled = true end # Disable LSP. # # @return [void] def disable(&block) if block original = @enabled @enabled = false yield @enabled = original else @enabled = false end end end end
Version data entries
10 entries across 10 versions & 3 rubygems