THRIFT-5198 Fix certain Visual Studio hints in generated netstd code
Client: netstd
Patch: Jens Geyer
diff --git a/compiler/cpp/src/thrift/generate/t_netstd_generator.cc b/compiler/cpp/src/thrift/generate/t_netstd_generator.cc
index ea47782..b90f71a 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::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 @@
{
scope_down(out);
}
- out << "#pragma warning restore IDE1006" << endl;
}
string t_netstd_generator::netstd_type_usings() const