Copilot commented on code in PR #13310:
URL: https://github.com/apache/trafficserver/pull/13310#discussion_r3455697318


##########
src/tsutil/CMakeLists.txt:
##########
@@ -80,9 +81,19 @@ if(BUILD_TESTING)
     unit_tests/test_StringConvert.cc
     unit_tests/test_Regex.cc
     unit_tests/test_ts_meta.cc
+    unit_tests/test_thread_safety.cc
     unit_tests/test_time_parser.cc
   )
 
+  # The thread-safety test doubles as a compile-time check: under Clang, build 
it
+  # with the analysis enabled and treat any finding as an error so a broken
+  # annotation chain fails the build. A no-op for GCC (the macros expand to
+  # nothing there).
+  set_source_files_properties(
+    unit_tests/test_thread_safety.cc PROPERTIES COMPILE_OPTIONS
+                                                
"$<$<CXX_COMPILER_ID:Clang>:-Wthread-safety;-Werror=thread-safety>"
+  )

Review Comment:
   The `COMPILE_OPTIONS` property value contains a semicolon inside a generator 
expression. CMake treats `;` as a list separator, so this will be split into 
two separate options (the second becoming `-Werror=thread-safety>`), which can 
break the build. Pass each option as its own generator expression (or escape 
the semicolon).



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to