Ask HN: Is there a name for the concept of "value changes upon read"?

https://news.ycombinator.com/item?id=4170600
by uvTwitch • 14 years ago
5 9 14 years ago

I'm trying to think of a name to use to describe a value which will reliably change upon being read. Not the nature of the change, but naming this concept of change-upon-read.

For example, I have this, complete with syntax error: class Alternator{ bool value; implicit cast(bool) { get { return value = !value; } } }

I know that this phenomenon exists in quantum physics - that the state of a particle will change due to the act of reading the particle's state - but I don't know if there is a term for it, though if there is it would be ideal.

I figure naming it is important, because otherwise i'm left with mystery object with dodgy tacit behaviour, which is not cool for the uninitiated.

Related Stories

Loading related stories...

Source preview

news.ycombinator.com