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

--- Log opened Sun Jul 11 00:00:12 2010
00:13 -!- incluye [~inklewyay@NW-ESR1-74-215-114-218.fuse.net] has quit [Remote
host closed the connection]
00:14 -!- incluye [~inklewyay@NW-ESR1-74-215-114-218.fuse.net] has joined #go-nuts
00:20 -!- qIIp [~qIIp@72-173-156-132.cust.wildblue.net] has joined #go-nuts
00:21 -!- qIIp [~qIIp@72-173-156-132.cust.wildblue.net] has quit [Read error:
Connection reset by peer]
00:32 -!- nictuku [~nictuku@cetico.org] has quit [Quit: Permission revoked -
dircproxy 1.0.5]
00:34 -!- nictuku [~nictuku@unaffiliated/nictuku] has joined #go-nuts
00:58 -!- GeoBSD [~geobsd@lns-bzn-56-82-255-226-184.adsl.proxad.net] has quit
[Quit: Lost terminal]
01:24 -!- Bombe [~droden@weltgehirnmaschine.de] has quit [Changing host]
01:24 -!- Bombe [~droden@freenet/developer/Bombe] has joined #go-nuts
01:29 -!- eikenberry [~jae@ivanova.zhar.net] has joined #go-nuts
01:48 -!- binarypie [~binarypie@c-24-6-151-185.hsd1.ca.comcast.net] has joined
#go-nuts
01:52 -!- lmoura [~lmoura@187.78.130.104] has joined #go-nuts
01:56 -!- jchico [~jchico@cpe-98-14-12-209.nyc.res.rr.com] has joined #go-nuts
02:00 -!- nsf [~nsf@jiss.convex.ru] has quit [Quit: WeeChat 0.3.2]
02:13 -!- rhelmer [~rhelmer@204.239.250.1] has joined #go-nuts
02:15 -!- rhelmer [~rhelmer@204.239.250.1] has quit [Client Quit]
02:15 -!- rhelmer [~rhelmer@204.239.250.1] has joined #go-nuts
02:18 -!- rhelmer [~rhelmer@204.239.250.1] has quit [Client Quit]
02:40 -!- kanru [~kanru@61-228-161-134.dynamic.hinet.net] has joined #go-nuts
02:47 < jchico> oh sweet never knew about http://ideone.com/
02:48 < Ginto8> does it have any cloud functionality?
02:48 -!- kanru [~kanru@61-228-161-134.dynamic.hinet.net] has quit [Quit: WeeChat
0.3.2]
02:49 < jchico> doesn't mention any of that in their FAQ
02:49 < Ginto8> hm well if it did I would totally use it
02:49 < jchico> just that the code cannot exceed 10 secs of run time, and
takes up to 256MB of memory
02:49 < Ginto8> right now I'm using dropbox for cloud-like dev functionality
02:49 < Ginto8> hm ok
02:59 -!- rejb [~rejb@unaffiliated/rejb] has quit [Ping timeout: 276 seconds]
03:01 -!- jhawk28 [~jhawk28@72.40.31.201] has quit [Read error: Connection reset
by peer]
03:12 -!- kanru [~kanru@61-228-161-134.dynamic.hinet.net] has joined #go-nuts
03:16 -!- slashus2 [~slashus2@74-137-24-74.dhcp.insightbb.com] has quit [Quit:
slashus2]
03:19 -!- binarypie [~binarypie@c-24-6-151-185.hsd1.ca.comcast.net] has quit [Ping
timeout: 265 seconds]
03:41 -!- Project_2501 [~Marvin@82.84.75.14] has joined #go-nuts
03:41 * Project_2501 is back \o/
03:53 < jchico> ok so I read all of the spec, tutorial, effective go docs
(although I didn't fully understand some things) now I'm not sure what to write to
test my knowledge...
03:54 -!- kanru [~kanru@61-228-161-134.dynamic.hinet.net] has quit [Quit: WeeChat
0.3.2]
03:54 < jchico> that's the problem I ran into when learning new languages, I
learn the syntax and write small snippets of code but never a full program :/
03:55 < Ginto8> a multiplexer
03:57 < jchico> like your hardware multiplexer with multiple inputs a
selector and one output?
03:57 -!- incluye [~inklewyay@NW-ESR1-74-215-114-218.fuse.net] has quit [Remote
host closed the connection]
03:57 -!- incluye [~inklewyay@NW-ESR1-74-215-114-218.fuse.net] has joined #go-nuts
04:20 -!- nsf [~nsf@jiss.convex.ru] has joined #go-nuts
04:23 -!- jchico [~jchico@cpe-98-14-12-209.nyc.res.rr.com] has quit [Quit:
Leaving]
04:38 -!- MizardX [~MizardX@unaffiliated/mizardx] has quit [Ping timeout: 276
seconds]
04:45 -!- jdp [~gu@24.238.32.162.res-cmts.segr.ptd.net] has quit []
04:51 -!- sladegen [~nemo@unaffiliated/sladegen] has quit [Ping timeout: 248
seconds]
04:51 -!- sladegen [~nemo@unaffiliated/sladegen] has joined #go-nuts
04:54 -!- rv2733 [~ron@c-98-242-168-49.hsd1.fl.comcast.net] has joined #go-nuts
04:59 -!- scm [justme@d071086.adsl.hansenet.de] has quit [Ping timeout: 260
seconds]
05:00 -!- scm [justme@d039124.adsl.hansenet.de] has joined #go-nuts
05:09 -!- Wiz126 [~Wiz126@24.229.245.72.res-cmts.sm.ptd.net] has quit [Ping
timeout: 276 seconds]
05:09 -!- Wiz126 [~Wiz126@24.229.245.72.res-cmts.sm.ptd.net] has joined #go-nuts
05:24 -!- scarabx [~scarabx@c-76-19-43-200.hsd1.ma.comcast.net] has joined
#go-nuts
05:33 -!- scarabx [~scarabx@c-76-19-43-200.hsd1.ma.comcast.net] has quit [Quit:
This computer has gone to sleep]
05:33 -!- skelterjohn [~jasmuth@c-76-116-181-134.hsd1.nj.comcast.net] has quit
[Quit: skelterjohn]
05:38 -!- rv2733 [~ron@c-98-242-168-49.hsd1.fl.comcast.net] has quit [Quit:
Leaving]
05:53 < Eko> nf: you around?
05:54 < nf> Eko: yes
05:55 < nf> trying to figure out how to introduce backtracking to this
sudoku solver ;)
05:55 < Eko> nf: do you still want updates to links for packages and so on
via email?
05:55 < Eko> lol!
05:55 < Eko> I purposely left mine alone once I got the basic one done
because I remember the hours and hours I spent on the last one I did
05:55 < nf> Eko: sure!
05:56 < nf> i just posted this a little while ago
http://nf.id.au/expressive-concurrency-a-go-sudoku-solver-par
05:56 < nf> i'm hoping that by the time i get to part 3 i'll have the
backtracking thing worked out
05:58 < Eko> lol.  I just did standard row/col/square elimination
06:10 -!- Macpunk [~macpunk@cpe-72-177-26-221.austin.res.rr.com] has joined
#go-nuts
06:11 < Boney_> nf: can you use continuations in go, perhaps you can
implement choice points using them.
06:11 < Eko> Boney_: continuations?
06:11 < Boney_> nf: the tricky part will be undoing updates you make to
memory.
06:11 < Boney_> http://en.wikipedia.org/wiki/Continuation
06:12 < Boney_> ^ other people can explain it better than I can.  I'm not
sure I fully understand it.
06:12 < Eko> nf: not sure if you've looked at my godoku attempt at a sudoku
solver, but I used two goroutines (though they could probably be combined to one),
and you could probably add a third goroutine (or make it again part of the first)
that handled storing states.
06:14 < Eko> so you go through the basic logic, and once that has exhausted
the eliminations it can make, you generate a key and send a message to each square
to save its state using that key, and then shove the key on a stack, make the
guess, and see where that leaves you.
06:15 < Eko> if it leaves you in an inconsistent state, you pop the last key
off the stack, and then try the next possibility associated with it.
06:15 < Boney_> Eko: yep, that's the basic design of a constraint solver.
06:15 < Eko> Boney_: with snazzy go concepts ;)
06:17 < Eko> I've seen less than fifty lines of code, and I already know
that ni's solver is going to be more idiomatic and cleaner than mine, lol
06:19 < Boney_> some of the concepts that would really help here are
trailing and backtracking.  I'm pretty sure that Go has neither.  (Most
programming languages don't).
06:19 < Boney_> You can get buy without trailing by copying your mrmory
rather than using distructive update.
06:22 < nf> yeah, i'm thinking about an elegant way to copy the entire state
of the solver before attempting a solution
06:22 < nf> maybe each goroutine could store its state in a data structure,
and there could be a 'freeze' channel which tells all the squares to save or
restore their state
06:23 < nf> and so they could just push their state onto a list
06:23 < nf> and pop it off to restore
06:23 < nf> it's a really interesting problem!  i'm fascinated
06:23 < nf> hmm..  actually, this is interesting
06:24 < nf> you could just start a new square goroutine, passing in current
state
06:24 < nf> (ie from the original goroutine)
06:24 < nf> that way the stack would preserve the state
06:24 < nf> and the new goroutine would take over peforming channel reads
06:24 < nf> i am not explaining myself at all clearly right now
06:25 < nf> it'll be a week or so before i'm able to articulate this
properly ;)
06:27 < Boney_> nf: you don't need to copy the _whole_ state, only the state
that's different and things that reference the different things (transativly
different things).
06:27 < nf> i should have a chat with ken, he'll have some good ideas ;)
06:28 < Boney_> If you're intrested take a look at this project
http://www.g12.csse.unimelb.edu.au
06:28 < Boney_> sadly most of their work is closed source but they work on
generic constraint programming software.
06:28 -!- incluye [~inklewyay@NW-ESR1-74-215-114-218.fuse.net] has quit [Ping
timeout: 265 seconds]
06:28 < nf> looks cool!
06:29 < nf> okay it's starting to get cold, better leave this cafe (some 3
hours later)
06:29 < nf> bbl
06:29 < Boney_> I have a problem where my wife has to visit roughly 50
schools in the next 4 months and perform literacy and numeracy tests on the
children there.
06:29 < Boney_> different schools have different numbers of children and
need a different amount of time.
06:30 -!- slashus2 [~slashus2@74-137-24-74.dhcp.insightbb.com] has joined #go-nuts
06:30 < Boney_> She can claim driving miles between schools, but not between
home and school.  and there are a few other constraints.
06:30 < Boney_> my job is to find the most optimal plan that minimises her
driving.
06:32 < Eko> nf: that IS interesting!  Using the stack as...  a stack!
brilliant, rofl.
06:32 < Eko> and also brilliantly concise, yet expressive.
06:33 < Boney_> Eko: the stack is my favorite data-structure.
06:38 < Eko> Boney_: it's simple but ridiculously effective.
06:39 -!- ExtraSpice [~ExtraSpic@88.118.32.225] has joined #go-nuts
06:51 -!- jA_cOp [~yakobu@unaffiliated/ja-cop/x-9478493] has joined #go-nuts
06:55 < nf> Boney_: she's having you solve the travelling salesman problem?!
:)
06:57 < nf> i think one of the reasons i like programming in Go is the same
reason i like Bach
07:09 -!- cco3 [~conley@c-69-181-138-209.hsd1.ca.comcast.net] has quit [Ping
timeout: 265 seconds]
07:14 < Boney_> nf: traveling salesman + timetableing + returning to base
every night + some extra constraints.
07:14 < Boney_> It'll be fun.
07:15 < Boney_> And it's my first excuse to actually use a Google API.
07:15 < Boney_> (maps/directions).
07:21 -!- mbarkhau [~koloss@dslb-094-219-043-014.pools.arcor-ip.net] has joined
#go-nuts
07:23 -!- sauerbraten [~sauerbrat@p508CB096.dip.t-dialin.net] has joined #go-nuts
07:24 < sauerbraten> can someone help me how i set up my .bashrc so i can
use 8g and 8l as commands without being in $GOBIN?
07:29 < sauerbraten> nevermind...
07:30 < Ginto8> just do eport PATH=$PATH;$GOBIN
07:30 < Ginto8> or is it $GOBIN;$PATH?
07:30 < Ginto8> or $GOBIN:$PATH
07:30 < Ginto8> I never get that right
07:35 -!- photron [~photron@port-92-201-142-142.dynamic.qsc.de] has joined
#go-nuts
07:35 -!- ShadowIce [pyoro@unaffiliated/shadowice-x841044] has joined #go-nuts
07:42 < str1ngs> $GOBIN:$PATH
07:42 < sauerbraten> it is done like that: add PATH=$PATH:$GOBIN to .bashrc
07:43 < str1ngs> yes
07:43 < sauerbraten> ;)
07:43 -!- rhelmer [~rhelmer@adsl-69-107-64-223.dsl.pltn13.pacbell.net] has joined
#go-nuts
07:43 < str1ngs> make sure GOBIN is set though
07:43 < sauerbraten> it is, works now
07:43 < str1ngs> good stuff
07:43 -!- Elems [~Jake@c-98-215-113-215.hsd1.il.comcast.net] has quit [Quit:
Leaving.]
07:43 < str1ngs> also you might want to put that in .bash_profile over
.bashrc.  if you tend to sourc .bashrc alot
07:46 < sauerbraten> i have a connection between server.go and client.go,
and server.go prints out everything that's typed in at client.  Now when i quit
client.go by pressing CTRL + C, server prints out empty messages from client in an
endless loop that i used to make it receive everything coming fom client
07:46 -!- rlab [~Miranda@150-175-113-92.pool.ukrtel.net] has joined #go-nuts
07:48 < sauerbraten> someone understands my problem?  here is server.go:
http://paste.pocoo.org/show/236058/ and client.go:
http://paste.pocoo.org/show/236057/
07:53 < str1ngs> sauerbraten: I'm kinda new to go.  but my guess is break
not being caught.
07:54 < str1ngs> does Client disconnected print?
07:55 < sauerbraten> str1ngs: no that's why i am confused...
07:55 < str1ngs> ok what I thought.  oh and I'm stealing your readLineSlice
cause that solves my problem :P
07:56 < str1ngs> msg[0:]) == "" so there is something wrong with this test.
07:56 < sauerbraten> str1ngs: actually it is not mine :D jhawk28 pasted it
for me
07:57 < str1ngs> ah I was liking for some readline function
07:57 < sauerbraten> i just edited it to read into []byte
07:58 < str1ngs> [0:] that I cant read what does that say.
07:58 < sauerbraten> maybe i should implement something in client, that if
you type in "quit" it cleanly closes the connetion so you don't have to break it
with CTRL+C
07:59 < str1ngs> sauerbraten: I was going to say that to ..  . close or
something . but still you should handle a disconnect
07:59 -!- slashus2 [~slashus2@74-137-24-74.dhcp.insightbb.com] has quit [Quit:
slashus2]
08:00 < sauerbraten> it reads into a slice, with an open end so it stops
when there is no more to read
08:00 < str1ngs> ah so start at 0 to : end
08:00 < sauerbraten> while it is limited at 1024 bytes of course because of
msg
08:00 < sauerbraten> yep
08:00 < str1ngs> I have also seen defer used for Closing
08:02 < str1ngs> let me check the spec for net.
08:03 < sauerbraten> i found defer in the "effective go"-doc...  but my
english is too bad to understand it's meaning
08:05 < sauerbraten> ah i think i got it...  but it doesn't seem to help in
my case
08:06 < str1ngs> Conn is an interface I'm assuming?
08:06 < jessta> net.Conn is an interface
08:07 < sauerbraten> yes
08:07 < jessta> sauerbraten: defer() says, to run that code when the
function ends
08:08 < str1ngs> jessta: ah that is good to know I was wonder what defer did
I thought thats what it meant
08:08 < str1ngs> good for when you open a file you can defer right after so
it always closes
08:08 < sauerbraten> yes only the thing with the arguments still confuses me
a little bit...
08:09 < jessta> sauerbraten: arguments?
08:09 < str1ngs> sauerbraten: I got it I think
08:09 < str1ngs> func (c *IPConn) Read(b []byte) (n int, err os.Error)
08:10 < jessta> str1ngs: you really shouldn't ignore errors
08:10 < str1ngs> so..  line 16 you want to do _, err . then test for
08:10 < str1ngs> jessta: I know I'm explaining that
08:10 < sauerbraten> jessta: http://golang.org/doc/effective_go.html, search
for "defer" and scroll down till the example with trace() and a()
08:11 < str1ngs> sauerbraten: _, err := connection.Read(msg[0:]) then test
err with if err != nil
08:12 < jessta> str1ngs: un(), trace() and a() are just functions
08:12 < jessta> oops, sauerbraten
08:12 -!- tvw [~tv@e176004193.adsl.alicedsl.de] has joined #go-nuts
08:12 < sauerbraten> ok and if err != nil the connection is broken and i
should break up?
08:12 < str1ngs> sauerbraten: yes can you can print out err.String().
08:13 < str1ngs> sauerbraten: which my guess will say.  connection lost blah
blah
08:13 < jessta> sauerbraten: defer takes a function, that function can take
arguments
08:14 < str1ngs> jessta: sorry I guess you ment dont just use defer without
error checking?
08:14 < str1ngs> dont* I mean
08:14 < jessta> str1ngs: nah, sorry, I thought that was your code
08:14 < jessta> sauerbraten: don't ignore errors
08:15 < str1ngs> jessta: ah gotcha . yes that why I suggested useing err
08:15 < str1ngs> jessta: I've only been learning go for a few days though.
08:15 < sauerbraten> jessta: ok i'll try not to do that anymore :D
08:15 < sauerbraten> ok guys it works fine now, the error is an endoffile
error
08:15 < jessta> sauerbraten: if you ignore errors then raptors will eat you
08:16 < sauerbraten> jessta: eww....  o.O :D
08:16 < jessta> it's better than an angry horde of developers chasing you
with flaming torches
08:17 < str1ngs> sauerbraten: did it work?
08:17 < sauerbraten> in server.go, line 9 Listen also returns an error which
i ignore..  bad?
08:17 < str1ngs> yep bad
08:17 < sauerbraten> str1ngs: yes thans
08:18 < str1ngs> sauerbraten: I'll give an example why its bad.  if you had
another instance of the server on port 50000 it would fail
08:19 < sauerbraten> yeah so i build such an if err != nil { } package for
every error that could occur?
08:20 < str1ngs> pretty much
08:22 < str1ngs> sauerbraten: I'm new though so there might be a better way
with say.  try catch if there is such a thing
08:22 < sauerbraten> i aske that yesterday, there is not :(
08:22 < sauerbraten> *asked
08:23 < sauerbraten> there is panic and recover but Ginto8 said mostly the
returned errors are used
08:27 < str1ngs> thats the trend I see in the go src tree
08:29 < sauerbraten> why do the go linkers create so silly filenames???  i
want to use them like: "8g file.go" "8l file.8" then execute without renaming
"./file.out" not "8.out" -.-
08:31 < str1ngs> sauerbraten: see /usr/lib/go/src/Make.cmd
08:31 < str1ngs> sauerbraten: or $GOROOT/src/Make.cmd
08:31 < jessta> sauerbraten: 8l -o file.out file.8
08:31 < str1ngs> my impression is with go you really dont need to use your
own Make files
08:33 < sauerbraten> str1ngs: what should i use makefiles for?
08:33 < sauerbraten> jessta: thanks, but why isn't that the default :/
08:35 < str1ngs> sauerbraten: see http://paste.pocoo.org/show/236063/
08:35 < str1ngs> sauerbraten: I'm trying to find were I got that from though
I coudl have sworn it was in the GOROOT somewhere
08:36 -!- Xurix [~Luixsia@AToulouse-254-1-1-8.w83-203.abo.wanadoo.fr] has joined
#go-nuts
08:37 < sauerbraten> str1ngs: i never used makefiles myself before...  so
what are they for?
08:37 < jessta> sauerbraten: historical reasons, a.out is histrically the
default name of what the c linker outputs
08:37 < sauerbraten> jessta: then it's time for a revolution :D
08:37 -!- vhold [~vhold@adsl-67-114-158-146.dsl.sntc01.pacbell.net] has quit
[Quit: shame quit]
08:38 < jessta> sauerbraten: it's also an unusal enough file name that it's
unlikely to override something you don't want it to
08:39 < str1ngs> the 8 can be important to . encase you are building
multiple archs at the same time.
08:39 < sauerbraten> mhm ok that's true
08:40 < jessta> sauerbraten: also, what would you change it to?
08:40 < sauerbraten> 8l file.8 should make a file file.out
08:40 < str1ngs> sauerbraten: and .out can be overwritting with -o like
jessta suggested
08:40 < str1ngs> sauerbraten: no 8.out is correct
08:40 -!- rutkowski [~adrian@078088207115.walbrzych.vectranet.pl] has joined
#go-nuts
08:41 < sauerbraten> str1ngs: yeah but in my opinion it SHOULD :D
08:41 < jessta> sauerbraten: should 6l do the same thing?
08:41 -!- terrex [~terrex@84.122.67.111.dyn.user.ono.com] has joined #go-nuts
08:41 < str1ngs> jessta: hehe now you have him cornered
08:41 < sauerbraten> jessta: ok what about file.8.out?  :P
08:42 -!- sioraiocht [~tomh@unaffiliated/sioraiocht] has joined #go-nuts
08:42 < sauerbraten> because if you buils two files in the same directory,
you have to rename the first so you don't overwrite it with the next one :d
08:42 < sauerbraten> ..
08:43 < str1ngs> if you have to rename 8.out you still have to rename
file.8.out so its redundant
08:43 < jessta> sauerbraten: you should have a make file by that stage
08:44 < sauerbraten> maybe...  but i have no idea how to...
08:45 < rutkowski> Hi, I'm starting learning go (and in general programming)
and have problem with echo example in tutorial.  I don't understand why it
works...  :S For example when I give echo 3 arguments, I don't understand why
third iteration displays argument and not a space...
08:45 < rutkowski> third an up
08:45 < jessta> sauerbraten: read some of the makefiles in the core packages
08:46 < str1ngs> sauerbraten: see $GOROOT/doc/code.html
08:46 < rutkowski> after second iteration i > 0 is always true so it
should put spaces until condition in loop
08:46 < sauerbraten> str1ngs: no i don't...  "8g server.go -> server.8"
"8l server.8 -> server.8.out" "8g client.go -> client.8" "8l client8 ->
client.8.out" => no need to rename
08:47 < str1ngs> sauerbraten: see that doc for Makefile
08:47 -!- General13372 [~support@71-84-50-230.dhcp.mtpk.ca.charter.com] has joined
#go-nuts
08:47 < sauerbraten> ok
08:47 < str1ngs> sauerbraten: will make your life easier
08:48 < jessta> rutkowski: huh?
08:48 < nf> rutkowski: it puts a space, and then the argument
08:48 < nf> rutkowski: there's no 'else', both string concatenations are
performed (s += Space and s += flag.Arg(i))
08:49 < rutkowski> um lol you right...
08:50 -!- General1337 [~support@71-84-50-230.dhcp.mtpk.ca.charter.com] has quit
[Ping timeout: 240 seconds]
08:50 < str1ngs> sauerbraten: also checkout gofmt.  my impression the go
build tools will do most of the work.  the Make.pkg and Make.cmd alone are pretty
nice.
09:00 -!- mbarkhau [~koloss@dslb-094-219-043-014.pools.arcor-ip.net] has quit
[Quit: Leaving.]
09:04 -!- skelterjohn [~jasmuth@c-76-116-181-134.hsd1.nj.comcast.net] has joined
#go-nuts
09:05 -!- skelterjohn [~jasmuth@c-76-116-181-134.hsd1.nj.comcast.net] has quit
[Client Quit]
09:08 -!- gr0gmint [~joebiden@87.60.23.38] has joined #go-nuts
09:16 -!- visof [~visof@unaffiliated/visof] has joined #go-nuts
09:41 -!- [Pete_27] [~noname@115-64-1-61.static.tpgi.com.au] has quit [Ping
timeout: 276 seconds]
09:42 -!- [Pete_27] [~noname@115-64-1-61.static.tpgi.com.au] has joined #go-nuts
09:46 -!- gr0gmint [~joebiden@87.60.23.38] has quit [Quit: leaving]
09:49 -!- visof [~visof@unaffiliated/visof] has quit [Ping timeout: 248 seconds]
09:50 -!- visof [~visof@unaffiliated/visof] has joined #go-nuts
09:53 -!- belkiss [~belkiss@drn13-1-78-235-168-105.fbx.proxad.net] has joined
#go-nuts
09:53 -!- Ginto8 [~ginto8@pool-72-82-235-34.cmdnnj.fios.verizon.net] has quit
[Ping timeout: 245 seconds]
10:16 -!- tux21b [~christoph@90.146.60.30] has quit [Quit: exit(EXIT_SUCCESS); //
see ⓎⓄⓊ]
10:28 -!- nsf [~nsf@jiss.convex.ru] has quit [Quit: WeeChat 0.3.2]
10:30 -!- ikaros [~ikaros@drms-4d014ad6.pool.mediaWays.net] has joined #go-nuts
10:31 -!- gr0gmint [~joebiden@87.60.23.38] has joined #go-nuts
10:31 -!- ExtraSpice [~ExtraSpic@88.118.32.225] has quit [Quit: Leaving]
10:35 -!- rutkowski [~adrian@078088207115.walbrzych.vectranet.pl] has quit [Ping
timeout: 240 seconds]
10:48 -!- Mindflyer91
[~Mindflyer@host212-154-dynamic.6-87-r.retail.telecomitalia.it] has joined
#go-nuts
10:51 -!- GeoBSD [~geobsd@lns-bzn-56-82-255-226-184.adsl.proxad.net] has joined
#go-nuts
10:54 -!- Macpunk [~macpunk@cpe-72-177-26-221.austin.res.rr.com] has quit [Quit:
Leaving]
11:00 -!- Xurix [~Luixsia@AToulouse-254-1-1-8.w83-203.abo.wanadoo.fr] has quit
[Quit: Leaving]
11:06 -!- sioraiocht [~tomh@unaffiliated/sioraiocht] has quit [Remote host closed
the connection]
11:19 -!- pl3 [~noam@77.126.167.205] has quit [Read error: Connection reset by
peer]
11:19 -!- pl3 [~noam@77.126.167.205] has joined #go-nuts
11:20 -!- surma [~surma@95-88-90-24-dynip.superkabel.de] has joined #go-nuts
11:20 -!- surma [~surma@95-88-90-24-dynip.superkabel.de] has left #go-nuts []
11:20 -!- pl3 [~noam@77.126.167.205] has quit [Read error: Connection reset by
peer]
11:20 -!- pl3 [~noam@77.126.167.205] has joined #go-nuts
11:21 -!- ikaros [~ikaros@drms-4d014ad6.pool.mediaWays.net] has quit [Quit: Leave
the magic to Houdini]
11:23 -!- sauerbraten [~sauerbrat@p508CB096.dip.t-dialin.net] has quit [Remote
host closed the connection]
11:32 -!- rejb [~rejb@unaffiliated/rejb] has joined #go-nuts
11:46 -!- pl3 [~noam@77.126.167.205] has quit [Read error: Connection reset by
peer]
11:46 -!- pl3 [~noam@77.126.167.205] has joined #go-nuts
12:17 -!- rhelmer [~rhelmer@adsl-69-107-64-223.dsl.pltn13.pacbell.net] has quit
[Ping timeout: 240 seconds]
12:19 -!- nsf [~nsf@jiss.convex.ru] has joined #go-nuts
12:20 -!- kanru [~kanru@61-228-161-134.dynamic.hinet.net] has joined #go-nuts
12:35 -!- rutkowski [~adrian@078088207115.walbrzych.vectranet.pl] has joined
#go-nuts
12:50 -!- Adys [~Adys@unaffiliated/adys] has joined #go-nuts
12:54 -!- pl3 [~noam@77.126.167.205] has quit [Read error: Connection reset by
peer]
13:04 -!- ExtraSpice [~ExtraSpic@88.118.32.225] has joined #go-nuts
13:21 -!- incluye [~inklewyay@NW-ESR1-74-215-114-218.fuse.net] has joined #go-nuts
13:25 < nictuku> is it possible to read from a channel like a queue, and do
not block reads if there is nothing on it?
13:27 < nictuku> or I'll need a third goroutine between these two existing
ones that are passing message to each other?
13:29 < Namegduf> nictuku: Yes.
13:30 < Namegduf> v, ok := <-chan
13:30 < Namegduf> I believe.
13:30 < nictuku> oh
13:30 < Namegduf> Will do a non-blocking read, returning !ok if there
13:30 < Namegduf> *there's nothing to read.
13:31 < nictuku> That's very interesting.  Why don't I see it in the docs?
:-)
13:31 < Namegduf> You don't?
13:32 < Namegduf> Oh, correction.
13:32 < nictuku> ah I see now
13:32 < Namegduf> ok := v <- chan
13:33 < Namegduf> Wait, no, that
13:33 < nictuku> b, ok := <-freeList
13:33 < Namegduf> *that's send, I was right the first time.
13:33 < Namegduf> Yeah, that'd work.
13:33 < Namegduf> It's at the end of "Communication operators" in the
language spec.
13:34 < nictuku> Ah, thank you for the pointer!
13:35 -!- snearch [~snearch@f053009033.adsl.alicedsl.de] has joined #go-nuts
13:36 -!- GeoBSD [~geobsd@lns-bzn-56-82-255-226-184.adsl.proxad.net] has quit
[Ping timeout: 240 seconds]
13:37 -!- GeoBSD [~geobsd@lns-bzn-33-82-252-55-34.adsl.proxad.net] has joined
#go-nuts
13:49 -!- artefon [~thiago@189.107.206.253] has joined #go-nuts
13:50 -!- snearch [~snearch@f053009033.adsl.alicedsl.de] has quit [Quit:
Verlassend]
13:51 -!- rv2733 [~ron@c-98-242-168-49.hsd1.fl.comcast.net] has joined #go-nuts
13:51 -!- slashus2 [~slashus2@74-137-24-74.dhcp.insightbb.com] has joined #go-nuts
13:53 -!- aho [~nya@f051020054.adsl.alicedsl.de] has quit [Read error: Connection
reset by peer]
14:00 -!- MizardX [~MizardX@unaffiliated/mizardx] has joined #go-nuts
14:03 -!- Adys [~Adys@unaffiliated/adys] has quit [Remote host closed the
connection]
14:23 -!- Fish [~Fish@9fans.fr] has joined #go-nuts
14:29 -!- temoto [~temoto@95-25-191-59.broadband.corbina.ru] has joined #go-nuts
14:38 -!- terrex [~terrex@84.122.67.111.dyn.user.ono.com] has quit [Remote host
closed the connection]
14:40 -!- Soultaker [~maks@hell.student.utwente.nl] has joined #go-nuts
14:42 -!- awidegreen [~quassel@62.176.237.78] has joined #go-nuts
14:54 -!- Mindflyer91
[~Mindflyer@host212-154-dynamic.6-87-r.retail.telecomitalia.it] has left #go-nuts
["Sto andando via"]
15:00 -!- visof [~visof@unaffiliated/visof] has quit [Quit: Leaving]
15:01 -!- sioraiocht [~tomh@unaffiliated/sioraiocht] has joined #go-nuts
15:03 -!- scarabx [~scarabx@c-76-19-43-200.hsd1.ma.comcast.net] has joined
#go-nuts
15:15 -!- skelterjohn [~jasmuth@c-76-116-181-134.hsd1.nj.comcast.net] has joined
#go-nuts
15:18 -!- terrex [~terrex@84.122.67.111.dyn.user.ono.com] has joined #go-nuts
15:26 -!- Shyde [~Shyde^^@HSI-KBW-078-043-070-132.hsi4.kabel-badenwuerttemberg.de]
has joined #go-nuts
15:36 -!- slashus2 [~slashus2@74-137-24-74.dhcp.insightbb.com] has quit [Quit:
slashus2]
15:40 -!- gr0gmint [~joebiden@87.60.23.38] has quit [Ping timeout: 265 seconds]
15:40 -!- gr0gmint [~joebiden@87.60.23.38] has joined #go-nuts
15:43 -!- deso [~deso@x0561a.wh30.tu-dresden.de] has joined #go-nuts
15:46 -!- incluye [~inklewyay@NW-ESR1-74-215-114-218.fuse.net] has quit [Ping
timeout: 265 seconds]
16:04 -!- tvw [~tv@e176004193.adsl.alicedsl.de] has quit [Ping timeout: 240
seconds]
16:10 -!- incluye [~inklewyay@NW-ESR1-74-215-114-218.fuse.net] has joined #go-nuts
16:44 -!- scarabx [~scarabx@c-76-19-43-200.hsd1.ma.comcast.net] has quit [Quit:
This computer has gone to sleep]
16:58 -!- gr0gmint [~joebiden@87.60.23.38] has quit [Read error: Connection reset
by peer]
16:58 -!- gr0gmint [~joebiden@87.60.23.38] has joined #go-nuts
16:59 -!- gr0gmint [~joebiden@87.60.23.38] has quit [Client Quit]
17:02 -!- sauerbraten [~sauerbrat@p508CB096.dip.t-dialin.net] has joined #go-nuts
17:05 -!- Tiger__ [~chatzilla@118.126.12.54] has joined #go-nuts
17:08 -!- Tiger_ [~chatzilla@118.126.12.54] has quit [Ping timeout: 264 seconds]
17:24 -!- sioraiocht [~tomh@unaffiliated/sioraiocht] has quit [Remote host closed
the connection]
17:28 -!- slashus2 [~slashus2@74-137-24-74.dhcp.insightbb.com] has joined #go-nuts
17:40 -!- belkiss [~belkiss@drn13-1-78-235-168-105.fbx.proxad.net] has quit [Quit:
KVIrc Equilibrium 4.1.0, revision: 4632, sources date: 20100519, built on:
2010-07-09 07:13:47 UTC http://www.kvirc.net/]
17:42 -!- slashus2 [~slashus2@74-137-24-74.dhcp.insightbb.com] has quit [Quit:
slashus2]
17:43 -!- awidegreen [~quassel@62.176.237.78] has quit [Remote host closed the
connection]
17:44 -!- Ginto8 [~ginto8@pool-72-82-235-34.cmdnnj.fios.verizon.net] has joined
#go-nuts
17:49 -!- Project-2501 [~Marvin@dynamic-adsl-94-36-178-35.clienti.tiscali.it] has
joined #go-nuts
17:50 -!- sauerbraten [~sauerbrat@p508CB096.dip.t-dialin.net] has quit [Ping
timeout: 265 seconds]
17:52 -!- Project_2501 [~Marvin@82.84.75.14] has quit [Ping timeout: 248 seconds]
17:55 -!- Project_2501 [~Marvin@82.84.94.103] has joined #go-nuts
17:58 -!- Project-2501 [~Marvin@dynamic-adsl-94-36-178-35.clienti.tiscali.it] has
quit [Ping timeout: 248 seconds]
18:03 -!- GeoBSD [~geobsd@lns-bzn-33-82-252-55-34.adsl.proxad.net] has quit [Ping
timeout: 260 seconds]
18:05 -!- vomjom [~vomjom@99-162-150-88.lightspeed.sntcca.sbcglobal.net] has quit
[Ping timeout: 260 seconds]
18:12 -!- rauq [~rauq@p2183-ipbf703sapodori.hokkaido.ocn.ne.jp] has joined
#go-nuts
18:16 -!- skelterjohn [~jasmuth@c-76-116-181-134.hsd1.nj.comcast.net] has quit
[Quit: skelterjohn]
18:16 -!- lmoura [~lmoura@187.78.130.104] has quit [Ping timeout: 246 seconds]
18:18 -!- {aaron} [~xyz@pool-173-50-62-95.syrcny.east.verizon.net] has joined
#go-nuts
18:19 < {aaron}> faq says "there is no safe way to call Go code from C or
C++"..."yet" is this still the case?
18:19 < Ginto8> yes, and it will probably remain that way
18:19 * {aaron} weeps
18:19 < Ginto8> go's typing system is too strict to easily integrate go into
C/++
18:20 < Ginto8> but you can call C code from Go
18:20 * {aaron} nods
18:20 < {aaron}> yes, you can check in any time you like but you can't never
leave
18:20 < Ginto8> also, goroutines would be difficult to handle via C++
18:20 < Ginto8> well yeah I guess
18:20 < Ginto8> but there are very valid reasons
18:20 < Ginto8> also, go is awesome
18:20 < Ginto8> =P
18:21 < {aaron}> yeah i'm just trying to figure out how i get from the suck
to the awesome
18:22 < Ginto8> is your only issue that you can't integrate go into C/++?
18:22 < KirkMcDonald> So if I want to use a C API which makes heavy use of
callbacks, can Go do this?
18:22 < Ginto8> KirkMcDonald, if by callbacks you mean function pointers,
then no
18:22 < {aaron}> well, it's a theoretical issue...  if i want to develop any
module or plugin for a C app I immediately start looking for some alternative that
C can link to
18:22 < Ginto8> because Go has closures, and functions are first class types
18:22 < KirkMcDonald> (Yes, I mean function pointers.)
18:23 < Ginto8> no
18:23 < Ginto8> you can't use the callbacks
18:23 < Ginto8> because go's first class functions are very different =/
18:23 < KirkMcDonald> This does not preclude having some way to explicitly
define a function as using the C call spec.
18:23 < Ginto8> hm
18:23 < Ginto8> idk
18:23 < KirkMcDonald> (Which implies not being able to use a closure on that
function, etc.)
18:24 < Ginto8> but I do know that I'm probly gonna end up rewriting lua in
go so that I can use it for my game engine =D
18:24 < Ginto8> but that'll give me some good experience, so it won't be too
bad
18:24 < {aaron}> Ginto8: isn't that going to rely heavily on "callbacks"?
18:24 < KirkMcDonald> I think it is also work comparing this to how D does
it.
18:25 < KirkMcDonald> {aaron}: Not an issue, if you have a Lua interpreter
written in Go.
18:25 < Ginto8> {aaron}, yes, that's why I'm rewriting it
18:25 < {aaron}> i see
18:25 < Namegduf> KirkMcDonald: Yes, it does.
18:25 < Namegduf> Preclude that, I mean.
18:25 < {aaron}> game engine is go then?
18:25 < Ginto8> yeppers
18:25 < KirkMcDonald> Namegduf: How so?
18:25 < Namegduf> The function must be aware that it could run out of stack
space.
18:26 < Ginto8> still getting the bare bones stuff workin atm tho
18:26 < Namegduf> And able to grow stack space as necessary.
18:26 < Namegduf> Unless there's a way to design that to work both on and
off segmented stacks..
18:26 < KirkMcDonald> Namegduf: Some sort of shim, perhaps?
18:27 < KirkMcDonald> Then, of course, the callback will call Go
functions...
18:28 < Namegduf> Can't really say.
18:29 < Namegduf> I know the calling semantics are different and have to be
different to be compatible with the stacks, but not what they actually need to do
in any detail aside "deal with it", and thus not how that could be wrapped
efficiently (or otherwise)
18:30 < KirkMcDonald> In D, there are distinct 'function' and 'delegate'
types.
18:30 < Ginto8> delegates are just unusual closures right?
18:30 < KirkMcDonald> Where a function is just a dumb function pointer (as
in C), and a delegate is basically a struct with a function pointer and a context
pointer.
18:31 < Ginto8> yeah that's it
18:31 < KirkMcDonald> Delegates can refer to both closures, and act as
"bound method" pointers.
18:31 < Ginto8> but isn't a delegate intended to point at methods?
18:31 < Ginto8> oic
18:31 < KirkMcDonald> It's both!  Very clever.
18:31 < Namegduf> While Go wraps this nicely
18:31 < KirkMcDonald> Yes.
18:31 < Ginto8> unfortunately that's one of the few good things about D
18:32 < KirkMcDonald> But the other part is that you can declare a function
pointer type as being an "extern(C)" function pointer type.
18:32 < Ginto8> and it all goes downhill from there
18:32 < {aaron}> looks like there is some work described here related to c
callign go: http://cheesesun.blogspot.com/2010/04/callbacks-in-cgo.html
18:32 < Namegduf> So your idea is that you could have a function pointer +
metastuff to pass into C as a callback.
18:32 < KirkMcDonald> I am not certain what my idea is.
18:32 < Namegduf> Ah.
18:32 < Namegduf> Well, the problem is that you can't impose additional
rules on the C side
18:33 < Namegduf> Generally, anyway.
18:33 < KirkMcDonald> Naively, I would think you could define a function as
being extern(C), so that it uses the C callspec.
18:33 < Namegduf> And what it expects is a pointer that does what it wants.
18:33 < Namegduf> And can be called as it expects.
18:33 < KirkMcDonald> Right.
18:33 < Ginto8> {aaron}, that looks interesting
18:33 < Ginto8> I'm curious if they have that implemented yet?
18:33 < {aaron}> i dunno http://golang.org/cmd/cgo/
18:34 < Namegduf> I suspect the options for making that work are automatic
wrappers, and having it behave like a C function and Go functions calling it get
an automatic wrapper
18:34 < Ginto8> yeah the cgo page only has the import "C" bit
18:34 < KirkMcDonald> Namegduf: Yeah.
18:34 < {aaron}> here is a much longer thread discussing gtk bindings or
something
http://groups.google.com/group/golang-nuts/browse_thread/thread/87389ea9b01544f9/ee29a6af05829a82?lnk=gst&q=c#ee29a6af05829a82
18:34 < Namegduf> I suspect you'd need to get really invasive to make that
work, though.
18:40 -!- rhelmer [~rhelmer@adsl-69-107-67-90.dsl.pltn13.pacbell.net] has joined
#go-nuts
18:40 -!- GeoBSD [~geobsd@lns-bzn-33-82-252-55-34.adsl.proxad.net] has joined
#go-nuts
18:44 -!- Project-2501 [~Marvin@82.84.70.34] has joined #go-nuts
18:46 -!- GeoBSD [~geobsd@lns-bzn-33-82-252-55-34.adsl.proxad.net] has quit [Ping
timeout: 276 seconds]
18:47 -!- Project_2501 [~Marvin@82.84.94.103] has quit [Ping timeout: 276 seconds]
18:50 -!- Project_2501 [~Marvin@82.84.95.168] has joined #go-nuts
18:50 -!- sauerbraten [~sauerbrat@p508CB096.dip.t-dialin.net] has joined #go-nuts
18:50 -!- Project_2501 [~Marvin@82.84.95.168] has quit [Read error: Connection
reset by peer]
18:51 -!- GeoBSD [~geobsd@lns-bzn-33-82-252-55-34.adsl.proxad.net] has joined
#go-nuts
18:53 -!- Project-2501 [~Marvin@82.84.70.34] has quit [Ping timeout: 260 seconds]
19:01 -!- jchico [~jchico@cpe-98-14-12-209.nyc.res.rr.com] has joined #go-nuts
19:06 -!- zerofluid [~zerofluid@ip24-56-54-185.ph.ph.cox.net] has joined #go-nuts
19:08 < zerofluid> first "real" program - doing something stupid - pass
"change *[]int" into a function and can determine length from len(*change) - how
do I access values?  Getting "change is not a type" errors
19:09 < Ginto8> why are you passing a *[]int?
19:09 < Ginto8> []int is a slice
19:09 < Ginto8> slices are cheap
19:09 < Ginto8> they're 2 words
19:09 < Ginto8> well, maybe 3
19:09 < Ginto8> pointer,length,capacity
19:10 < zerofluid> um - because slices were a few slides down...
19:10 < zerofluid> and an array would have been ok - I get your point though
19:10 < Ginto8> just pass a slice
19:10 < Ginto8> it's cheap and idiomatic
19:11 < zerofluid> ok - thanks
19:11 < Ginto8> np
19:11 < Ginto8> you're lookin through the .pdf's in $GOROOT/doc right?
19:12 < Ginto8> that's the only place where I can think of slides being
used, unless it's the google talk
19:12 < zerofluid> GoCourseDay2
19:12 < zerofluid> yes
19:12 < Ginto8> yeah
19:12 < Ginto8> those are the BEST tutorials for go
19:12 < Ginto8> by far
19:13 < zerofluid> and I actually needed a static array for the first time I
can remember...  no problem :-)
19:13 < Ginto8> why did you need a static array?
19:15 < zerofluid> believe it or not, just a silly assignment with fixed
values
19:16 < Ginto8> well yeah actually I use static arrays quite a bit outside
of parameter passing
19:16 < zerofluid> seriously - thank you - using go because I had a choice
and I figured I might as well try to solve a problem in it - never used it before
- this assignment was a good excuse
19:16 < Ginto8> Go is a very good language
19:16 < Ginto8> extremely useful
19:17 < Ginto8> It was described by someone here as "C for the modern world"
19:17 < Ginto8> perfectly true
19:18 < zerofluid> just trying to wrap my little brain around a little chunk
of it now - take care :-)
19:18 -!- zerofluid [~zerofluid@ip24-56-54-185.ph.ph.cox.net] has quit [Quit:
Leaving]
19:19 < jchico> umm, how would you declare static variables in Go?
19:20 < jchico> I totally forgot about not having a static keyword
19:24 < Ginto8> declare them as a package global
19:24 < Ginto8> unexported package global*
19:27 < Eko> If you attempt a read from a synchronous channel, and then
later that channel closes without sending, it will return the zero value and be
closed() right?
19:28 < Eko> it doesn't have to be a read initiated *after* the channel is
closed to have those semantics?
19:28 -!- jchico [~jchico@cpe-98-14-12-209.nyc.res.rr.com] has quit [Ping timeout:
252 seconds]
19:29 < Ginto8> it should
19:29 -!- Elems [~Jake@c-98-215-113-215.hsd1.il.comcast.net] has joined #go-nuts
19:29 -!- Elems [~Jake@c-98-215-113-215.hsd1.il.comcast.net] has left #go-nuts []
19:30 < Eko> also, I've seen some of the Go source use structures as map
keys...  is this allowed?  I thought the go spec said it wasn't.
19:31 < Ginto8> nope
19:31 < Ginto8> not according to the spec =P
19:31 < Eko> that's what I thought, lol
19:32 -!- taruti [taruti@aoi.yi.org] has quit [Ping timeout: 265 seconds]
19:32 < Ginto8> mainly because there isn't any builtin struct equality
19:32 < Ginto8> cuz that would have to worry about whether it's
deep/shallow, whether to count unexported members,etc.
19:32 -!- jchico [~jchico@cpe-98-14-12-209.nyc.res.rr.com] has joined #go-nuts
19:45 < KirkMcDonald> You can use pointers to structs as map keys.
19:46 < Ginto8> yes, but that is...  well, you know
19:46 -!- deso [~deso@x0561a.wh30.tu-dresden.de] has quit [Read error: Connection
reset by peer]
19:46 < KirkMcDonald> If you just want to hash on identity, it could be
sufficient.
19:46 < Ginto8> yep
19:47 < Ginto8> but for most applications that isn't enough
19:47 < Ginto8> I'm curious if it would be possible to set it up so that
data types with an Equals() method would be usable as a map key?
19:47 < Ginto8> or a Hash() method
19:47 < Ginto8> or would you need a self-implemented hash table for that?
19:48 < KirkMcDonald> The spec could define a built-in "Hashable" interface,
perhaps, which maps would know how to understand.
19:48 < Ginto8> hm I guess
19:49 < Ginto8> that would be interesting
19:49 < KirkMcDonald> But then you'd need to distinguish between hashing a
pointer to a struct which implements this interface, and hashing on the interface.
19:49 < Ginto8> hm yeah
19:49 < KirkMcDonald> Since it is conceivable you'd want one or the other
behavior.
19:49 < Ginto8> yeah
19:49 -!- sully [~sully@bloomy.moroso.emarhavil.com] has left #go-nuts ["I'm not
sure why I'm here I don't like go"]
19:49 -!- Shyde [~Shyde^^@HSI-KBW-078-043-070-132.hsi4.kabel-badenwuerttemberg.de]
has quit [Quit: Shyde]
19:57 -!- rv2733 [~ron@c-98-242-168-49.hsd1.fl.comcast.net] has quit [Ping
timeout: 265 seconds]
20:00 -!- {aaron} [~xyz@pool-173-50-62-95.syrcny.east.verizon.net] has quit []
20:03 -!- taruti [taruti@aoi.yi.org] has joined #go-nuts
20:06 < Eko> well, for your (o *Object) Hash() you could either do { hash(o)
} or { o.hash() } to achieve one or the other
20:07 -!- Project_2501 [~Marvin@82.84.72.174] has joined #go-nuts
20:08 < Eko> before I go write a testcase to try, does anyone know if I can
do rfunc := func(x int) { ...  rfunc(x-1) }?
20:08 -!- sakirious [~saki@c-98-223-212-96.hsd1.il.comcast.net] has joined
#go-nuts
20:09 < Ginto8> no I don't think so
20:09 < Ginto8> but you'd have to check
20:09 < Ginto8> I know in lua at least that wouldn't work
20:10 < Ginto8> but idk about go
20:13 -!- jdp [~gu@24.238.32.162.res-cmts.segr.ptd.net] has joined #go-nuts
20:15 -!- Project_2501 [~Marvin@82.84.72.174] has quit [Ping timeout: 240 seconds]
20:15 < KirkMcDonald> That should work.
20:16 -!- cco3 [~conley@c-69-181-138-209.hsd1.ca.comcast.net] has joined #go-nuts
20:16 < KirkMcDonald> Since the variable rfunc exists in the outer scope,
and can be (statically) found by the inner function.
20:16 < KirkMcDonald> That the inner function is itself assign to that
variable should be irrelevant.
20:16 < KirkMcDonald> assigned*
20:16 < Namegduf> No, you can't.
20:17 < Namegduf> Because the variable rfunc does not exist in the outer
scope- yet.
20:17 < Namegduf> var rfunc <type>
20:17 < Namegduf> rfunc = func() { ...  }
20:17 < Namegduf> Will.
20:17 < KirkMcDonald> Hmm.
20:18 < Namegduf> The most hilarious problem that could possibly result from
"rfunc :=" is "return rfunc"
20:18 < Namegduf> In which case the type is fun to derive
20:18 < Ginto8> oh lol
20:18 < Ginto8> that would be ...  interesting
20:19 < KirkMcDonald> Curious.
20:20 < KirkMcDonald> So the initializer for a variable declaration is
evaluated before the declaration takes effect.
20:20 < KirkMcDonald> Which makes sense.
20:20 < Namegduf> Has to, if the declaration has its type implied by the
initializer.
20:20 < KirkMcDonald> For the same reason for x := x makes no sense.
20:20 < KirkMcDonald> Er, s/for/that/
20:21 < KirkMcDonald> Even in the case of: var x int = x
20:21 < Ginto8> yeah it's like that in lua
20:21 < Ginto8> in x = y y is evaluated first
20:21 < KirkMcDonald> Works in Python, though.  :-)
20:21 < Ginto8> then x gets set to y
20:21 < KirkMcDonald> That is: f = lambda: f()
20:21 < Namegduf> Python is untyped and scary
20:21 < KirkMcDonald> That works because the f inside te lambda is not
resolved until the function is called.
20:22 < Namegduf> Well, not really, just untyped.
20:22 < Namegduf> Yeah.
20:22 < KirkMcDonald> the*
20:22 < KirkMcDonald> It's not untyped.
20:22 < KirkMcDonald> It is dynamically, strongly typed.
20:22 < Namegduf> Okay, yeah
20:22 < Namegduf> It's strongly typed, but every variable is a void*
20:22 < Namegduf> Pointing at strongly typed things
20:22 < KirkMcDonald> A PyObject* :-)
20:23 < Ginto8> sounds...  a lot like lua =P
20:23 < str1ngs> and ruby
20:23 < KirkMcDonald> The "strongly" refers to the fact that e.g.  12 + '14'
is invalid.
20:23 < Namegduf> Right.
20:32 -!- bmizeran_ [~bmizerany@c-24-6-37-113.hsd1.ca.comcast.net] has quit
[Remote host closed the connection]
20:33 -!- belkiss [~belkiss@drn13-1-78-235-168-105.fbx.proxad.net] has joined
#go-nuts
20:34 -!- bmizerany [~bmizerany@c-24-6-37-113.hsd1.ca.comcast.net] has joined
#go-nuts
20:35 -!- rutkowski [~adrian@078088207115.walbrzych.vectranet.pl] has quit [Quit:
WeeChat 0.3.3-dev]
20:46 -!- sauerbraten [~sauerbrat@p508CB096.dip.t-dialin.net] has quit [Remote
host closed the connection]
20:46 -!- General1337 [~support@71-84-50-230.dhcp.mtpk.ca.charter.com] has joined
#go-nuts
20:50 -!- General13372 [~support@71-84-50-230.dhcp.mtpk.ca.charter.com] has quit
[Ping timeout: 276 seconds]
20:50 -!- aho [~nya@f051084134.adsl.alicedsl.de] has joined #go-nuts
20:59 -!- lmoura [~lmoura@187.78.130.104] has joined #go-nuts
21:03 -!- TR2N [email@89-180-179-16.net.novis.pt] has quit [Quit: Time left until
the Epochalypse: 27yrs 27wks 2days 12hrs 5mins 58secs]
21:05 -!- TR2N [email@89.180.179.16] has joined #go-nuts
21:05 -!- stalled [~stalled@unaffiliated/stalled] has quit [Ping timeout: 265
seconds]
21:07 -!- belkiss [~belkiss@drn13-1-78-235-168-105.fbx.proxad.net] has quit [Quit:
KVIrc Equilibrium 4.1.0, revision: 4632, sources date: 20100519, built on:
2010-07-09 07:13:47 UTC http://www.kvirc.net/]
21:10 -!- Fish [~Fish@9fans.fr] has quit [Remote host closed the connection]
21:12 -!- temoto [~temoto@95-25-191-59.broadband.corbina.ru] has quit [Ping
timeout: 240 seconds]
21:14 -!- sioraiocht [~tomh@unaffiliated/sioraiocht] has joined #go-nuts
21:17 -!- rlab [~Miranda@150-175-113-92.pool.ukrtel.net] has quit [Quit: Miranda
IM! Smaller, Faster, Easier.  http://miranda-im.org]
21:18 -!- General1337 [~support@71-84-50-230.dhcp.mtpk.ca.charter.com] has quit
[Ping timeout: 264 seconds]
21:20 -!- ako [~nya@f051073049.adsl.alicedsl.de] has joined #go-nuts
21:20 -!- aho [~nya@f051084134.adsl.alicedsl.de] has quit [Disconnected by
services]
21:21 -!- qIIp [~qIIp@72-173-156-132.cust.wildblue.net] has joined #go-nuts
21:22 -!- General1337 [~support@71-84-50-230.dhcp.mtpk.ca.charter.com] has joined
#go-nuts
21:24 -!- stalled [~stalled@unaffiliated/stalled] has joined #go-nuts
21:27 -!- qIIp [~qIIp@72-173-156-132.cust.wildblue.net] has quit [Quit: Lost
terminal]
21:28 -!- scarabx [~scarabx@c-76-19-43-200.hsd1.ma.comcast.net] has joined
#go-nuts
21:33 -!- artefon [~thiago@189.107.206.253] has quit [Ping timeout: 240 seconds]
21:37 -!- stalled [~stalled@unaffiliated/stalled] has quit [Ping timeout: 265
seconds]
21:37 -!- [Pete_27] [~noname@115-64-1-61.static.tpgi.com.au] has quit [Ping
timeout: 246 seconds]
21:42 -!- taruti [taruti@aoi.yi.org] has quit [Ping timeout: 276 seconds]
21:42 -!- tvw [~tv@e176004193.adsl.alicedsl.de] has joined #go-nuts
21:48 -!- scarabx [~scarabx@c-76-19-43-200.hsd1.ma.comcast.net] has quit [Quit:
This computer has gone to sleep]
22:01 -!- terrex [~terrex@84.122.67.111.dyn.user.ono.com] has quit [Quit:
Leaving.]
22:01 -!- thomas_b [~thomasb@cm-84.215.37.40.getinternet.no] has quit [Quit:
leaving]
22:03 -!- Wiz126 [~Wiz126@24.229.245.72.res-cmts.sm.ptd.net] has quit [Ping
timeout: 276 seconds]
22:10 -!- Wiz126 [~Wiz126@24.229.245.72.res-cmts.sm.ptd.net] has joined #go-nuts
22:13 -!- Jefus [~dereck@ip68-0-236-81.ri.ri.cox.net] has joined #go-nuts
22:14 -!- tvw [~tv@e176004193.adsl.alicedsl.de] has quit [Ping timeout: 245
seconds]
22:19 -!- stalled [~stalled@unaffiliated/stalled] has joined #go-nuts
22:28 -!- rhelmer [~rhelmer@adsl-69-107-67-90.dsl.pltn13.pacbell.net] has quit
[Ping timeout: 264 seconds]
22:29 -!- rhelmer [~rhelmer@adsl-69-107-79-191.dsl.pltn13.pacbell.net] has joined
#go-nuts
22:33 -!- Jefus [~dereck@ip68-0-236-81.ri.ri.cox.net] has quit [Remote host closed
the connection]
22:47 -!- fenicks [~christian@log77-3-82-243-254-112.fbx.proxad.net] has joined
#go-nuts
22:47 -!- kanru [~kanru@61-228-161-134.dynamic.hinet.net] has quit [Ping timeout:
240 seconds]
22:50 -!- KinOfCain [~KinOfCain@rrcs-64-183-61-2.west.biz.rr.com] has joined
#go-nuts
22:50 < fenicks> hello
22:51 < noodll> hey
22:51 -!- rhelmer [~rhelmer@adsl-69-107-79-191.dsl.pltn13.pacbell.net] has quit
[Ping timeout: 246 seconds]
22:53 -!- rhelmer [~rhelmer@adsl-69-107-65-192.dsl.pltn13.pacbell.net] has joined
#go-nuts
23:05 -!- rhelmer [~rhelmer@adsl-69-107-65-192.dsl.pltn13.pacbell.net] has quit
[Ping timeout: 260 seconds]
23:07 -!- rhelmer [~rhelmer@adsl-69-107-80-157.dsl.pltn13.pacbell.net] has joined
#go-nuts
23:27 -!- Boney_ [~paul@210-84-63-248.dyn.iinet.net.au] has joined #go-nuts
23:29 -!- Boney [~paul@203-217-70-220.dyn.iinet.net.au] has quit [Ping timeout:
240 seconds]
23:34 -!- ExtraSpice [~ExtraSpic@88.118.32.225] has quit [Ping timeout: 240
seconds]
23:37 -!- GeoBSD [~geobsd@lns-bzn-33-82-252-55-34.adsl.proxad.net] has quit [Quit:
Lost terminal]
23:42 -!- photron [~photron@port-92-201-142-142.dynamic.qsc.de] has quit [Ping
timeout: 248 seconds]
23:48 -!- EthanG [~ethan@sourcemage/guru/eekee] has joined #go-nuts
23:51 -!- zerofluid [~zerofluid@ip24-56-54-185.ph.ph.cox.net] has joined #go-nuts
--- Log closed Mon Jul 12 00:00:12 2010