Skip to content

Commit 753d735

Browse files
author
ripley
committed
mention NORET, with caveats
git-svn-id: https://svn.r-project.org/R/trunk@87759 00db46b3-68df-0310-9c12-caf00c1e9a41
1 parent 6b2742a commit 753d735

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

doc/manual/R-exts.texi

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15179,6 +15179,14 @@ These are defined in header @file{R_ext/Error.h} included by @file{R.h}.
1517915179
@strong{NB}: when @code{R_NO_REMAP} is defined (as is done for
1518015180
C++ code), @code{Rf_error} etc must be used.
1518115181

15182+
Header @file{R_ext/Error.h} defines a macro @code{NORET} intended to be
15183+
used only from C code (C++ code can use the @code{[[noreturn]]}
15184+
attribute). This covers various ways to signal to the compiler that the
15185+
function never returns. Because the usages of those ways differ by C
15186+
standard, it should always be used at the beginning of a function
15187+
declaration, including before @code{static} and attributes such as
15188+
@code{attribute_hidden}.
15189+
1518215190

1518315191
@c 1-item menu: kept to avoid spurious warning from makeinfo 6.8/7.0
1518415192
@menu

0 commit comments

Comments
 (0)