8000 use auto · johnrees/arangodb@9a46fd5 · GitHub
[go: up one dir, main page]

Skip to content

Commit 9a46fd5

Browse files
author
Jan Steemann
committed
use auto
1 parent e222c72 commit 9a46fd5

File tree

1 file changed

+9
-10
lines changed

1 file changed

+9
-10
lines changed

arangod/Utils/ExplicitTransaction.h

Lines changed: 9 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -75,13 +75,13 @@ namespace triagens {
7575
if (waitForSync) {
7676
this->setWaitForSync();
7777
}
78-
79-
for (auto it = readCollections.begin(); it != readCollections.end(); ++it) {
80-
this->addCollection((*it), TRI_TRANSACTION_READ);
78+
79+
for (auto const& it : readCollections) {
80+
this->addCollection(it, TRI_TRANSACTION_READ);
8181
}
8282

83-
for (auto it = writeCollections.begin(); it != writeCollections.end(); ++it) {
84-
this->addCollection((*it), TRI_TRANSACTION_WRITE);
83+
for (auto const& it : writeCollections) {
84+
this->addCollection(it, TRI_TRANSACTION_WRITE);
8585
}
8686
}
8787

@@ -107,16 +107,15 @@ namespace triagens {
107107
this->setWaitForSync();
108108
}
109109

110-
for (auto it = readCollections.begin(); it != readCollections.end(); ++it) {
111-
this->addCollection((*it), TRI_TRANSACTION_READ);
110+
for (auto const& it : readCollections) {
111+
this->addCollection(it, TRI_TRANSACTION_READ);
112112
}
113113

114-
for (auto it = writeCollections.begin(); it != writeCollections.end(); ++it) {
115-
this->addCollection((*it), TRI_TRANSACTION_WRITE);
114+
for (auto const& it : writeCollections) {
115+
this->addCollection(it, TRI_TRANSACTION_WRITE);
116116
}
117117
}
118118

119-
120119
////////////////////////////////////////////////////////////////////////////////
121120
/// @brief end the transaction
122121
////////////////////////////////////////////////////////////////////////////////

0 commit comments

Comments
 (0)
0