Skip to content

Commit 0ef947d

Browse files
committed
Micro-optimise a ref_ptr copy into a move
This avoids a pair of atomic operations on a hot path
1 parent 533bae8 commit 0ef947d

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

src/vsg/utils/Intersector.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,7 @@ void Intersector::apply(const StateGroup& stategroup)
8383
statecommand->accept(*arrayState);
8484
}
8585

86-
arrayStateStack.emplace_back(arrayState);
86+
arrayStateStack.emplace_back(std::move(arrayState));
8787

8888
stategroup.traverse(*this);
8989

0 commit comments

Comments
 (0)