From: Willem Jan Withagen Date: Sat, 14 Nov 2020 17:11:05 +0000 (+0100) Subject: test/librbd/crypto: Fixup include order to prevent implicit definitions X-Git-Tag: v16.1.0~586^2 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=refs%2Fpull%2F38081%2Fhead;p=ceph.git test/librbd/crypto: Fixup include order to prevent implicit definitions Clang complains a lot, part of it: ``` /home/jenkins/workspace/ceph-master-compile/src/test/librbd/crypto/test_mock_CryptoObjectDispatch.cc:35:8: error: explicit specialization of 'librbd::io::CopyupRequest' after instantiation struct CopyupRequest { ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ /home/jenkins/workspace/ceph-master-compile/src/librbd/io/ObjectRequest.cc:560:10: note: implicit instantiation first required here if (it == image_ctx->copyup_list.end()) { ^ /home/jenkins/workspace/ceph-master-compile/src/test/librbd/crypto/test_mock_CryptoObjectDispatch.cc:54:32: error: template specialization requires 'template<>' librbd::MockImageCtx>::s_instance = nullptr; ``` fixes: https://github.com/ceph/ceph/pull/37916 Signed-off-by: Willem Jan Withagen --- diff --git a/src/test/librbd/crypto/test_mock_CryptoObjectDispatch.cc b/src/test/librbd/crypto/test_mock_CryptoObjectDispatch.cc index 805a83d75bd..cfcd92e5184 100644 --- a/src/test/librbd/crypto/test_mock_CryptoObjectDispatch.cc +++ b/src/test/librbd/crypto/test_mock_CryptoObjectDispatch.cc @@ -15,9 +15,9 @@ template bool librbd::io::util::trigger_copyup( MockImageCtx *image_ctx, uint64_t object_no, IOContext io_context, Context* on_finish); -#include "librbd/io/ObjectRequest.cc" template class librbd::io::ObjectWriteRequest; template class librbd::io::AbstractObjectWriteRequest; +#include "librbd/io/ObjectRequest.cc" namespace librbd {