Class: Kapusta::Compiler::Emitter
- Inherits:
-
Object
- Object
- Kapusta::Compiler::Emitter
- Includes:
- Kapusta::Compiler::EmitterModules::Bindings, Kapusta::Compiler::EmitterModules::Collections, Kapusta::Compiler::EmitterModules::ControlFlow, Kapusta::Compiler::EmitterModules::Expressions, Kapusta::Compiler::EmitterModules::Interop, Kapusta::Compiler::EmitterModules::Patterns, Kapusta::Compiler::EmitterModules::Support
- Defined in:
- lib/kapusta/compiler/emitter.rb
Constant Summary collapse
- RUBY_KEYWORDS =
%w[ BEGIN END alias and begin break case class def defined? do else elsif end ensure false for if in module next nil not or redo rescue retry return self super then true undef unless until when while yield ].freeze
Instance Method Summary collapse
- #emit_file(forms) ⇒ Object
-
#initialize(path:) ⇒ Emitter
constructor
A new instance of Emitter.
Constructor Details
#initialize(path:) ⇒ Emitter
Returns a new instance of Emitter.
27 28 29 30 |
# File 'lib/kapusta/compiler/emitter.rb', line 27 def initialize(path:) @path = path @temp_index = 0 end |