This commit is contained in:
parent
3214561634
commit
dbbb7949e8
3 changed files with 5 additions and 1 deletions
|
@ -5,7 +5,7 @@ name: default
|
|||
|
||||
steps:
|
||||
- name: ameba
|
||||
image: veelenga/ameba
|
||||
image: veelenga/ameba:latest
|
||||
commands:
|
||||
- ameba src/
|
||||
- name: build
|
||||
|
|
|
@ -82,6 +82,7 @@ module Hence
|
|||
)
|
||||
end
|
||||
|
||||
# ameba:disable Metrics/CyclomaticComplexity
|
||||
def get_register(index : UInt8) : UInt16
|
||||
case index
|
||||
when 0x0_u8
|
||||
|
@ -121,6 +122,7 @@ module Hence
|
|||
end
|
||||
end
|
||||
|
||||
# ameba:disable Metrics/CyclomaticComplexity
|
||||
def set_register(index : UInt8, value : UInt16) : UInt16
|
||||
case index
|
||||
when 0x0_u8
|
||||
|
@ -160,6 +162,7 @@ module Hence
|
|||
end
|
||||
end
|
||||
|
||||
# ameba:disable Metrics/CyclomaticComplexity
|
||||
def alu(op : UInt8) : UInt16
|
||||
case op
|
||||
when 0x00 # not
|
||||
|
|
|
@ -4,6 +4,7 @@ module Hence
|
|||
module Parser
|
||||
extend self
|
||||
|
||||
# ameba:disable Metrics/CyclomaticComplexity
|
||||
def parse(source : String) : AST
|
||||
s = StringScanner.new(source.gsub(/;.*|@.*|#.*/, nil))
|
||||
body = [] of AST::Node
|
||||
|
|
Loading…
Reference in a new issue