On Wed, 25 Feb 2026 14:04:40 GMT, SendaoYan <[email protected]> wrote:

> Hi all,
> 
> clang23+gcc12(ubuntu) generate compiler warning 
> "get_temporary_buffer<testing::TestInfo *>' is deprecated 
> [-Werror,-Wdeprecated-declarations]". And this compiler warning from 
> googletest file googletest/src/gtest.cc, googletest/src/gtest.cc invoke 
> `std::stable_sort`, and `std::stable_sort` invoke deprecated 
> `std::get_temporary_buffer`. So this warning is unrelated to JDK totally.
> 
> This PR disable deprecated-declarations warning when building libgtest. 
> Change has been verified locally.

This pull request has now been integrated.

Changeset: f4da2d56
Author:    SendaoYan <[email protected]>
URL:       
https://git.openjdk.org/jdk/commit/f4da2d56b7785569e1b88625bb766675b20438cc
Stats:     4 lines in 1 file changed: 4 ins; 0 del; 0 mod

8378684: Fix -Wdeprecated-declarations warnings from gtest by clang23

Reviewed-by: erikj, kbarrett

-------------

PR: https://git.openjdk.org/jdk/pull/29919

Reply via email to