Limit the comparison functions to have file scope
authorKai Li <kaili_kloud@163.com>
Fri, 11 Jul 2014 02:22:01 +0000 (10:22 +0800)
committerKai Li <kaili_kloud@163.com>
Sat, 19 Jul 2014 16:26:41 +0000 (00:26 +0800)
src/caffe/layers/accuracy_layer.cpp
src/caffe/layers/argmax_layer.cpp

index 86ded06..916059e 100644 (file)
@@ -31,7 +31,7 @@ void AccuracyLayer<Dtype>::SetUp(
 }
 
 template<typename Dtype>
-bool int_Dtype_pair_greater(std::pair<int, Dtype> a,
+static bool int_Dtype_pair_greater(std::pair<int, Dtype> a,
                             std::pair<int, Dtype> b) {
   return a.second > b.second;
 }
index 44476cc..580e4b0 100644 (file)
@@ -30,7 +30,7 @@ void ArgMaxLayer<Dtype>::SetUp(const vector<Blob<Dtype>*>& bottom,
 }
 
 template<typename Dtype>
-bool int_Dtype_pair_greater(std::pair<int, Dtype> a,
+static bool int_Dtype_pair_greater(std::pair<int, Dtype> a,
                             std::pair<int, Dtype> b) {
   return a.second > b.second;
 }