-1
コード:エラーLNK2019 2013
template <typename T>
class Graf
{
vector < vector <T> > Mat;
int n, m;
public:
friend istream& operator >>(istream& Read, Graf <T> &Object); // this is where I get the error
friend ostream& operator <<(ostream& Show, Graf <T> &Object); // here too, when I try to display an object
Graf() : Mat(MAX_NODES, vector<T>(MAX_NODES)), n(0), m(0) {}
};
#include "graf_implementation.h"
i "はcinを>> G" しようとすると、私はこれは本当に厄介なエラーが発生します。
ostream<char,struct std::char_traits<char> > & __cdecl operator<<(class std::basic_ostream<char,struct std::char_traits<char> > &,class Graf<int> &)" ([email protected][email protected][email protected]@[email protected]@@[email protected]@[email protected][email protected]@@@Z) referenced in function _main
[定義されていない参照/未解決の外部シンボルエラーとは何ですか?どうすれば修正できますか?](http://stackoverflow.com/questions/12573816/what-is-an-undefined-reference-unresolved-外部記号エラー・アンド・ハウ・ド・イ・フィックス) –