Why am I able to change the contents of const char *ptr?

前端 未结 0 631
春和景丽
春和景丽 2021-02-15 04:19

I passed a pointer ptr to a function whose prototype takes it as const.

foo( const char  *str );

Which according to m

相关标签:
回答
  • 消灭零回复
提交回复
热议问题