Module rustc_const_eval::const_eval [−][src]
Modules
Structs
Extra machine state for CTFE, and the Machine instance
When const-evaluation errors, this type is constructed with the resulting information, and then used to emit the error as a lint or hard error.
Enums
The CTFE machine has some custom error kinds.
Functions
Convert an evaluated constant to a type level constant
This function uses unwrap
copiously, because an already validated constant
must have valid fields and can thus never fail outside of compiler bugs. However, it is
invoked from the pretty printer, where it can receive enums with no variants and e.g.
read_discriminant
needs to be able to handle that.
Whether the def_id
is an unstable const fn and what feature gate is necessary to enable it