Go Language Resources Go, golang, go... NOTE: This page ceased updating in October, 2012

--- Log opened Thu Dec 03 00:00:30 2009
03:53 -!- Gracenotes [n=person@wikipedia/Gracenotes] has joined #go-run
11:49 -!- Netsplit kornbluth.freenode.net <-> irc.freenode.net quits:
drhodes, rndbot
11:50 -!- Netsplit over, joins: rndbot, drhodes
11:50 -!- Netsplit kornbluth.freenode.net <-> irc.freenode.net quits: rndbot
11:53 -!- Netsplit over, joins: rndbot
14:08 -!- tonyg [n=tonyg@host238.lshift.net] has joined #go-run
14:09 < tonyg> > c := make(chan int); close(c); c <- 123;
print("here");
14:09 < rndbot> here
14:09 < tonyg> > c := make(chan int); c <- 123; print("here");
14:09 < rndbot> <no output>
14:40 < tonyg> > var err os.Error; println("hi");
14:40 < rndbot> hi
14:41 < tonyg> > var err os.Error; println(err);
14:41 < rndbot> (0x0,0x0)
14:41 < tonyg> > var err os.Error; println(err.String());
14:41 < rndbot> SIGSEGV: segmentation violation Faulting address: 0x14
PC=0x804882b mainĀ·main+0x2b /tmp/swgaxvcigen.go:4 mainĀ·main() mainsta...
14:44 < tonyg> > type s struct { v int; }; func (self *s) String() string
{ return fmt.Sprintf("x%d", self.v); } println(new(s));
14:44 < rndbot> <Error: syntax error near String, syntax error near
println, empty top-level declaration>
14:53 < tonyg> @ (func () os.Error {var x *s; return x;})() == nil
14:53 < tonyg> rndbot, help
14:53 < tonyg> > (func () os.Error {var x *s; return x;})() == nil
14:53 < rndbot> <Error: undefined: s, (((node CLOSURE))()) == nil not
used>
14:54 < tonyg> > println( (func () os.Error {var x *s; return x;})() ==
nil )
14:54 < rndbot> <Error: undefined: s>
14:54 < tonyg> > println( (func () os.Error {var x *struct{}; return
x;})() == nil )
14:54 < rndbot> <Error: *struct { } is not os.Error, String()
(string)>
15:10 < Gracenotes> os.Error does require a String method
15:11 < Gracenotes> > fmt.Printf("%#v", os.NewError("string"))
15:11 < rndbot> "string"
15:11 < Gracenotes> > fmt.Printf("%T", os.NewError("string"))
15:11 < rndbot> os.ErrorString
15:33 < tonyg> > s := "hello"; (func () { s := 123; println(s); })();
println(s);
15:33 < rndbot> 123 hello
15:33 < tonyg> > s := "hello"; (func () { s, err := "goodbye", 0;
println(s, err); })(); println(s);
15:33 < rndbot> goodbye 0 hello
15:34 < tonyg> > s := "hello"; (func () { s := "goodbye"; println(s);
})(); println(s);
15:34 < rndbot> goodbye hello
15:34 < tonyg> > s := "hello"; (func () { s = "goodbye"; println(s);
})(); println(s);
15:34 < rndbot> goodbye goodbye
15:36 < tonyg> > (interface{})(nil) != nil
15:36 < rndbot> <Error: false not used, false not used>
15:37 < tonyg> @ (interface{})(nil) == nil
15:37 < tonyg> eval (interface{})(nil) == nil
15:37 < tonyg> > println( interface{})(nil) == nil )
15:37 < rndbot> <Error: syntax error near nil>
15:37 < tonyg> > println( (interface{})(nil) == nil )
15:37 < rndbot> true
15:37 < tonyg> > println( (interface{})(int(0)) == nil )
15:37 < rndbot> false
15:38 < tonyg> > c := make(chan int); close(c); close(c); c <- 123;
println("hi");
15:38 < rndbot> hi
15:50 < Gracenotes> you can print things with @eval
16:51 < tonyg> Gracenotes, thanks!  I'd forgotten what the syntax was :)
16:51 < tonyg> @eval help
16:51 < rndbot> <Error: undefined: help>
16:51 < tonyg> heh
17:33 -!- tonyg [n=tonyg@host238.lshift.net] has quit ["Leaving"]
19:14 -!- Gracenotes [n=person@wikipedia/Gracenotes] has quit [Remote closed the
connection]
19:15 -!- rndbot [n=bot@wikipedia/Gracenotes] has quit [Remote closed the
connection]
20:58 < rbohn> @eval "\u23d5"
23:46 -!- rbohn [n=rbohn@192.206.100.4] has quit ["ChatZilla 0.9.85 [Firefox
3.0.15/2009101601]"]
--- Log closed Fri Dec 04 00:00:30 2009