Class: Rubycc::Rmake::Step

Inherits:
Object
  • Object
show all
Defined in:
lib/rubycc/rmake/model.rb

Overview

A single node of the execution plan: the target that would be (re)built and the ordered, fully-expanded commands that would build it. prereqs names the other steps that must complete before this one may start — the edges a parallel scheduler (B3 -j) needs. It is empty for a step with no stale step among its prerequisites, and the sequential runner ignores it entirely (the plan is already emitted in a valid dependency order).

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(target:, commands:, prereqs: []) ⇒ Step

Returns a new instance of Step.



98
99
100
101
102
# File 'lib/rubycc/rmake/model.rb', line 98

def initialize(target:, commands:, prereqs: [])
  @target = target
  @commands = commands
  @prereqs = prereqs
end

Instance Attribute Details

#commandsObject (readonly)

Returns the value of attribute commands.



95
96
97
# File 'lib/rubycc/rmake/model.rb', line 95

def commands
  @commands
end

#prereqsObject

Returns the value of attribute prereqs.



96
97
98
# File 'lib/rubycc/rmake/model.rb', line 96

def prereqs
  @prereqs
end

#targetObject (readonly)

Returns the value of attribute target.



95
96
97
# File 'lib/rubycc/rmake/model.rb', line 95

def target
  @target
end