Recently for my project I made the switch from VS 2010 to VS 2012 to take advantage of some of the newer features it offers, but I've seem to run into an interesting issue I can't seem to figure out.
Currently right now I am trying to build the TextureHolder from the sfml game dev book
namespace Textures
{
enum ID
{
Skeleton
};
}
class TextureHolder
{
public:
void Load(Textures::ID id, const std::string& filename);
sf::Texture& Get(Textures::ID id);
const sf::Texture& Get(Textures::ID id) const;
private:
std::map<Textures::ID, std::unique_ptr<sf::Texture>> mTextureMap;
};
Pretty Straight forward stuff. But on use I get this error:
error C2248: 'std::unique_ptr<_Ty>::unique_ptr' : cannot access private member declared in class 'std::unique_ptr<_Ty>.
So I investigated this little issue, which appears that the pairing of the std::map is trying to copy over the unique_ptr, which is illegal. I looked into this but couldn't find one single answer as to what was going on. Apparently the issue might be my compiler using old libs? I have tried full uninstalls/re-installs, full repairs, creating a new Empty Project and bringing in all my files individually - everything I can think of.
I've exhausted my resources so now I turn to all of you... I hope one of you has an answer.
Also I would give you all a complete and minimal example, but I believe this to be a compiler issue... but I could be completely wrong, who knows.