From d443ddb053141510311e002c59746a2dd9ba8b16 Mon Sep 17 00:00:00 2001 From: David Robillard Date: Fri, 11 Jan 2013 05:40:18 +0000 Subject: Use range-based for loops where possible. Mmm, shiny. git-svn-id: http://svn.drobilla.net/lad/trunk/ingen@4919 a436a847-0d15-0410-975c-d299462d15a1 --- src/gui/RDFS.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'src/gui/RDFS.cpp') diff --git a/src/gui/RDFS.cpp b/src/gui/RDFS.cpp index 0420d4dd..bec69cee 100644 --- a/src/gui/RDFS.cpp +++ b/src/gui/RDFS.cpp @@ -51,8 +51,8 @@ classes(World* world, URISet& types, bool super) do { added = 0; URISet klasses; - for (URISet::iterator t = types.begin(); t != types.end(); ++t) { - LilvNode* type = lilv_new_uri(world->lilv_world(), t->c_str()); + for (const auto& t : types) { + LilvNode* type = lilv_new_uri(world->lilv_world(), t.c_str()); LilvNodes* matches = (super) ? lilv_world_find_nodes( world->lilv_world(), type, rdfs_subClassOf, NULL) @@ -153,8 +153,8 @@ instances(World* world, const URISet& types) world->lilv_world(), LILV_NS_RDF "type"); Objects result; - for (URISet::const_iterator i = types.begin(); i != types.end(); ++i) { - LilvNode* type = lilv_new_uri(world->lilv_world(), i->c_str()); + for (const auto& t : types) { + LilvNode* type = lilv_new_uri(world->lilv_world(), t.c_str()); LilvNodes* objects = lilv_world_find_nodes( world->lilv_world(), NULL, rdf_type, type); LILV_FOREACH(nodes, o, objects) { -- cgit v1.2.1