Class: Rucc::Macro

Inherits:
Object
  • Object
show all
Defined in:
lib/rucc/macro.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(kind, body: nil, nargs: nil, is_varg: nil, fn: nil) ⇒ Macro



10
11
12
13
14
15
16
17
18
19
20
21
# File 'lib/rucc/macro.rb', line 10

def initialize(kind,
               body: nil,
               nargs: nil,
               is_varg: nil,
               fn: nil
              )
  @kind = kind
  @body = body
  @nargs = nargs
  @is_varg = is_varg
  @fn = fn
end

Instance Attribute Details

#bodyObject (readonly)

Returns the value of attribute body.



22
23
24
# File 'lib/rucc/macro.rb', line 22

def body
  @body
end

#fnObject (readonly)

Returns the value of attribute fn.



22
23
24
# File 'lib/rucc/macro.rb', line 22

def fn
  @fn
end

#is_vargObject (readonly)

Returns the value of attribute is_varg.



22
23
24
# File 'lib/rucc/macro.rb', line 22

def is_varg
  @is_varg
end

#kindObject (readonly)

Returns the value of attribute kind.



22
23
24
# File 'lib/rucc/macro.rb', line 22

def kind
  @kind
end

#nargsObject (readonly)

Returns the value of attribute nargs.



22
23
24
# File 'lib/rucc/macro.rb', line 22

def nargs
  @nargs
end