Macaulay2 Engine
Loading...
Searching...
No Matches

◆ setOutputPositions()

void SLProgram::setOutputPositions ( const M2_arrayint a)

Definition at line 53 of file SLP.cpp.

54{
55 for (int i = 0; i < a->len; i++)
56 {
57 int p = a->array[i];
59 ERROR("input or constant position out of range");
60 else if (p >= 0 && p >= mNodes.size())
61 ERROR("node position out of range");
62 else
63 mOutputPositions.push_back(p);
64 }
65}
int inputCounter
Definition SLP-defs.hpp:107
std::vector< GATE_TYPE > mNodes
Definition SLP-defs.hpp:95
std::vector< GATE_POSITION > mOutputPositions
Definition SLP-defs.hpp:103
int p
const int ERROR
Definition m2-mem.cpp:55

References ERROR, inputCounter, mNodes, mOutputPositions, and p.

Referenced by rawSLPsetOutputPositions().