Skip to content

Commit 05560ef

Browse files
authored
FEAT: Enforce Level 3 and 4 warnings as errors to adhere to compliance standards. (#78)
This pull request introduces a platform-specific enhancement to the build configuration for `ddbc_bindings` in the `CMakeLists.txt` file. It adds stricter warning level flags for MSVC to improve code quality. Build configuration improvement: * [`mssql_python/pybind/CMakeLists.txt`](diffhunk://#diff-dbb5892fbbb28149d1639664797cf3adb48ced28ec11aba95f2e2b338ca46badR289-R294): Added a conditional block to apply `/W4` (warning level 4) and `/WX` (treat warnings as errors) compiler flags when building with MSVC. This ensures stricter code quality checks for Windows builds.
1 parent 8899355 commit 05560ef

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

mssql_python/pybind/CMakeLists.txt

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -286,6 +286,11 @@ target_compile_definitions(ddbc_bindings PRIVATE
286286
NOMINMAX
287287
)
288288

289+
# Add warning level flags for MSVC
290+
if(MSVC)
291+
target_compile_options(ddbc_bindings PRIVATE /W4 /WX)
292+
endif()
293+
289294
# Add macOS-specific string conversion fix
290295
if(APPLE)
291296
message(STATUS "Enabling macOS string conversion fix")

0 commit comments

Comments
 (0)