クラスの演算子のオーバーライド(ロード?)でリンカのエラーがでます

error LNK2005: "bool __cdecl operator<(double const &,class TestClass const &)" (??M@YA_NABNABVTestClass@@@Z)
はすでに foo.obj で定義されています

ヘッダファイルに直接以下のように書いているのですが、なにがダメなのでしょうか?

// 比較演算子(upper_boundで必要)
bool operator < ( const double &a, const TestClass &v )
{
  return v.x < a;
}

なぜか解りませんがinlineを付けるとエラーが出ませんでした。