summaryrefslogtreecommitdiffstats
path: root/src/server/GraphImpl.cpp
diff options
context:
space:
mode:
authorDavid Robillard <d@drobilla.net>2017-12-25 16:37:00 -0500
committerDavid Robillard <d@drobilla.net>2017-12-25 16:37:00 -0500
commit37729e5b314e39fb750a3fb46a005acdb15b4ac2 (patch)
tree5e8e316e9f186dc47bfef09c7546cc3a8f14f6bb /src/server/GraphImpl.cpp
parent05bce078b6b5cfc64f10399da3a422d00fe6f790 (diff)
downloadingen-37729e5b314e39fb750a3fb46a005acdb15b4ac2.tar.gz
ingen-37729e5b314e39fb750a3fb46a005acdb15b4ac2.tar.bz2
ingen-37729e5b314e39fb750a3fb46a005acdb15b4ac2.zip
Use auto for iterators
Diffstat (limited to 'src/server/GraphImpl.cpp')
-rw-r--r--src/server/GraphImpl.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/server/GraphImpl.cpp b/src/server/GraphImpl.cpp
index ec73a8c8..f9c4cb54 100644
--- a/src/server/GraphImpl.cpp
+++ b/src/server/GraphImpl.cpp
@@ -110,8 +110,8 @@ GraphImpl::duplicate(Engine& engine,
for (const auto& a : _arcs) {
SPtr<ArcImpl> arc = dynamic_ptr_cast<ArcImpl>(a.second);
if (arc) {
- PortMap::iterator t = port_map.find(arc->tail());
- PortMap::iterator h = port_map.find(arc->head());
+ auto t = port_map.find(arc->tail());
+ auto h = port_map.find(arc->head());
if (t != port_map.end() && h != port_map.end()) {
dup->add_arc(SPtr<ArcImpl>(new ArcImpl(t->second, h->second)));
}
@@ -277,7 +277,7 @@ SPtr<ArcImpl>
GraphImpl::remove_arc(const PortImpl* tail, const PortImpl* dst_port)
{
ThreadManager::assert_thread(THREAD_PRE_PROCESS);
- Arcs::iterator i = _arcs.find(std::make_pair(tail, dst_port));
+ auto i = _arcs.find(std::make_pair(tail, dst_port));
if (i != _arcs.end()) {
SPtr<ArcImpl> arc = dynamic_ptr_cast<ArcImpl>(i->second);
_arcs.erase(i);
@@ -291,7 +291,7 @@ bool
GraphImpl::has_arc(const PortImpl* tail, const PortImpl* dst_port) const
{
ThreadManager::assert_thread(THREAD_PRE_PROCESS);
- Arcs::const_iterator i = _arcs.find(std::make_pair(tail, dst_port));
+ auto i = _arcs.find(std::make_pair(tail, dst_port));
return (i != _arcs.end());
}