[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

Re: Any C++ on Alpha gfurus out there?



 Paul Tomblin wrote:
> >
> > Quoting Stefan Schroepfer (scr@iis.fhg.de):
> > > Brian E.W. Wood wrote:
> > > >
> > > > _wd * wd = (_wd *)m_menuFactoryItems[k].callback_action;
> > >
> > > [...]
> > >  - Why does one write such a counter-intuitive construct
> > >    even if it is a valid one?
> >
> > What's so hard to understand?  _wd is obviously a class or a
typedef.  wd is a
> > pointer to that class.  m_menuFactoryItems is an array of structs or
class
> > instances, which has a data field (or method) of type (pointer to
_wd) called
> > callback_action.

> Thanks for the reply. I simply overlooked that there's an
> instantiation of a (_wd *) in this line and got confused
> about this presumed dammned _product_ on the left side of
> the assignment (it's not my day today).
>
> scr


Oops... that's true, the l-value is the wd variable, of course.


Sorry,
Leo





[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index] []