title: Mono Bug: Error message when attempting to observe a newly assigned value after mutating an object member
body: <p>I'm observing an error message on a data-tip when attempting to observe a newly assigned value after mutating an object member.</p>
  <p><strong>Viewmodel:</strong></p>
  <p>I'm trying to mutate the header member of a viewmodel object.</p>
  <pre><code>let mutable header : NavBarItem option = None
  
  member x.Header      with get()  = header
                       and  set(v) = header       &lt;- v
                                     base.NotifyPropertyChanged(&lt;@ x.Header @&gt;)
  ...
  //----------------------------------
  // THE FOLLOWING ERRORS
  //----------------------------------
  member x.LoadAsync(panelId:PanelId) =
  
     let items = seq [NavBarItem() :&gt; UITemplate]
  
     let result = items  |&gt; Seq.map (fun v -&gt; v :?&gt; NavBarItem)
                         |&gt; Seq.tryHead // Error recovering value
  
     x.Header &lt;- result
  </code></pre>
  <p><strong>Error:</strong></p>
  <p>Here's the error after I hover my cursor over x.Header:</p>
  <blockquote>
  <p>Incorrect number or types of arguments Parameter name: arguments</p>
  </blockquote>
  <p><a href="https://i.stack.imgur.com/zZfH6.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/zZfH6.png" alt="enter image description here" /></a>
  Here's a <a href="https://xamarin.github.io/bugzilla-archives/46/4659/bug.html" rel="nofollow noreferrer">bug report</a> that I observed after researching the error message.</p>
  <p><strong>UPDATE:</strong></p>
  <p>I attempted to serialize the sequence of objects that I did have access to so that I could deserialize the json and access an individual item.</p>
  <p>That also failed:</p>
  <pre><code>   let temp = seq [NavBarItem() :&gt; UITemplate] |&gt; filterToNavBarItems 
                                                 |&gt; Seq.cast&lt;NavBarItem&gt;
  
     let json  = JsonConvert.SerializeObject(temp)
     let items = JsonConvert.DeserializeObject&lt;NavBarItem seq&gt;(json)
     let item  = items |&gt; Seq.tryHead
  
     x.Header &lt;- item // Error recovering value
  </code></pre>
  <p>Json:</p>
  <pre><code>[{&quot;MeasureId&quot;:&quot;some_navbar_id&quot;,&quot;Header&quot;:&quot;Dashboard&quot;,&quot;Subheader&quot;:&quot;Trauma Alerting&quot;,&quot;EmblemLabel&quot;:&quot;&quot;,&quot;IsEmblemAttached&quot;:false,&quot;EmblemBGColor&quot;:&quot;&quot;,&quot;EmblemFGColor&quot;:&quot;&quot;}]
  </code></pre>
  <p><strong>Appendix:</strong></p>
  <pre><code>type UITemplate =
      abstract member ToString   : unit -&gt; string
      abstract member OrderIndex : int with get, set
  
  type NavBarItem() =
  
      inherit ViewModelBase()
  
      let mutable header = &quot;&quot;
  
      interface UITemplate with 
          member x.ToString() = &quot;NavBarItem&quot;
          member val OrderIndex = -1 with get,set
  
      member x.Header  with get()  = header
                       and  set(v) = header &lt;- v
                                     base.NotifyPropertyChanged(&lt;@ x.Header @&gt;)
  
  
  type ViewModelBase () =
  
      let propertyChanged = Event&lt;PropertyChangedEventHandler,PropertyChangedEventArgs&gt;()
          
      let getPropertyName = function 
          | PropertyGet(_,pi,_) -&gt; pi.Name
          | _ -&gt; invalidOp &quot;Expecting property getter expression&quot;
          
      interface INotifyPropertyChanged with
  
          [&lt;CLIEvent&gt;]
          member this.PropertyChanged = propertyChanged.Publish
          
      member this.NotifyPropertyChanged propertyName = 
          propertyChanged.Trigger(this,PropertyChangedEventArgs(propertyName))
  
      member this.NotifyPropertyChanged quotation = 
          quotation |&gt; getPropertyName |&gt; this.NotifyPropertyChanged
  </code></pre>