This is the mail archive of the gcc-help@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

G++ switch to make everything public in a class?


Hi All,

I'm interested in writing test cases against c++ classes. For testing,
I'd like everything to be public so I can call protected and private
functions with bad data for negative test cases.

I don't want to use friendship since its for testing only (it would
pollute the interfaces).

Is there a switch to force everything public? If not, how does one
typically access the non-public stuff for testing?

Jeff


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]