[bazel] Add -Wno-vla-cxx-extension to macOS lldb srcs (#185945)

```
lldb/tools/debugserver/source/MacOSX/MachVMMemory.cpp:88:20: warning: variable length arrays in C++ are a Clang extension [-Wvla-cxx-extension]
   88 |   int dispositions[dispositions_size];
      |                    ^~~~~~~~~~~~~~~~~
```

This code contains objc++ which can only be compiled with clang anyways.
This commit is contained in:
Keith Smiley 2026-03-11 11:59:55 -07:00 committed by GitHub
parent ed42ac3c4c
commit cfcc50a732
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 7 additions and 0 deletions

View File

@ -979,6 +979,9 @@ cc_library(
["tools/debugserver/source/**/*.cpp"],
exclude = ["tools/debugserver/source/debugserver.cpp"],
),
copts = [
"-Wno-vla-cxx-extension",
],
local_defines = ["LLDB_USE_OS_LOG"],
tags = ["nobuildkite"],
deps = [
@ -1022,6 +1025,9 @@ cc_binary(
":debugserver_version_gen",
":mach_gen",
],
copts = [
"-Wno-vla-cxx-extension",
],
tags = ["nobuildkite"],
target_compatible_with = select({
"@platforms//os:macos": [],

View File

@ -103,4 +103,5 @@ OBJCPP_COPTS = [
"-std=c++{}".format(CMAKE_CXX_STANDARD),
"-fno-objc-exceptions",
"-Wno-shorten-64-to-32",
"-Wno-vla-cxx-extension",
]