title: comparing c++ char struct to an ASCII value yields an error
body: <pre><code>if (sale-&gt;taxStatus[i] = "y")  // line 44
  </code></pre>
  
  <p>yields error: </p>
  
  <p><code>y.cpp:44:12: error: request for member taxStatus in sale, which is of non-class type Sale*</code></p>
  
  <p>My struct:  </p>
  
  <pre><code>struct Sale {
      int quantity[MAX_SALES];
      float unitPrice[MAX_SALES];
      char taxStatus[MAX_SALES]; // MAX_SALES = 10
  };
  </code></pre>
  
  <p>the full function:</p>
  
  <pre><code>void total(struct Sale sale[], int sales) {
  
      int i = 0;
      float subTotal, hst, total = 0;
  
      for (i = 0; i &lt; sales; i++) {
          subTotal = subTotal + (sale-&gt;quantity[i] * sale-&gt;unitPrice[i]);
          if (sale-&gt;taxStatus[i] = "y")
          {
              hst = hst + ((sale-&gt;quantity[i] * sale-&gt;unitPrice[i]) * 0.13);
          }
      }
  
      cout &lt;&lt; "\n" &lt;&lt; "Subtotal  : " &lt;&lt; subTotal &lt;&lt; endl;   
      cout &lt;&lt; "HST (13%) : " &lt;&lt; hst;   
  }
  </code></pre>