title: Why does my implementation of an XOR-reduction has multiple drivers?
body: <p>I have a binary string like "11000110".
  I'm trying to XOR all bits together.</p>
  
  <p>I have this code:</p>
  
  <pre><code>library IEEE;
  use IEEE.STD_LOGIC_1164.ALL;
  use IEEE.STD_LOGIC_ARITH.ALL;
  use IEEE.NUMERIC_STD.ALL;
  use IEEE.STD_LOGIC_UNSIGNED.ALL;
  
  entity e_circuit is
    generic(n : INTEGER:=8);
    port(
      d1:in std_logic_vector(n-1 downto 0);
      result:out std_logic
    );
  end e_circuit;
  
  architecture structure of e_circuit is
      signal temp:std_logic;
  begin
  
      temp&lt;=d1(0);
      loop1:for i in 1  to n-1 generate
          temp&lt;= d1(i) or d1(i-1);
      end generate;
      result&lt;=temp;
  end structure;
  </code></pre>
  
  <p>But, when I try to compile it, I get the error below:</p>
  
  <blockquote>
    <p>ERROR:Xst:528 - Multi-source in Unit &lt;e_circuit> on signal &lt;result>;
    this signal is connected to multiple drivers.</p>
  </blockquote>
  
  <p>What does it mean? How can I fix it?</p>