From d04c206f3062e9881df909a961cf9569ced3e9bc Mon Sep 17 00:00:00 2001 From: hedaoyuan Date: Tue, 6 Dec 2016 00:59:09 +0800 Subject: [PATCH] remove the 'using namespace paddle;' in the test files --- paddle/math/tests/PerfUtils.h | 1 + paddle/math/tests/test_Tensor.cu | 9 +++++++-- paddle/math/tests/test_lazyAssign.cu | 5 +++-- 3 files changed, 11 insertions(+), 4 deletions(-) diff --git a/paddle/math/tests/PerfUtils.h b/paddle/math/tests/PerfUtils.h index 51e46bb62d9..c32f4c634a6 100644 --- a/paddle/math/tests/PerfUtils.h +++ b/paddle/math/tests/PerfUtils.h @@ -22,6 +22,7 @@ limitations under the License. */ #else #include "paddle/utils/Stat.h" +using namespace paddle; // NOLINT #define EXPRESSION_PERFORMANCE(expression) \ do { \ diff --git a/paddle/math/tests/test_Tensor.cu b/paddle/math/tests/test_Tensor.cu index 343e0631f60..8fa402055a6 100644 --- a/paddle/math/tests/test_Tensor.cu +++ b/paddle/math/tests/test_Tensor.cu @@ -16,8 +16,13 @@ limitations under the License. */ #include "paddle/math/Matrix.h" #include "TensorCheck.h" -using namespace paddle; // NOLINT -using namespace std; // NOLINT +using paddle::Matrix; +using paddle::CpuMatrix; +using paddle::GpuMatrix; +using paddle::CpuVector; +using paddle::GpuVector; +using paddle::CpuIVector; +using paddle::GpuIVector; using autotest::TensorCheckEqual; using autotest::TensorCheckErr; diff --git a/paddle/math/tests/test_lazyAssign.cu b/paddle/math/tests/test_lazyAssign.cu index de76976620b..52dfdacffe3 100644 --- a/paddle/math/tests/test_lazyAssign.cu +++ b/paddle/math/tests/test_lazyAssign.cu @@ -18,8 +18,9 @@ limitations under the License. */ #include "TensorCheck.h" #include "PerfUtils.h" -using namespace paddle; // NOLINT -using namespace std; // NOLINT +using paddle::BaseMatrix; +using paddle::CpuMatrix; +using paddle::GpuMatrix; using autotest::TensorCheckEqual; using autotest::TensorCheckErr; -- GitLab