title: Failed to produce diagnostic for expression for image array
body: <p>I am trying to utilize the UIImage array in SWiftUI class for forEach loop but Xcode always gives me the error 'Failed to produce diagnostic for expression;'. I also tried using the <em>Data</em> array but same error. Below is my code. It will be great if someone can point what I am doing wrong?</p>
  <pre><code>struct Sample: View {
  
      let imageArray: [UIImage]
  
      var body: some View {
          ForEach(imageArray) { image in
              Image(uiImage: image)
          }
      }
  }
  </code></pre>