Disable more of the pragma warning stuff (#64899)
authorEdward Yang <ezyang@fb.com>
Mon, 13 Sep 2021 17:53:06 +0000 (10:53 -0700)
committerFacebook GitHub Bot <facebook-github-bot@users.noreply.github.com>
Mon, 13 Sep 2021 17:58:31 +0000 (10:58 -0700)
Summary:
Pull Request resolved: https://github.com/pytorch/pytorch/pull/64899

ghstack-source-id: 137882055

Test Plan: sandcastle, ossci

Reviewed By: malfet, ngimel

Differential Revision: D30893691

fbshipit-source-id: 67ec8cc9f212aa16a201771603236e429944b561

aten/src/ATen/core/TensorBase.h
aten/src/ATen/templates/TensorBody.h

index e91e9e1..352aef9 100644 (file)
@@ -755,12 +755,6 @@ private:
   TensorBase __dispatch_contiguous(c10::MemoryFormat) const;
 };
 
-// For "multiple ... operators specified" warnings, closing brace of class
-// declaration must be included between pragma push & pop
-#ifdef _MSC_VER
-#pragma warning( pop )
-#endif
-
 inline int64_t get_device(const TensorBase& self) {
   return self.get_device();
 }
index eb6402f..a8d1b7a 100644 (file)
@@ -167,11 +167,8 @@ class TORCH_API Tensor: public TensorBase {
   // Also MSVC will wrongly issue the following warning with the aforementioned fix
   //    warning C4522: 'at::Tensor': multiple assignment operators specified
   // Let's just skip the warning.
-
-  #ifdef _MSC_VER
-  #pragma warning( push )
-  #pragma warning( disable : 4522 )
-  #endif
+  //
+  // TODO: temporarily disabled
 
   Tensor& operator=(const TensorBase& x) & {
     impl_ = x.getIntrusivePtr();
@@ -560,12 +557,6 @@ class TORCH_API Tensor: public TensorBase {
   }
 };
 
-// For "multiple ... operators specified" warnings, closing brace of class
-// declaration must be included between pragma push & pop
-#ifdef _MSC_VER
-#pragma warning( pop )
-#endif
-
 namespace detail {
 // Helper creator for Tensor class which doesn't requires the users to pass
 // in an intrusive_ptr instead it just converts the argument passed to