<br><br><div class="gmail_quote">On Fri, Nov 26, 2010 at 9:45 PM, Nikolay Nikolov <span dir="ltr"><<a href="mailto:nickysn@users.sourceforge.net">nickysn@users.sourceforge.net</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">
<div class="im">On 11/26/2010 10:42 AM, Max Vlasov wrote:<br>
<blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">
<br>
Is anyone aware of similar concept in any other OOP language?<br>
</blockquote></div>
Yes, C++ has it:<br>
<a href="http://duramecho.com/ComputerInformation/WhyHowCppConst.html" target="_blank">http://duramecho.com/ComputerInformation/WhyHowCppConst.html</a><br>
<br>
It's true that it's a little bit messy, but that's pretty much the norm with everything in C++ ;-)<div><div></div><div class="h5"><br></div></div></blockquote></div><br><br>Thanks, Nikolay, it's interesting information, when I tried to search before I posted, I didn't use "const", only "read only" so did not find anything. I already see that it never would be implemented the similar way since in contrary to C++ const objects in pascal already can do whatever they want. <br>
<br>Also searching now, found a post <br><br><a href="http://community.freepascal.org:10000/bboards/message?message_id=256912&forum_id=24082">http://community.freepascal.org:10000/bboards/message?message_id=256912&forum_id=24082</a><br>
<br>Where was question about const, but it seems that primary discussion was about optimization, not preventing from occasional modification. <br><br>Max Vlasov<br>