|
|
|
|
|
by thomasahle
2123 days ago
|
|
If anyone wants to know more about const fns, see https://doc.rust-lang.org/reference/items/functions.html#con... It is the Rust way of specifying a function as being _pure_.
In other words the output is dependent only on the function arguments, and not on any external state. This means they can be evaluated at compile time.
I suppose in the future, it could also allow better compiler optimizations. |
|