[llvm] 63b1582 - LangRef: note that `allockind("free")` requires void return
Augie Fackler via llvm-commits
llvm-commits at lists.llvm.org
Tue Jul 26 07:10:27 PDT 2022
Author: Augie Fackler
Date: 2022-07-26T10:10:14-04:00
New Revision: 63b15823505aed9870e797ab8562bbee1a701172
URL: https://github.com/llvm/llvm-project/commit/63b15823505aed9870e797ab8562bbee1a701172
DIFF: https://github.com/llvm/llvm-project/commit/63b15823505aed9870e797ab8562bbee1a701172.diff
LOG: LangRef: note that `allockind("free")` requires void return
Otherwise we have to work pretty hard to ensure a discarded alloc/free
pair doesn't remove a return value that's still useful.
Differential Revision: https://reviews.llvm.org/D130568
Added:
Modified:
llvm/docs/LangRef.rst
Removed:
################################################################################
diff --git a/llvm/docs/LangRef.rst b/llvm/docs/LangRef.rst
index 53df75b920472..bc1f63f272f3d 100644
--- a/llvm/docs/LangRef.rst
+++ b/llvm/docs/LangRef.rst
@@ -1593,6 +1593,7 @@ example:
will match that of the ``allocptr`` argument and the ``allocptr``
argument is invalidated, even if the function returns the same address.
* "free": the function frees the block of memory specified by ``allocptr``.
+ Functions marked as "free" ``allockind`` must return void.
* "uninitialized": Any newly-allocated memory (either a new block from
a "alloc" function or the enlarged capacity from a "realloc" function)
will be uninitialized.
More information about the llvm-commits
mailing list