Skip to content

Commit

Permalink
add documentation for /Zi flag
Browse files Browse the repository at this point in the history
  • Loading branch information
wusatosi committed Jan 9, 2025
1 parent 58b5b05 commit ae2f060
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions cmake/msvc-toolchain.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,8 @@ set(CMAKE_C_COMPILER cl)
set(CMAKE_CXX_COMPILER cl)

if(BEMAN_BUILDSYS_SANITIZER STREQUAL "MaxSan")
# /Zi flag (add debug symbol) is needed when using address sanitizer
# See C5072: https://learn.microsoft.com/en-us/cpp/error-messages/compiler-warnings/compiler-warning-c5072
set(SANITIZER_FLAGS "/fsanitize=address /Zi")
endif()

Expand Down

0 comments on commit ae2f060

Please sign in to comment.