Sha256: 0c9320bc56e251f0ca954c7f64e6192876c7928ff155e247346bcdb673e54cfe

Contents?: true

Size: 421 Bytes

Versions: 1

Compression:

Stored size: 421 Bytes

Contents

# frozen_string_literal: true

require_relative 'word'
require_relative 'module_memo_word'

module Forthic
  class ModuleMemoBangWord < Word
    attr_accessor :memo_word

    # @param [ModuleMemoWord] memo_word
    def initialize(memo_word)
      super("#{memo_word.name}!")
      @memo_word = memo_word
    end

    # @param [Interpreter] interp
    def execute(interp)
      @memo_word.refresh(interp)
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
forthic-0.1.0 lib/forthic/words/module_memo_bang_word.rb