From: Hwankyu Jhun Date: Wed, 2 May 2018 08:19:52 +0000 (+0900) Subject: Add annotations about namespace X-Git-Tag: accepted/tizen/4.0/unified/20180514.093956~2 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=5f32a0ecb8849d273b70068c6582bb1932cf5f71;p=platform%2Fcore%2Fappfw%2Ftidl.git Add annotations about namespace Change-Id: I17f5a1cf961d31ac7cfec19574f9d57c77c6c7ab Signed-off-by: Hwankyu Jhun --- diff --git a/idlc/cpp_gen/cpp_proxy_body_gen.cc b/idlc/cpp_gen/cpp_proxy_body_gen.cc index 4c689a9..8226991 100644 --- a/idlc/cpp_gen/cpp_proxy_body_gen.cc +++ b/idlc/cpp_gen/cpp_proxy_body_gen.cc @@ -59,9 +59,12 @@ void CppProxyBodyGen::GenNamespace(std::ofstream& stream) { GenDeSerializer(stream); GenListSerializer(stream); GenInterfaces(stream); - }, false); - }, false); - }, false); + }, false, false); + stream << " // namespace proxy" + NLine(1); + }, false, false); + stream << " // namespace " + GetFileNamespace() + NLine(1); + }, false, false); + stream << " // namespace rpc_port" + NLine(1); } void CppProxyBodyGen::GenInterfaces(std::ofstream& stream) { diff --git a/idlc/cpp_gen/cpp_proxy_header_gen.cc b/idlc/cpp_gen/cpp_proxy_header_gen.cc index 001e93b..91a2b18 100644 --- a/idlc/cpp_gen/cpp_proxy_header_gen.cc +++ b/idlc/cpp_gen/cpp_proxy_header_gen.cc @@ -45,9 +45,12 @@ void CppProxyHeaderGen::GenNamespace(std::ofstream& stream) { GenBrace(stream, 0, [&]() { GenExceptions(stream); GenInterfaces(stream); - }, false); - }, false); - }, false); + }, false, false); + stream << " // namespace proxy" + NLine(1); + }, false, false); + stream << " // namespace " + GetFileNamespace() + NLine(1); + }, false, false); + stream << " // namespace rpc_port" + NLine(1); } void CppProxyHeaderGen::GenExceptions(std::ofstream& stream) { diff --git a/idlc/cpp_gen/cpp_stub_body_gen.cc b/idlc/cpp_gen/cpp_stub_body_gen.cc index 7d4ca48..e5b428b 100644 --- a/idlc/cpp_gen/cpp_stub_body_gen.cc +++ b/idlc/cpp_gen/cpp_stub_body_gen.cc @@ -58,9 +58,12 @@ void CppStubBodyGen::GenNamespace(std::ofstream& stream) { GenDeSerializer(stream); GenListSerializer(stream); GenInterfaces(stream); - }, false); - }, false); - }, false); + }, false, false); + stream << " // namespace stub" + NLine(1); + }, false, false); + stream << " // namespace " + GetFileNamespace() + NLine(1); + }, false, false); + stream << " // namespace rpc_port" + NLine(1); } void CppStubBodyGen::GenInterfaces(std::ofstream& stream) { diff --git a/idlc/cpp_gen/cpp_stub_header_gen.cc b/idlc/cpp_gen/cpp_stub_header_gen.cc index f451631..c2d4d4f 100644 --- a/idlc/cpp_gen/cpp_stub_header_gen.cc +++ b/idlc/cpp_gen/cpp_stub_header_gen.cc @@ -45,9 +45,12 @@ void CppStubHeaderGen::GenNamespace(std::ofstream& stream) { GenBrace(stream, 0, [&]() { GenExceptions(stream); GenInterfaces(stream); - }, false); - }, false); - }, false); + }, false, false); + stream << " // namespace stub" + NLine(1); + }, false, false); + stream << " // namespace " + GetFileNamespace() + NLine(1); + }, false, false); + stream << " // namespace rpc_port" + NLine(1); } void CppStubHeaderGen::GenExceptions(std::ofstream& stream) {