Ruby 4.1.0dev (2026-09-30 revision bf937bfa16767a4dd857ee16f4f18df1bae4d5ca)
Macros
nodiscard.h File Reference

(bf937bfa16767a4dd857ee16f4f18df1bae4d5ca)

This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

#define PRISM_NODISCARD   __attribute__((__warn_unused_result__))
 Mark the return value of a function as important so that the compiler warns if a caller ignores it.
 

Macro Definition Documentation

◆ PRISM_NODISCARD

#define PRISM_NODISCARD   __attribute__((__warn_unused_result__))

Mark the return value of a function as important so that the compiler warns if a caller ignores it.

This is useful for functions that return error codes or allocated resources that must be freed.

Definition at line 15 of file nodiscard.h.