On Sep 30, 2015, at 21:13, Random832 firstname.lastname@example.org wrote:
Andrew Barnert via Python-ideas email@example.com writes:
I think the docs used to use the word "virtual" as a more specific term than "lazy": a view onto an object that conceptually exists but doesn't actually exist is "virtual" (like range, which is a view into the infinite set of integers), but a view into a real object isn't (like dict_keys, which has a reference to an actual dict), nor is something that isn't conceptually view-like at all (like a RNG iterator), even though they're all "lazy".
If either "lazy" or "virtual" means that the contained objects don't exist as python objects until they are accessed, doesn't this extend to strings and arrays (and byte strings, byte arrays, and memory views)?
There's a sense in which that's true, and in some discussions (e.g., intimately involving the GC or object sharing or optimization of array algorithms) that would be the most relevant sense, but there's also a sense in which they concretely hold all the values in memory, and in most discussions (e.g., talking about generic sequence algorithms) that would be more relevant. I don't think there's a major problem here—we don't need to eliminate all ambiguity from our speech, only the ambiguity that actually gets in the way.