class Mint::Compiler2::Renderer
  
  - Mint::Compiler2::Renderer
- Reference
- Object
Overview
This class is responsible to render Compiled code.
Defined in:
compiler2/renderer.crConstructors
Instance Method Summary
- #base : Ast::Node | Bundle
- 
        #builtins : Set(Mint::Compiler2::Builtin)
        
          A set to track used builtins which will be imported. 
- #bundle_path : Proc(Ast::Node | Bundle, String)
- 
        #class_pool : NamePool(Ast::Node | Builtin, Ast::Node | Bundle)
        
          The pool for class variables (uppercase). 
- #deferred_path : Proc(Ast::Node | Bundle, String)
- 
        #depth : Int32
        
          The current indentation depth. 
- 
        #depth=(depth : Int32)
        
          The current indentation depth. 
- #import(imports : Hash(String, String), optimize : Bool, path : String)
- 
        #pool : NamePool(Ast::Node | Variable | String | Encoder | Decoder, Ast::Node | Bundle)
        
          The pool for variables (lowercase). 
- #references : ReferencesTracker
- #render(items : Compiled, io : IO)
- #render(items : Compiled) : String
- 
        #render(item : Item, io : IO = IO::Memory.new)
        
          We are using a string builder to build the final compiled code. 
- 
        #used : Set(Mint::Ast::Node | Mint::Compiler2::Decoder | Mint::Compiler2::Encoder)
        
          A set to track nodes which we rendered. 
Constructor Detail
        
        def self.new(*, base : Mint::Ast::Node | Mint::Compiler2::Bundle, pool : Mint::NamePool(Mint::Ast::Node | Mint::Compiler2::Decoder | Mint::Compiler2::Encoder | Mint::Compiler2::Variable | String, Mint::Ast::Node | Mint::Compiler2::Bundle), class_pool : Mint::NamePool(Mint::Ast::Node | Mint::Compiler2::Builtin, Mint::Ast::Node | Mint::Compiler2::Bundle), bundle_path : Mint::Ast::Node | Mint::Compiler2::Bundle -> String, deferred_path : Mint::Ast::Node | Mint::Compiler2::Bundle -> String, references : Mint::ReferencesTracker)
        #
      
      
      Instance Method Detail
The pool for class variables (uppercase).
The pool for variables (lowercase).
We are using a string builder to build the final compiled code.
A set to track nodes which we rendered.