RESOLVED FIXED271005
[WPE][GTK] Fix clang warning about use of variable length arrays in C++
https://bugs.webkit.org/show_bug.cgi?id=271005
Summary [WPE][GTK] Fix clang warning about use of variable length arrays in C++
Michael Catanzaro
Reported 2024-03-14 14:14:20 PDT
[34/83] Building CXX object Tools/TestWebKitAPI/glib/CMakeFile...tWebContext.dir/__/Tests/WebKitGLib/TestWebKitWebContext.cpp.o /home/mcatanzaro/Projects/WebKit/Tools/TestWebKitAPI/Tests/WebKitGLib/TestWebKitWebContext.cpp:382:34: warning: variable length arrays in C++ are a Clang extension [-Wvla-cxx-extension] 382 | GRefPtr<WebKitWebView> views[numIterations]; | ^~~~~~~~~~~~~ /home/mcatanzaro/Projects/WebKit/Tools/TestWebKitAPI/Tests/WebKitGLib/TestWebKitWebContext.cpp:382:34: note: read of non-const variable 'numIterations' is not allowed in a constant expression /home/mcatanzaro/Projects/WebKit/Tools/TestWebKitAPI/Tests/WebKitGLib/TestWebKitWebContext.cpp:381:9: note: declared here 381 | int numIterations = 25; | ^ 1 warning generated.
Attachments
Michael Catanzaro
Comment 1 2024-03-14 15:34:37 PDT
EWS
Comment 2 2024-03-15 09:49:18 PDT
Committed 276168@main (d02f043164f2): <https://commits.webkit.org/276168@main> Reviewed commits have been landed. Closing PR #25911 and removing active labels.
Note You need to log in before you can comment on or make changes to this bug.