Connecting Tech Pros Worldwide Help | Site Map

Code intrepretation

Newbie
 
Join Date: Sep 2008
Posts: 2
#1: Sep 6 '08
Hi,

I'm not good at ptr reference etc
Any one can help to advice below code, what its do or what its mean. Thank you.

Expand|Select|Wrap|Line Numbers
  1. display =  (DisplayBufferAddress*)(ABC::displayBufferAddress);
JosAH's Avatar
Expert
 
Join Date: Mar 2007
Posts: 10,611
#2: Sep 6 '08

re: Code intrepretation


Quote:

Originally Posted by badzkun

Hi,

I'm not good at ptr reference etc
Any one can help to advice below code, what its do or what its mean. Thank you.

Expand|Select|Wrap|Line Numbers
  1. display =  (DisplayBufferAddress*)(ABC::displayBufferAddress);

Basically that line reads as 'x= (T)y' which says: assign the value of y to x after
interpreting this value as a T'. The value (in your case) is ABC::displayBufferAddress,
it is interpreted as a pointer to a DisplayBufferAddress and assigned to your
variable 'display'.

kind regards,

Jos
Newbie
 
Join Date: Sep 2008
Posts: 2
#3: Sep 6 '08

re: Code intrepretation


Jos,

Thank you!, your advice help me a bit
Reply