Class: XfOOrth::MacroSpec

Inherits:
AbstractWordSpec show all
Defined in:
lib/fOOrth/compiler/word_specs.rb

Overview

A class used to specify the compile of fOOrth macros.

Instance Attribute Summary

Attributes inherited from AbstractWordSpec

#builds, #does, #tags

Instance Method Summary collapse

Methods inherited from AbstractWordSpec

#get_info, #get_stub_action, #has_tag?, #initialize

Constructor Details

This class inherits a constructor from XfOOrth::AbstractWordSpec

Instance Method Details

#build_builds_string(_name, _symbol) ⇒ Object

Generate the Ruby code for this macro.
Parameters:

  • _name - The string that maps to the symbol. Unused

  • _symbol - The symbol that the name maps to. Unused


Note:

  • The last entry in the tags array is expected to be a string

with the text of the command macro.


177
178
179
# File 'lib/fOOrth/compiler/word_specs.rb', line 177

def build_builds_string(_name, _symbol)
  @builds = @tags[-1]
end