Why can I assign a value of different type to a variable? : <p>In the book "Go in Action", the author wrote "Values of two different types can’t be assigned to each other, even if they’re compatible".</p>

<p>For example, we can't assign <code>Duration</code> to <code>int64</code> or <code>int64</code> to <code>Duration</code>.</p>

<p>But this is not always true, the following assignment would work like the <code>X</code> value is converted back to <code>[]int</code> automatically:</p>

<pre><code>type X []int
var v []int = X([]int{1, 2, 3})
</code></pre>

<p>What's the difference between these two situations?</p>
