4 ms·
ScriptRock's Experience with Go, After Porting 30KLOC
- fmstephe 12y agoI am not a C++ developer. My understanding was that c++ const was found severely lacking for complex structures? I know that java's final is worthless in this scenario. Can anyone elaborate on how effective c++'s const is for this use? Thx. EDIT: After reading the first three links from a sensible Google search http://duramecho.com/ComputerInformation/WhyHowCppConst.html http://duramecho.com/ComputerInformation/WhyHowCppConst.html https://msdn.microsoft.com/en-us/library/145yc477.aspx https://msdn.microsoft.com/en-us/library/145yc477.aspx http://www.cprogramming.com/tutorial/const_correctness.html http://www.cprogramming.com/tutorial/const_correctness.html I can see that C++ const is very sophisticated. I like it, and I can see that what the author described is well provided for by it - safely sharable objects. But, it is also very clear that const introduces a fairly extreme level of sophistication to the compiler. It isn't clear how this sort of feature would interact with interfaces{} etc.