Re: why use -> (not .) with pointers?





Richard Tobin wrote:
[snip]
>
> I think the answer is just that they are different operations so C has
> different names for them. a->b is equivalent to (*a).b.
Don't you think that was what I meant, albeit in a roundabout way?
You don't I'll assume for now :)

<i_think_remotely_O(n)T(opic)>
In any case, this fires my curiosity. What if we did have the _same_
operator? Would the compiler not have to extra work?
</i_think_remotely_O(n)T(opic)>
> A less
> explicit language than C might confound these, but C doesn't.

.



Relevant Pages