Prechádzať zdrojové kódy

use default implementation of special methods

Andrey Filipenkov 3 rokov pred
rodič
commit
3616827aad
4 zmenil súbory, kde vykonal 1 pridanie a 13 odobranie
  1. 1 5
      AI/VCAI/AIhelper.cpp
  2. 0 1
      AI/VCAI/AIhelper.h
  3. 0 6
      lib/Terrain.cpp
  4. 0 1
      lib/Terrain.h

+ 1 - 5
AI/VCAI/AIhelper.cpp

@@ -19,10 +19,6 @@ AIhelper::AIhelper()
 	armyManager.reset(new ArmyManager());
 }
 
-AIhelper::~AIhelper()
-{
-}
-
 bool AIhelper::notifyGoalCompleted(Goals::TSubgoal goal)
 {
 	return resourceManager->notifyGoalCompleted(goal);
@@ -182,4 +178,4 @@ std::vector<SlotInfo>::iterator AIhelper::getWeakestCreature(std::vector<SlotInf
 std::vector<SlotInfo> AIhelper::getSortedSlots(const CCreatureSet * target, const CCreatureSet * source) const
 {
 	return armyManager->getSortedSlots(target, source);
-}
+}

+ 0 - 1
AI/VCAI/AIhelper.h

@@ -36,7 +36,6 @@ class DLL_EXPORT AIhelper : public IResourceManager, public IBuildingManager, pu
 	//TODO: vector<IAbstractManager>
 public:
 	AIhelper();
-	~AIhelper();
 
 	bool canAfford(const TResources & cost) const;
 	TResources reservedResources() const override;

+ 0 - 6
lib/Terrain.cpp

@@ -201,12 +201,6 @@ Terrain::operator std::string() const
 Terrain::Terrain(const std::string & _name) : name(_name)
 {}
 	
-Terrain& Terrain::operator=(const Terrain & _name)
-{
-	name = _name.name;
-	return *this;
-}
-	
 Terrain& Terrain::operator=(const std::string & _name)
 {
 	name = _name;

+ 0 - 1
lib/Terrain.h

@@ -74,7 +74,6 @@ public:
 	
 	int id() const; //TODO: has to be completely removed
 	
-	Terrain& operator=(const Terrain & _type);
 	Terrain& operator=(const std::string & _type);
 	
 	DLL_LINKAGE friend bool operator==(const Terrain & l, const Terrain & r);