Thought about this today, and although your argument is valid for the case
where the function signature contains Node (like this)
func (e E) Less(e2 Node) bool {
return e.value < e2.value
}
the function signature presents a different type with Element
func (e E) Less(e2 Element) bool {
return e
Say I have a
type Node interface {
Less(Node) bool
}
and
type Element struct {
value int
}
func callLess(n1, n2 Node) {
n1.Less(n2)
}
I understand that type-assertions are generally required to get a different
type from an interface. But in this specific case where a type is kn
Never mind, I figured it out. As long as I export a separate $GOROOT during
compile, it works fine. To sum up, I just
1. Downloaded and unpacked the source
2. cd'd into src/. exported $GOROOT_BOOTSTRAP to /usr/local/go (in my
case).
3. run ./all.bash. as long as you don't add the bin
I currently have the distribution "go version go1.7.1 darwin/amd64"
installed. However, I'd like to test my applications on the 1.8 beta.
- Is it okay to install another distribution without messing up the
environment variables?
- If I build from source, can I scope the installation to
That fixes it, sorry for the silly question. Thank you very much.
On Tuesday, November 8, 2016 at 1:03:48 AM UTC-5, Ian Lance Taylor wrote:
>
> On Mon, Nov 7, 2016 at 8:58 PM, > wrote:
> > I've been trying out Go's assembler, but I can't seem to get the most
> basic
> > program to compile. Fol
I've been trying out Go's assembler, but I can't seem to get the most basic
program to compile. Following the example on https://goroutines.com/asm,
which introduces go's assembler through an example of an add function on
amd64, I get the compile error:
# github.com/smasher164/asmtest
../../wor