summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJens Geyer <jensg@apache.org>2020-12-09 21:56:21 +0100
committerJens Geyer <jensg@apache.org>2020-12-09 22:05:36 +0100
commit494a845dd972fc0e68f6937e27ae74efd444b848 (patch)
treead9e420c0c4aabec72d6c7d1a9916843ee374083
parent10f2556733b8ee34f2c3695f09c1dff717fdafc8 (diff)
downloadthrift-494a845dd972fc0e68f6937e27ae74efd444b848.tar.gz
THRIFT-5198 Fix certain Visual Studio hints in generated netstd code
Client: netstd Patch: Jens Geyer
-rw-r--r--compiler/cpp/src/thrift/generate/t_netstd_generator.cc6
1 files changed, 4 insertions, 2 deletions
diff --git a/compiler/cpp/src/thrift/generate/t_netstd_generator.cc b/compiler/cpp/src/thrift/generate/t_netstd_generator.cc
index ea4778287..b90f71a3d 100644
--- a/compiler/cpp/src/thrift/generate/t_netstd_generator.cc
+++ b/compiler/cpp/src/thrift/generate/t_netstd_generator.cc
@@ -333,7 +333,10 @@ void t_netstd_generator::reset_indent() {
void t_netstd_generator::start_netstd_namespace(ostream& out)
{
- out << "#pragma warning disable IDE1006 // parts of the code use IDL spelling" << endl;
+ out << "#pragma warning disable IDE0079 // remove unnecessary pragmas" << endl
+ << "#pragma warning disable IDE1006 // parts of the code use IDL spelling" << endl
+ << endl;
+
if (!namespace_name_.empty())
{
out << "namespace " << namespace_name_ << endl;
@@ -347,7 +350,6 @@ void t_netstd_generator::end_netstd_namespace(ostream& out)
{
scope_down(out);
}
- out << "#pragma warning restore IDE1006" << endl;
}
string t_netstd_generator::netstd_type_usings() const