RESOLVED FIXED304063
REGRESSION(304354@main) GLIB build failure without assertions due to wrong WARN_UNUSED_RETURN
https://bugs.webkit.org/show_bug.cgi?id=304063
Summary REGRESSION(304354@main) GLIB build failure without assertions due to wrong WA...
Lauro Moura
Reported 2025-12-12 06:12:41 PST
Error: In file included from ../../../Source/WTF/wtf/Platform.h:31, from ../../../Source/WTF/wtf/ExportMacros.h:32, from ../../../Source/WTF/config.h:26, from ../../../Source/WTF/wtf/glib/GMallocString.cpp:29: ../../../Source/WTF/wtf/Compiler.h:427:40: error: ‘nodiscard’ attribute can only be applied to functions or to class or enumeration types [-Werror=attributes] 427 | #define WARN_UNUSED_RETURN [[nodiscard]] // NOLINT: check-webkit-style does not understand annotations. | ^ ../../../Source/WTF/wtf/glib/GMallocString.h:98:22: note: in expansion of macro ‘WARN_UNUSED_RETURN’ 98 | char* leakUTF8() WARN_UNUSED_RETURN { return byteCast<char>(m_spanWithNullTerminator.leakSpan().data()); } | ^~~~~~~~~~~~~~~~~~ cc1plus: all warnings being treated as errors Patch incoming.
Attachments
Lauro Moura
Comment 1 2025-12-12 06:21:18 PST
EWS
Comment 2 2025-12-12 07:38:34 PST
Committed 304358@main (6e51015952ca): <https://commits.webkit.org/304358@main> Reviewed commits have been landed. Closing PR #55308 and removing active labels.
Radar WebKit Bug Importer
Comment 3 2025-12-12 07:39:12 PST
Lauro Moura
Comment 4 2025-12-12 08:05:02 PST
Originally, the PR at https://github.com/WebKit/WebKit/pull/55277 (that became 304354@main) used 304328@main, giving a green bubble: https://ews-build.webkit.org/#/builders/5/builds/142781 But the GMallocString.h was added in 304343@main, so we did not have the chance to test both in EWS before landing.
Note You need to log in before you can comment on or make changes to this bug.