Thread
:
Character conversion
View Single Post
04-22-2003, 04:16 PM
#
7
(
permalink
)
agh
Registered User
Join Date: Apr 2003
Posts: 30
You could do this:
Code:
void f() { char c = 'a'; const char* ccp = &c; char* cp = const_cast<char*>(ccp); *cp = 'b'; }
But, as joe_bruin said, you shouldn't do that, because things are marked const for a reason.
agh
View Public Profile
Find More Posts by agh