Module: RBS
Constant Summary
-
VERSION =
# File 'lib/rbs/version.rb', line 4"3.4.0"
Class Attribute Summary
Class Method Summary
Class Attribute Details
.logger_level (rw)
[ GitHub ]# File 'lib/rbs.rb', line 64
attr_reader :logger_level
.logger_level=(level) (rw)
[ GitHub ]# File 'lib/rbs.rb', line 76
def logger_level=(level) @logger_level = level @logger = nil end
.logger_output (rw)
[ GitHub ]# File 'lib/rbs.rb', line 65
attr_reader :logger_output
.logger_output=(val) (rw)
[ GitHub ]# File 'lib/rbs.rb', line 71
def logger_output=(val) @logger = nil @logger_output = val end
Class Method Details
.logger
[ GitHub ]# File 'lib/rbs.rb', line 67
def logger @logger ||= Logger.new(logger_output || STDERR, level: logger_level || Logger::WARN, progname: "rbs") end
.print_warning
[ GitHub ]# File 'lib/rbs.rb', line 81
def print_warning() @warnings ||= Set[] = yield() unless @warnings.include?( ) @warnings << logger.warn { } end end