Skip to content

Commit e5751c9

Browse files
authored
Merge pull request #484 from oli-obk/patch-2
Update `unsafe` in const functions documentation
2 parents 2a487bd + 9cdf6e8 commit e5751c9

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/items/functions.md

+3-3
Original file line numberDiff line numberDiff line change
@@ -185,9 +185,9 @@ Exhaustive list of permitted structures in const functions:
185185
* Reading from constants (but not statics, not even taking a reference to a static)
186186
* `&` and `*` (only dereferencing of references, not raw pointers)
187187
* Casts except for raw pointer to integer casts
188-
* `const unsafe fn` is allowed, but the body must consist of safe operations
189-
only and you won't be able to call the `const unsafe fn` from within another
190-
const function even if you use `unsafe`
188+
* `unsafe` blocks and `const unsafe fn` are allowed, but the body/block may only do
189+
the following unsafe operations:
190+
* calls to const unsafe functions
191191

192192
## Attributes on functions
193193

0 commit comments

Comments
 (0)