pub struct CalcParseFlags {
pub percentage_context: PercentageContext,
pub color_components: ChannelKeyword,
pub additional_functions: AdditionalFunctions,
pub in_place_operations: CalcNodeParseInPlaceOperations,
}Expand description
What is allowed to be parsed for math functions within in this context?
Fields§
§percentage_context: PercentageContextWhether percentages are allowed in this context, and what numeric type they are relative to. Used both to control parsing as well as to type check calculation trees.
color_components: ChannelKeywordWhich relative color components, if any, are allowed.
additional_functions: AdditionalFunctionsAdditional functions allowed to be parsed in this context.
in_place_operations: CalcNodeParseInPlaceOperationsWhether or not in place operations should be performed. Normally, we aggressive simplify via in-place operations, but it is disabled for generating a trace of steps.
Implementations§
Source§impl CalcParseFlags
impl CalcParseFlags
Sourcepub fn new(percentage_context: PercentageContext) -> Self
pub fn new(percentage_context: PercentageContext) -> Self
Builds parse flags with the given percentage calculation context.
Trait Implementations§
Source§impl Clone for CalcParseFlags
impl Clone for CalcParseFlags
Source§fn clone(&self) -> CalcParseFlags
fn clone(&self) -> CalcParseFlags
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Default for CalcParseFlags
impl Default for CalcParseFlags
impl Copy for CalcParseFlags
Auto Trait Implementations§
impl Freeze for CalcParseFlags
impl RefUnwindSafe for CalcParseFlags
impl Send for CalcParseFlags
impl Sync for CalcParseFlags
impl Unpin for CalcParseFlags
impl UnsafeUnpin for CalcParseFlags
impl UnwindSafe for CalcParseFlags
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§impl<T> MaybeBoxed<Box<T>> for T
impl<T> MaybeBoxed<Box<T>> for T
Source§fn maybe_boxed(self) -> Box<T>
fn maybe_boxed(self) -> Box<T>
Convert
Source§impl<T> MaybeBoxed<T> for T
impl<T> MaybeBoxed<T> for T
Source§fn maybe_boxed(self) -> T
fn maybe_boxed(self) -> T
Convert