From: Paul Brannan Date: 2002-04-12T03:19:36+09:00 Subject: Re: Is eval a code/design smell? On Fri, Apr 12, 2002 at 02:56:46AM +0900, Sean Middleditch wrote: > Of course, with C++, you do directly access any byte in memory owned by > the program you want, so things like public/private/friend are simply > there as "safety" checks - not any kind of true protection or security > mechanism. It's more than that. In C++, bypassing the access control is undefined. You must first find out the memory location where the data you want is. There is no portable way to do this. It's perfectly legal for a compiler to only allow this kind of access on Tuesdays between 6:30 and 10:00pm. GOTW has an interesting (and somewhat humorous) article on the subject: http://www.gotw.ca/gotw/076.htm Paul