Ruby 4.1.0dev (2026-10-03 revision 1b0fb238e012e17a8cbccb54c885af593c2b5f28)
Macros
nonnull.h File Reference

(1b0fb238e012e17a8cbccb54c885af593c2b5f28)

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

Go to the source code of this file.

Macros

#define PRISM_NONNULL(...)   __attribute__((__nonnull__(__VA_ARGS__)))
 Mark the parameters of a function as non-null.
 

Macro Definition Documentation

◆ PRISM_NONNULL

#define PRISM_NONNULL (   ...)    __attribute__((__nonnull__(__VA_ARGS__)))

Mark the parameters of a function as non-null.

This allows the compiler to warn if a caller passes NULL for a parameter that should never be NULL. The arguments are the 1-based indices of the parameters.

Definition at line 13 of file nonnull.h.