Sha256: c1b75c45eaaa8ff48ef0de6a13dc1fa2ece2b0a53f5f0ff30515d51de074128a

Contents?: true

Size: 521 Bytes

Versions: 4

Compression:

Stored size: 521 Bytes

Contents

# frozen_string_literal: true

module Phlex
	class Compiler
		module Optimizers
			class VCall < BaseOptimizer
				module StandardElement
					def format(formatter)
						Generators::StandardElement.new(formatter,
							method_name: value.value.to_sym).call
					end
				end

				module VoidElement
					def format(formatter)
						Generators::VoidElement.new(formatter,
							method_name: value.value.to_sym).call
					end
				end

				private

				def name
					@node.value.value.to_sym
				end
			end
		end
	end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
phlex-0.4.0 lib/phlex/compiler/optimizers/vcall.rb
phlex-0.3.2 lib/phlex/compiler/optimizers/vcall.rb
phlex-0.3.1 lib/phlex/compiler/optimizers/vcall.rb
phlex-0.3.0 lib/phlex/compiler/optimizers/vcall.rb