start with block_compiler

as a copy of method_compiler
re-merge later, when we know what's needed
This commit is contained in:
Torsten Ruger
2018-07-09 16:48:23 +03:00
parent 7231f301ba
commit dd544214b3
10 changed files with 159 additions and 13 deletions

View File

@ -5,6 +5,16 @@ module Mom
class Constant
end
class BlockConstant < Constant
attr_reader :block
def initialize(bl)
@block = bl
end
def to_parfait(compiler)
@block
end
end
class IntegerConstant < Constant
attr_reader :value
def initialize(value)