Skip to content

Commit 96d41a7

Browse files
committed
Fix formatting of doc comment
1 parent 7fe82b1 commit 96d41a7

1 file changed

Lines changed: 8 additions & 4 deletions

File tree

library/core/src/arch.rs

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -80,13 +80,17 @@ pub fn breakpoint() {
8080
/// The `core::arch::return_address!()` macro returns a pointer with an address that corresponds to the caller of the function that invoked the `return_address!()` macro.
8181
/// The pointer has no provenance, as if created by `core::ptr::without_provenance`. It cannot be used to read memory (other than ZSTs).
8282
///
83-
/// The value returned by the macro depends highly on the architecture and compiler (including any options set).
84-
/// In particular, it is allowed to be wrong (particularly if inlining is involved), or even contain a nonsense value.
83+
/// The value returned by the macro depends highly on the architecture and compiler (including any options set).
84+
/// In particular, it is allowed to be wrong (particularly if inlining is involved), or even contain a nonsense value.
8585
/// The result of this macro must not be relied upon for soundness or correctness, only for debugging purposes.
86+
///
87+
/// As a best effort, if a useful value cannot be determined (for example, due to limitations on the current codegen),
88+
/// this macro tries to return a null pointer instead of nonsense (this cannot be relied upon for correctness, however).
89+
///
8690
/// Formally, this function returns a pointer with a non-deterministic address and no provenance.
87-
/// As a best effort, if a useful value cannot be determined (for example, due to limitations on the current codegen), this macro tries to return a null pointer instead of nonsense (this cannot be relied upon for correctness, however).
8891
///
89-
/// This is equivalent to the gcc `__builtin_return_address(0)` intrinsic (other forms of the intrinsic are not supported). Because the operation can be always performed by the compiler without crashing or causing undefined behaviour, invoking the macro is a safe operation.
92+
/// This is equivalent to the gcc `__builtin_return_address(0)` intrinsic (other forms of the intrinsic are not supported).
93+
/// Because the operation can be always performed by the compiler without crashing or causing undefined behaviour, invoking the macro is a safe operation.
9094
///
9195
/// ## Example
9296
/// ```

0 commit comments

Comments
 (0)