TIP: Click on subject to list as thread! ANSI
echo: c_plusplus
to: CHRIS DOWNS
from: NEIL HELLER
date: 1997-08-11 19:41:00
subject: PRINTING POINTER VALU

CD> To print the _value_of_the_pointer_, cast the pointer to a void*
CD>  cout << (void*)aPtr;  //generates something like 0x5423:3212
It amazes me that after I have declaired aPtr to be a pointer that I
wouldn't have to dereference it if printing it's contents.  In light of
that I would think that it would keep outputing characters until (if
you're lucky) it came across a NULL and that byte were still somewhere
legal to print.  Is this the only situation that you know of where such
a cast is necessary?
 * KWQ/2 1.2i * 
--- TMail v1.31.5
---------------
* Origin: Diablo Valley PCUG-BBS, Walnut Creek, CA 510/943-6238 (1:161/55)

SOURCE: echomail via exec-pc

Email questions or comments to sysop@ipingthereforeiam.com
All parts of this website painstakingly hand-crafted in the U.S.A.!
IPTIA BBS/MUD/Terminal/Game Server List, © 2025 IPTIA Consulting™.