mirror of
				https://github.com/ciphervance/supercell-wx.git
				synced 2025-10-31 15:20:05 +00:00 
			
		
		
		
	Don't use std::move when returning a local variable, allow NRVO
This commit is contained in:
		
							parent
							
								
									d73c1597d2
								
							
						
					
					
						commit
						976617d342
					
				
					 2 changed files with 4 additions and 4 deletions
				
			
		|  | @ -157,7 +157,7 @@ std::vector<std::shared_ptr<RadarSite>> RadarSite::GetAll() | |||
|       radarSites.push_back(site.second); | ||||
|    } | ||||
| 
 | ||||
|    return std::move(radarSites); | ||||
|    return radarSites; | ||||
| } | ||||
| 
 | ||||
| std::string GetRadarIdFromSiteId(const std::string& siteId) | ||||
|  |  | |||
|  | @ -260,7 +260,7 @@ TextureAtlas::Impl::LoadImage(const std::string& imagePath) | |||
|    if (!imageFile.isOpen()) | ||||
|    { | ||||
|       logger_->error("Could not open image: {}", imagePath); | ||||
|       return std::move(image); | ||||
|       return image; | ||||
|    } | ||||
| 
 | ||||
|    boost::iostreams::stream<util::IoDeviceSource> dataStream(imageFile); | ||||
|  | @ -275,10 +275,10 @@ TextureAtlas::Impl::LoadImage(const std::string& imagePath) | |||
|    catch (const std::exception& ex) | ||||
|    { | ||||
|       logger_->error("Error reading image: {}", ex.what()); | ||||
|       return std::move(image); | ||||
|       return image; | ||||
|    } | ||||
| 
 | ||||
|    return std::move(image); | ||||
|    return image; | ||||
| } | ||||
| 
 | ||||
| TextureAtlas& TextureAtlas::Instance() | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue
	
	 Dan Paulat
						Dan Paulat