On Fri, Sep 16, 2016 at 9:02 AM, <[email protected]> wrote:
> I have not been able to find an explanation. Does anyone care to explain or
> point to relevant documentation?
Slices are not strings. I think that a + b has an intuitively clear
value when a and b are strings. I do not think it does when a and b
are slices. You would presumably suggest that it means the same as
append(a, b...) but I think it could also mean
c := make(elementof(a), len(a))
for i, v := range a {
c[i] = v + b[i]
}
Given the lack of clear meaning for addition of slices, the language
omits it. Instead, it provides append and loops.
Ian
--
You received this message because you are subscribed to the Google Groups
"golang-nuts" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/d/optout.