Skip to content

Commit dfff6ff

Browse files
committed
Add a comment
1 parent 2ede114 commit dfff6ff

1 file changed

Lines changed: 7 additions & 0 deletions

File tree

src/Iteration.cpp

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -282,6 +282,13 @@ void Iteration::flushVariableBased(
282282
Parameter<Operation::OPEN_PATH> pOpen;
283283
pOpen.path = "";
284284
IOHandler()->enqueue(IOTask(this, pOpen));
285+
/*
286+
* In v-based encoding, the snapshot attribute must always be written,
287+
* so don't set the `changesOverSteps` flag of the IOTask here.
288+
* Reason: Even in backends that don't support changing attributes,
289+
* variable-based iteration encoding can be used to write one single
290+
* iteration. Then, this attribute determines which iteration it is.
291+
*/
285292
this->setAttribute("snapshot", i);
286293
}
287294

0 commit comments

Comments
 (0)