Class: GrammarLinter Abstract

Inherits:
GrammarPlugin show all
Defined in:
lib/ruby_grammar_builder/grammar_plugin.rb

Overview

This class is abstract.

Subclass and override #pre_lint and/or #post_lint to implement a linter

Instance Method Summary collapse

Methods inherited from GrammarPlugin

display_options, options

Instance Method Details

#post_lint(grammar_hash) ⇒ Boolean

Runs the linter on the entire grammar



54
55
56
# File 'lib/ruby_grammar_builder/grammar_plugin.rb', line 54

def post_lint(grammar_hash) # rubocop:disable Lint/UnusedMethodArgument
    true
end

#pre_lint(pattern, options = {}) ⇒ Boolean

Runs the linter on each pattern



43
44
45
# File 'lib/ruby_grammar_builder/grammar_plugin.rb', line 43

def pre_lint(pattern, options = {}) # rubocop:disable Lint/UnusedMethodArgument
    true
end