Module: AdLint::Pluggable
- Included in:
- Cc1::Interpreter, Cc1::Lexer, Cc1::MemoryWindow, Cc1::SyntaxTreeMulticastVisitor, Cpp::CodeSubstitution, Cpp::Lexer, Cpp::MacroTable, Cpp::PreprocessedSource, Cpp::Preprocessor, Cpp::SyntaxTreeMulticastVisitor, Ld::FunctionTraversal, Ld::TypedefTraversal, Ld::VariableTraversal, Source, Foo
- Defined in:
- lib/adlint/util.rb
Instance Method Summary collapse
Instance Method Details
#def_plugin(event) ⇒ Object
457 458 459 460 461 462 463 464 465 466 |
# File 'lib/adlint/util.rb', line 457 def def_plugin(event) class_eval <<-EOS define_method("#{event}") do |*args| @#{event}_plugin ||= Plugin.new end define_method("#{event}=") do |*args| @#{event}_plugin = args.first end EOS end |