<span style="color: rgb(0, 0, 153);">public abstract class Object</span><br style="color: rgb(0, 0, 153);"><span style="color: rgb(0, 0, 153);">{</span><br style="color: rgb(0, 0, 153);"><span style="color: rgb(0, 0, 153);"> protected string weakName = string.Empty;</span><br style="color: rgb(0, 0, 153);">
<br style="color: rgb(0, 0, 153);"><span style="color: rgb(0, 0, 153);"> public string WeakName</span><br style="color: rgb(0, 0, 153);"><span style="color: rgb(0, 0, 153);"> {</span><br style="color: rgb(0, 0, 153);">
<span style="color: rgb(0, 0, 153);"> get { return this.weakName; }</span><br style="color: rgb(0, 0, 153);"><span style="color: rgb(0, 0, 153);"> protected set { this.weakName = value; }</span><br style="color: rgb(0, 0, 153);">
<span style="color: rgb(0, 0, 153);"> }</span><br style="color: rgb(0, 0, 153);"><span style="color: rgb(0, 0, 153);">}</span><br><br><span style="color: rgb(0, 0, 153);">public class Derived</span><br style="color: rgb(0, 0, 153);">
<span style="color: rgb(0, 0, 153);">{</span><br style="color: rgb(0, 0, 153);"><span style="color: rgb(0, 0, 153);"> public Derived()</span><br style="color: rgb(0, 0, 153);"><span style="color: rgb(0, 0, 153);"> {</span><br style="color: rgb(0, 0, 153);">
<span style="color: rgb(0, 0, 153);"> this.WeakName = "Hello";</span><br style="color: rgb(0, 0, 153);"><span style="color: rgb(0, 0, 153);"> }</span><br style="color: rgb(0, 0, 153);"><span style="color: rgb(0, 0, 153);">}</span><br>
<br>In C#:<br><font color="#3333ff">Derived obj = new Derived();<br>Console.WriteLine(obj.WeakName)<br><font color="#000000">Hello</font><br>obj.WeakName = "Fail";<br><font color="#ff0000"><span style="color: rgb(255, 102, 102);">The property or indexer 'Object.WeakName' cannot be used in this context because the set accessor is inaccessible</span><br>
</font><br><span style="color: rgb(0, 0, 0);">In IPy:<br>>>> <span style="color: rgb(0, 153, 0);">obj = Derived()</span><br>>>> <span style="color: rgb(0, 153, 0);">obj.WeakName = 'Succeed'</span><br>
>>> <span style="color: rgb(0, 153, 0);">obj.WeakName</span><br>'Succeed'<br><br>Is this expected behavior?<br><br></span></font>___________________________<br>Matthew Barnard