1
0
mirror of https://github.com/safiire/n65.git synced 2024-12-12 00:29:03 +00:00
n65/lib/directives/exit_scope.rb
2015-03-05 13:45:19 -08:00

36 lines
509 B
Ruby

require_relative '../instruction_base'
module Assembler6502
####
## This directive to include bytes
class ExitScope < InstructionBase
####
## Try to parse an incbin directive
def self.parse(line)
match_data = line.match(/^\.$/)
return nil if match_data.nil?
ExitScope.new
end
####
## Execute on the assembler
def exec(assembler)
assembler.symbol_table.exit_scope
end
####
## Display
def to_s
"."
end
end
end