Closed dead-claudia closed 1 month ago
Other designs could be possible, but I just want to make sure there's a way to define such a virtualized value that's always checked but possibly externally determined.
Honestly not sure this is the right way to go, so I'm closing it.
The idea is for things like
localStorage
, which often lack ways to know when it's updated. They'd also come in handy in embedded, since it's common to see an SMBus event or pin update for "state changed", but you still have to explicitly poll to know what changed.Here's an explainer:
External
signal is checked for dirtiness, it's computed and the value checked..get()
on a signal, all its dependentExternal
signals are also checked. (You can optimize the back references to signals down to shared cells, to avoid memory leaks. It's just a boolean flag.)