Iterators for D

Walter Bright newshound at digitalmars.com
Mon Nov 6 22:33:39 PST 2006


Bill Baxter wrote:
> Sean Kelly wrote:
>>> The problem is if the iterator is an actual pointer, there is no 
>>> .value property for a pointer.
> 
> Well, they could.  It's up to Mr. Compiler Writer if a pointer has a 
> value property or not.

Consider the following struct:

	struct Foo
	{
		int value;
	}

Foo* p;

p.value;

Is p.value the entire contents of Foo (as it would be for a proposed 
.value property) or just Foo.value? "value" is a pretty common field name.



More information about the Digitalmars-d mailing list