mirror of
https://github.com/safiire/n65.git
synced 2025-02-09 13:30:31 +00:00
Linted instruction_base.rb
This commit is contained in:
parent
92e315b3ed
commit
963dab73cc
@ -1,29 +1,17 @@
|
|||||||
|
# frozen_string_literal: true
|
||||||
|
|
||||||
module N65
|
module N65
|
||||||
|
|
||||||
class InstructionBase
|
class InstructionBase
|
||||||
|
def self.parse(_line)
|
||||||
|
raise(NotImplementedError, "#{self.class.name} must implement self.parse")
|
||||||
#####
|
|
||||||
## Sort of a "pure virtual" class method, not really tho.
|
|
||||||
def self.parse(line)
|
|
||||||
fail(NotImplementedError, "#{self.class.name} must implement self.parse")
|
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
||||||
####
|
|
||||||
## Does this instruction have unresolved symbols?
|
|
||||||
def unresolved_symbols?
|
def unresolved_symbols?
|
||||||
false
|
false
|
||||||
end
|
end
|
||||||
|
|
||||||
|
def exec(_assembler)
|
||||||
####
|
raise(NotImplementedError, "#{self.class.name} must implement exec")
|
||||||
## Another method subclasses will be expected to implement
|
|
||||||
def exec(assembler)
|
|
||||||
fail(NotImplementedError, "#{self.class.name} must implement exec")
|
|
||||||
end
|
end
|
||||||
|
|
||||||
end
|
end
|
||||||
|
|
||||||
end
|
end
|
||||||
|
Loading…
x
Reference in New Issue
Block a user