[LangRef] State that a nocapture pointer cannot be returned

This is a small patch stating that a nocapture pointer cannot be returned.

Discussed in D93189.

Reviewed By: jdoerfert

Differential Revision: https://reviews.llvm.org/D94386
This commit is contained in:
Juneyoung Lee 2021-01-11 14:42:08 +09:00
parent 0c8466c001
commit 76643c48cd
1 changed files with 2 additions and 1 deletions

View File

@ -1193,7 +1193,8 @@ Currently, only the following parameter attributes are defined:
``nocapture``
This indicates that the callee does not make any copies of the
pointer that outlive the callee itself. This is not a valid
pointer that outlive the callee itself in any form such as a pointer stored
in the memory or as a return value. This is not a valid
attribute for return values. Addresses used in volatile operations
are considered to be captured.