Crate const_gen[][src]

Macros

const_array_declaration

Like const_declaration, but for const array types

const_array_definition

Like const_definition, but for const array types

const_declaration

A macro to help in the creation of const declarations. Allows this syntax: const_declaration!(VAR_NAME = value) This is syntactic sugar for calling the CompileConst::const_declaration function.

const_definition

A macro to help in the creation of const definitions. Allows this syntax: const_definition!(#[attribute1] #[attributeN] TypeName) This is syntactic sugar for calling the CompileConst::const_definition function.

Traits

CompileConst

Trait which defines how a type should be represented as a constant

CompileConstArray

Trait which defines how an array-representable type should be represented as a const array

Derive Macros

CompileConst

Derives the CompileConst trait for structs and enums. Requires that all fields also implement the CompileConst trait.