|
Boost : |
From: Steven Watanabe (steven_at_[hidden])
Date: 2007-03-06 20:03:52
AMDG
Jason Turner <lefticus <at> gmail.com> writes:
> Learn something new every day, I thought the -> operator could take parameters.
operator-> can be overloaded, but it behaves differently
from all other operators.
struct A {
void f();
};
struct B {
A* operator->() const {
return(p);
}
A* p;
};
A a;
C c = { &a };
c->f(); //calls a.f();
I can't think of any way to make it do what
you want.
In Christ,
Steven Watanabe
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk