pub enum BuiltinMacroFunction {
Min,
Max,
Mod,
CubicBezier,
Rgb,
Debug,
}
Expand description
A builtin function which is handled by the compiler pass
Builtin function expect their arguments in one and a specific type, so that’s easier for the generator. Macro however can do some transformation on their argument.
Variants§
Min
Transform min(a, b, c, ..., z)
into a series of conditional expression and comparisons
Max
Transform max(a, b, c, ..., z)
into a series of conditional expression and comparisons
Mod
Add the right conversion operations so that the return type is the same as the argument type
CubicBezier
Rgb
The argument can be r,g,b,a or r,g,b and they can be percentages or integer. transform the argument so it is always rgb(r, g, b, a) with r, g, b between 0 and 255.
Debug
transform debug(a, b, c)
into debug a + " " + b + " " + c
Trait Implementations§
source§impl Clone for BuiltinMacroFunction
impl Clone for BuiltinMacroFunction
source§fn clone(&self) -> BuiltinMacroFunction
fn clone(&self) -> BuiltinMacroFunction
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read more