AngouriMath

Navigation

SettingsState


← Back to list of classes

Description

Summary

What every setting reads as, taken together, so that something holding a result computed
under the settings of a moment can tell whether those settings still hold.

Remarks

A state and not a change count. Counting changes looks equivalent and is not: a
scope opened and closed leaves every setting exactly as it found it while moving a
counter twice, and the library opens such scopes constantly — a single
Simplify of one unevaluated integral opened 3520 of them, all four from
numeric downcasting in Number/Operators.cs. A counter therefore reports
"everything has changed" continuously and is useless to a cache. Measured, not assumed:
the counter was built first and threw away the whole benefit.
The state of one setting is the reference to the frame on top of its stack, which
is exact rather than a hash — releasing a scope restores the very frame object that was
there before it, since the chain below a pushed frame is never rebuilt. So comparing
snapshots is a handful of reference comparisons with no chance of collision, and a
balanced open-and-close compares equal, which is the whole point.

Members

























Angouri © 2019-2023 · Project's repo · Site's repo · Octicons · Transparency · 4378 pages online