Skip to content

Commit

Permalink
Revert "remove 4996 in nv_includes.h & test_main.cc"
Browse files Browse the repository at this point in the history
This reverts commit facd228.
  • Loading branch information
yf711 committed Jun 17, 2024
1 parent 663c8b7 commit 4e99543
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
9 changes: 4 additions & 5 deletions onnxruntime/core/providers/tensorrt/nv_includes.h
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,11 @@
// Licensed under the MIT License.
#pragma once

// File to include the required TRT headers with workarounds for warnings we can't fix.

// Ignore warning C4100: unreferenced formal parameter
// File to include the required TRT headers with workarounds for warnings we can't fix or not fixed yet.
#if defined(_MSC_VER)
#pragma warning(push)
#pragma warning(disable : 4100)
#pragma warning(disable : 4100) // Ignore warning C4100: unreferenced formal parameter
#pragma warning(disable : 4996) // Ignore warning C4996: 'nvinfer1::IPluginV2' was declared deprecated
#endif

#include <NvInfer.h>
Expand All @@ -17,4 +16,4 @@

#if defined(_MSC_VER)
#pragma warning(pop)
#endif
#endif
1 change: 1 addition & 0 deletions onnxruntime/test/unittest_main/test_main.cc
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ void ortenv_setup() {
#if defined(_MSC_VER)
#pragma warning(push)
#pragma warning(disable : 4100) // Ignore warning C4100: unreferenced format parameter.
#pragma warning(disable : 4996) // Ignore warning C4996: 'nvinfer1::IPluginV2' was declared deprecated
#endif

// TensorRT will load/unload libraries as builder objects are created and torn down. This will happen for
Expand Down

0 comments on commit 4e99543

Please sign in to comment.