Skip to content

Commit 58e9ca1

Browse files
Abseil Teamcopybara-github
authored andcommitted
Mark Voidify::operator&&() as no-inline.
This improves stack trace for `LOG(FATAL)` with optimization on. PiperOrigin-RevId: 770679129 Change-Id: I2c7326725d5f1749165c04d3225833fdb22191d6
1 parent 2ea5334 commit 58e9ca1

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

absl/log/internal/voidify.h

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,8 @@ class Voidify final {
3636
// This has to be an operator with a precedence lower than << but higher than
3737
// ?:
3838
template <typename T>
39-
ABSL_ATTRIBUTE_COLD void operator&&(T&& message) const&& {
39+
ABSL_ATTRIBUTE_COLD ABSL_ATTRIBUTE_NOINLINE void operator&&(
40+
T&& message) const&& {
4041
// The dispatching of the completed `absl::LogEntry` to applicable
4142
// `absl::LogSink`s happens here.
4243
message.Flush();

0 commit comments

Comments
 (0)