--- Log opened Mon Nov 08 00:00:15 2010 00:01 -!- danslo [~daniel@s5593965d.adsl.wanadoo.nl] has quit [Quit: Leaving.] 00:06 -!- photron [~photron@port-92-201-249-233.dynamic.qsc.de] has quit [Ping timeout: 255 seconds] 00:15 -!- danslo [~daniel@s5593965d.adsl.wanadoo.nl] has joined #go-nuts 00:16 -!- XenoPhoenix [~Xeno@cpc5-aztw24-2-0-cust39.aztw.cable.virginmedia.com] has quit [Read error: Connection reset by peer] 00:17 < SirPsychoS> anyone know whether identical structs in C and Go have the same memory representation? 00:17 < SirPsychoS> that is, does the Go compiler handle address alignment and padding within structs identically to the C compiler? 00:18 < SirPsychoS> ohh hmm I guess that's not actually the question I meant to ask 00:19 < SirPsychoS> rather, are cgo-translated structs identical in memory representation to the same struct with Go types? 00:19 < SirPsychoS> I suppose they would have to be, since cgo just uses 'type C.int int32' and the like 00:20 < SirPsychoS> sooo I just answered my own question. now it's in the backlogs for future reference :D 00:23 < SirPsychoS> ohhh eww... one potential problem. How is the bool type stored in Go? 00:23 < SirPsychoS> hopefully it's a uint8 s.t. 1==true and 0==false? 00:26 -!- jhawk28 [~jhawk28@user-387c58d.cable.mindspring.com] has joined #go-nuts 00:27 -!- jhawk28 [~jhawk28@user-387c58d.cable.mindspring.com] has quit [Read error: Connection reset by peer] 00:27 -!- jhawk28_ [~jhawk28@user-387c58d.cable.mindspring.com] has joined #go-nuts 00:27 < SirPsychoS> beautiful! for future reference, a bool is stored as {u,}int8 where false==0, true!=0 00:28 -!- rlab [~Miranda@91.200.158.34] has quit [Quit: Miranda IM! Smaller, Faster, Easier. http://miranda-im.org] 00:34 -!- danslo [~daniel@s5593965d.adsl.wanadoo.nl] has quit [Remote host closed the connection] 00:38 -!- binarypie [~binarypie@c-24-6-151-185.hsd1.ca.comcast.net] has joined #go-nuts 00:40 -!- MX80 [~MX80@cust222.253.117.74.dsl.g3telecom.net] has joined #go-nuts 00:41 -!- danslo [~daniel@s5593965d.adsl.wanadoo.nl] has joined #go-nuts 00:44 -!- gnuvince_ [~vince@70.35.170.156] has quit [Quit: ""] 01:00 -!- artefon [~thiago@189.26.196.57.dynamic.adsl.gvt.net.br] has joined #go-nuts 01:02 -!- mikespook [~mikespook@58.62.4.218] has joined #go-nuts 01:13 -!- bikcmp [jason@botters/helper/bikcmp] has left #go-nuts [] 01:17 -!- kanru [~kanru@61-30-10-70.static.tfn.net.tw] has joined #go-nuts 01:27 -!- Scorchin [~Scorchin@host86-144-50-166.range86-144.btcentralplus.com] has quit [Quit: Scorchin] 01:31 -!- danslo [~daniel@s5593965d.adsl.wanadoo.nl] has quit [Quit: Leaving.] 01:41 -!- norlee [~lmumar@121.96.188.176] has joined #go-nuts 01:46 -!- Tuller [~tuller@c-69-143-52-174.hsd1.va.comcast.net] has joined #go-nuts 01:57 -!- Tuller [~tuller@c-69-143-52-174.hsd1.va.comcast.net] has quit [Remote host closed the connection] 01:59 -!- ville-_ [~ville@a107.ath.cx] has joined #go-nuts 01:59 -!- ronnyy [~quassel@p4FF1D04D.dip.t-dialin.net] has quit [Ping timeout: 245 seconds] 01:59 -!- ville- [~ville@a107.ath.cx] has quit [Ping timeout: 245 seconds] 02:01 -!- ronnyy [~quassel@p4FF1D04D.dip.t-dialin.net] has joined #go-nuts 02:01 -!- artefon [~thiago@189.26.196.57.dynamic.adsl.gvt.net.br] has quit [Quit: bye] 02:03 -!- danslo [~daniel@s5593965d.adsl.wanadoo.nl] has joined #go-nuts 02:04 -!- nsf [~nsf@jiss.convex.ru] has joined #go-nuts 02:06 -!- smw_ [~smw@pool-70-104-128-58.nycmny.fios.verizon.net] has joined #go-nuts 02:41 -!- SoniaKeys [~soniakeys@c-76-118-178-209.hsd1.ma.comcast.net] has joined #go-nuts 02:48 -!- jhawk28_ [~jhawk28@user-387c58d.cable.mindspring.com] has quit [Ping timeout: 276 seconds] 02:50 -!- tensorpudding [~user@99.148.202.191] has joined #go-nuts 02:55 -!- binarypie [~binarypie@c-24-6-151-185.hsd1.ca.comcast.net] has quit [Remote host closed the connection] 02:59 -!- devrim [~Adium@cpe-72-225-239-227.nyc.res.rr.com] has quit [Quit: Leaving.] 03:09 -!- devrim [~Adium@cpe-72-225-239-227.nyc.res.rr.com] has joined #go-nuts 03:20 -!- plainhao [~plainhao@mail.xbiotica.com] has quit [Quit: plainhao] 03:34 -!- rejb [~rejb@unaffiliated/rejb] has quit [Ping timeout: 276 seconds] 03:42 -!- gnuvince_ [~vince@70.35.167.208] has joined #go-nuts 03:52 -!- dj2 [~dj2@CPE001f5b35feb4-CM0014048e0344.cpe.net.cable.rogers.com] has quit [Remote host closed the connection] 03:54 -!- ronnyyy [~quassel@2001:6f8:12c6:1c86:224:1dff:fed7:9541] has joined #go-nuts 03:57 -!- ronnyy [~quassel@p4FF1D04D.dip.t-dialin.net] has quit [Ping timeout: 245 seconds] 04:03 -!- binarypie [~binarypie@c-24-130-113-34.hsd1.ca.comcast.net] has joined #go-nuts 04:09 -!- binarypi_ [~binarypie@c-24-130-113-34.hsd1.ca.comcast.net] has joined #go-nuts 04:10 -!- binarypie [~binarypie@c-24-130-113-34.hsd1.ca.comcast.net] has quit [Ping timeout: 245 seconds] 04:11 -!- sl [~stanleyli@68-179-130-17.bsr-c9-d1.evv.dhcp.sigecom.net] has joined #go-nuts 04:12 -!- binarypi_ [~binarypie@c-24-130-113-34.hsd1.ca.comcast.net] has quit [Remote host closed the connection] 04:35 -!- aho [~nya@fuld-4d00d684.pool.mediaWays.net] has joined #go-nuts 04:37 -!- ako [~nya@fuld-4d00d482.pool.mediaWays.net] has quit [Ping timeout: 245 seconds] 04:37 -!- scarabx [~scarabx@c-76-19-43-200.hsd1.ma.comcast.net] has joined #go-nuts 04:50 -!- Tv [~tv@cpe-76-168-227-45.socal.res.rr.com] has quit [Ping timeout: 276 seconds] 04:53 -!- SoniaKeys [~soniakeys@c-76-118-178-209.hsd1.ma.comcast.net] has quit [] 04:56 -!- iant [~iant@adsl-71-133-8-30.dsl.pltn13.pacbell.net] has quit [Ping timeout: 265 seconds] 04:56 -!- iant [~iant@216.239.45.130] has joined #go-nuts 04:56 -!- mode/#go-nuts [+v iant] by ChanServ 05:06 -!- zozoR [~zozoR@5634798d.rev.stofanet.dk] has joined #go-nuts 05:07 -!- tensorpudding [~user@99.148.202.191] has quit [Remote host closed the connection] 05:08 -!- cco3 [~conley@c-69-181-138-209.hsd1.ca.comcast.net] has quit [Ping timeout: 276 seconds] 05:23 -!- araujo [~araujo@gentoo/developer/araujo] has quit [Quit: Leaving] 05:24 -!- b00m_chef [~watr@66.183.108.186] has joined #go-nuts 05:34 -!- nsf [~nsf@jiss.convex.ru] has quit [Quit: WeeChat 0.3.3] 05:39 -!- norlee [~lmumar@121.96.188.176] has quit [Remote host closed the connection] 05:40 -!- norlee [~lmumar@121.96.188.176] has joined #go-nuts 05:47 -!- rbraley [~rbraley@ip72-222-128-78.ph.ph.cox.net] has quit [Ping timeout: 264 seconds] 05:50 -!- rbraley [~rbraley@ip72-222-128-78.ph.ph.cox.net] has joined #go-nuts 05:52 -!- zcram [~zcram@77-233-77-110.cdma.dyn.kou.ee] has joined #go-nuts 05:58 -!- noktoborus_ [debian-tor@gateway/tor-sasl/noktoborus] has quit [Ping timeout: 245 seconds] 06:02 -!- kanru [~kanru@61-30-10-70.static.tfn.net.tw] has quit [Quit: WeeChat 0.3.2] 06:02 -!- kanru [~kanru@61-30-10-70.static.tfn.net.tw] has joined #go-nuts 06:07 -!- zozoR [~zozoR@5634798d.rev.stofanet.dk] has quit [Quit: Morten. Desu~] 06:13 -!- scarabx [~scarabx@c-76-19-43-200.hsd1.ma.comcast.net] has quit [Quit: This computer has gone to sleep] 06:14 -!- devrim [~Adium@cpe-72-225-239-227.nyc.res.rr.com] has quit [Quit: Leaving.] 06:15 -!- devrim [~Adium@cpe-72-225-239-227.nyc.res.rr.com] has joined #go-nuts 06:46 -!- MashTomato [~ed@unaffiliated/mashpotato] has joined #go-nuts 06:47 -!- sacho [~sacho@83.228.17.51] has quit [Quit: Ex-Chat] 06:50 < SirPsychoS> is it just me, or is cgo broken with respect to multiple input files and anonymous structs? 06:50 -!- MashPotato [~ed@unaffiliated/mashpotato] has quit [Ping timeout: 245 seconds] 06:52 < SirPsychoS> it generates a struct named _Ctype_struct___1 for the first anonymous struct encountered in each cgo file, and if the first anonymous struct in one cgo file is different from the first in another cgo file, it errors with "inconsistent definitions for C type '_Ctype_struct___1'" 06:56 -!- b00m_chef [~watr@66.183.108.186] has quit [Ping timeout: 265 seconds] 07:04 -!- binarypie [~binarypie@c-24-130-113-34.hsd1.ca.comcast.net] has joined #go-nuts 07:06 -!- binarypie [~binarypie@c-24-130-113-34.hsd1.ca.comcast.net] has quit [Remote host closed the connection] 07:14 -!- nsf [~nsf@jiss.convex.ru] has joined #go-nuts 07:17 -!- rbraley [~rbraley@ip72-222-128-78.ph.ph.cox.net] has quit [Ping timeout: 245 seconds] 07:19 -!- noktoborus [debian-tor@gateway/tor-sasl/noktoborus] has joined #go-nuts 07:23 -!- fuzzybyte [~fuzzybyte@77.79.7.8] has joined #go-nuts 07:26 -!- rbraley [~rbraley@ip72-222-128-78.ph.ph.cox.net] has joined #go-nuts 07:43 -!- fabled [~fabled@83.145.235.194] has joined #go-nuts 07:50 -!- devrim [~Adium@cpe-72-225-239-227.nyc.res.rr.com] has quit [Quit: Leaving.] 08:05 -!- gnuvince1 [~vince@70.35.167.114] has joined #go-nuts 08:08 -!- gnuvince_ [~vince@70.35.167.208] has quit [Ping timeout: 252 seconds] 08:09 -!- ucasano [~ucasano@host153-182-static.227-95-b.business.telecomitalia.it] has joined #go-nuts 08:11 -!- |Craig| [~|Craig|@panda3d/entropy] has quit [Quit: |Craig|] 08:11 -!- noktoborus_ [debian-tor@gateway/tor-sasl/noktoborus] has joined #go-nuts 08:12 -!- noktoborus [debian-tor@gateway/tor-sasl/noktoborus] has quit [Ping timeout: 245 seconds] 08:18 -!- zcram [~zcram@77-233-77-110.cdma.dyn.kou.ee] has quit [Read error: Connection reset by peer] 08:21 -!- awidegreen [~quassel@p5DF1C39C.dip.t-dialin.net] has joined #go-nuts 08:22 -!- Fish [~Fish@86.65.182.207] has joined #go-nuts 08:54 -!- zcram [~zcram@77-233-77-110.cdma.dyn.kou.ee] has joined #go-nuts 09:00 -!- gr0gmint [~quassel@87.60.23.38] has joined #go-nuts 09:04 -!- sahid [~sahid@LNeuilly-152-21-22-10.w193-253.abo.wanadoo.fr] has joined #go-nuts 09:06 -!- derferman [~derferman@c-98-207-60-44.hsd1.ca.comcast.net] has quit [Quit: derferman] 09:13 -!- SirPsychoS [~sp@c-24-13-132-255.hsd1.il.comcast.net] has quit [Ping timeout: 264 seconds] 09:15 -!- wrtp [~rog@92.17.41.119] has joined #go-nuts 09:20 -!- rlab [~Miranda@91.200.158.34] has joined #go-nuts 09:29 -!- Fish [~Fish@86.65.182.207] has quit [Ping timeout: 240 seconds] 09:31 -!- mikespook [~mikespook@58.62.4.218] has quit [Quit: Leaving.] 09:36 -!- Fish [~Fish@86.65.182.207] has joined #go-nuts 09:37 -!- gnuvince_ [~vince@72.0.215.186] has joined #go-nuts 09:39 -!- gnuvince1 [~vince@70.35.167.114] has quit [Ping timeout: 240 seconds] 09:48 -!- ExtraSpice [~XtraSpice@88.118.33.48] has joined #go-nuts 10:01 -!- res99 [~anonymous@201.237.130.70] has quit [Ping timeout: 265 seconds] 10:13 -!- Fish [~Fish@86.65.182.207] has quit [Ping timeout: 276 seconds] 10:15 -!- aho [~nya@fuld-4d00d684.pool.mediaWays.net] has quit [Quit: EXEC_over.METHOD_SUBLIMATION] 10:22 -!- photron [~photron@port-92-201-102-143.dynamic.qsc.de] has joined #go-nuts 10:25 -!- wrtp [~rog@92.17.41.119] has quit [Read error: Connection reset by peer] 10:25 -!- res99 [~anonymous@201.237.130.70] has joined #go-nuts 10:25 -!- wrtp [~rog@92.17.41.119] has joined #go-nuts 10:30 -!- Gertm` [~Gertm@d51A45118.access.telenet.be] has joined #go-nuts 10:30 -!- Gertm` [~Gertm@d51A45118.access.telenet.be] has quit [Client Quit] 10:34 -!- gr0gmint [~quassel@87.60.23.38] has quit [Remote host closed the connection] 10:38 -!- SirPsychoS [~sp@c-24-13-132-255.hsd1.il.comcast.net] has joined #go-nuts 10:40 -!- fabled [~fabled@83.145.235.194] has quit [Quit: Ex-Chat] 10:43 -!- norlee [~lmumar@121.96.188.176] has quit [Ping timeout: 240 seconds] 10:46 -!- fabled [~fabled@mail.fi.jw.org] has joined #go-nuts 10:54 -!- artefon [~thiago@189.26.196.57.dynamic.adsl.gvt.net.br] has joined #go-nuts 11:00 -!- XenoPhoenix [~Xeno@cpc5-aztw24-2-0-cust39.aztw.cable.virginmedia.com] has joined #go-nuts 11:01 -!- Fish [~Fish@86.65.182.207] has joined #go-nuts 11:26 -!- mbohun [~mbohun@ppp115-156.static.internode.on.net] has joined #go-nuts 11:32 -!- rbraley [~rbraley@ip72-222-128-78.ph.ph.cox.net] has quit [Ping timeout: 240 seconds] 11:36 -!- rbraley [~rbraley@ip72-222-128-78.ph.ph.cox.net] has joined #go-nuts 11:38 -!- virtualsue [~chatzilla@nat/cisco/x-hsuouhmezwemnhte] has joined #go-nuts 11:48 -!- niemeyer [~niemeyer@189.73.144.110] has joined #go-nuts 12:04 -!- Tuller [~tuller@c-69-143-52-174.hsd1.va.comcast.net] has joined #go-nuts 12:09 -!- noktoborus__ [debian-tor@gateway/tor-sasl/noktoborus] has joined #go-nuts 12:10 -!- noktoborus_ [debian-tor@gateway/tor-sasl/noktoborus] has quit [Ping timeout: 245 seconds] 12:15 -!- MaksimBurnin [~max@44.188-224-87.telenet.ru] has quit [Ping timeout: 245 seconds] 12:16 -!- skejoe [~skejoe@188.114.142.231] has joined #go-nuts 12:19 -!- noktoborus__ [debian-tor@gateway/tor-sasl/noktoborus] has quit [Ping timeout: 245 seconds] 12:28 -!- Tuller [~tuller@c-69-143-52-174.hsd1.va.comcast.net] has quit [Remote host closed the connection] 12:31 -!- smw_ [~smw@pool-70-104-128-58.nycmny.fios.verizon.net] has quit [Ping timeout: 245 seconds] 12:35 -!- noktoborus [debian-tor@gateway/tor-sasl/noktoborus] has joined #go-nuts 12:35 -!- falconindy [~noclaf@unaffiliated/falconindy] has quit [Ping timeout: 250 seconds] 12:35 -!- sauerbraten [~sauerbrat@p508CACA8.dip.t-dialin.net] has joined #go-nuts 12:58 -!- noktoborus_ [debian-tor@gateway/tor-sasl/noktoborus] has joined #go-nuts 12:58 -!- noktoborus [debian-tor@gateway/tor-sasl/noktoborus] has quit [Ping timeout: 245 seconds] 13:05 -!- noktoborus_ [debian-tor@gateway/tor-sasl/noktoborus] has quit [Remote host closed the connection] 13:16 -!- devrim [~Adium@cpe-72-225-239-227.nyc.res.rr.com] has joined #go-nuts 13:21 -!- noktoborus [debian-tor@gateway/tor-sasl/noktoborus] has joined #go-nuts 13:38 -!- sacho [~sacho@83.228.17.51] has joined #go-nuts 13:49 -!- falconindy [~noclaf@unaffiliated/falconindy] has joined #go-nuts 13:56 -!- plainhao [~plainhao@mail.xbiotica.com] has joined #go-nuts 14:01 -!- fumblebee [~kgay@blk-142-24-126.eastlink.ca] has joined #go-nuts 14:02 -!- artefon [~thiago@189.26.196.57.dynamic.adsl.gvt.net.br] has quit [Quit: bye] 14:06 -!- falconindy [~noclaf@unaffiliated/falconindy] has quit [Quit: Lost terminal] 14:15 -!- iomox [~ios@180.191.95.177] has joined #go-nuts 14:19 -!- skejoe [~skejoe@188.114.142.231] has quit [Quit: leaving] 14:23 -!- femtoo [~femto@95-89-197-196-dynip.superkabel.de] has joined #go-nuts 14:24 -!- noktoborus [debian-tor@gateway/tor-sasl/noktoborus] has quit [Remote host closed the connection] 14:27 -!- scarabx [~scarabx@c-76-19-43-200.hsd1.ma.comcast.net] has joined #go-nuts 14:28 -!- danslo [~daniel@s5593965d.adsl.wanadoo.nl] has quit [Read error: Connection reset by peer] 14:30 -!- danslo [~daniel@s5593965d.adsl.wanadoo.nl] has joined #go-nuts 14:31 -!- devrim [~Adium@cpe-72-225-239-227.nyc.res.rr.com] has quit [Quit: Leaving.] 14:32 -!- Venom_X [~pjacobs@adsl-99-20-147-171.dsl.aus2tx.sbcglobal.net] has joined #go-nuts 14:32 -!- falconindy [~noclaf@unaffiliated/falconindy] has joined #go-nuts 14:36 -!- scarabx [~scarabx@c-76-19-43-200.hsd1.ma.comcast.net] has quit [Quit: This computer has gone to sleep] 14:56 -!- dj2 [~dj2@216.16.242.254] has joined #go-nuts 14:58 -!- araujo [~araujo@190.38.50.25] has joined #go-nuts 14:58 -!- araujo [~araujo@190.38.50.25] has quit [Changing host] 14:58 -!- araujo [~araujo@gentoo/developer/araujo] has joined #go-nuts 15:04 -!- wrtp [~rog@92.17.41.119] has quit [Ping timeout: 250 seconds] 15:09 -!- wrtp [~rog@92.17.41.119] has joined #go-nuts 15:10 -!- kanru [~kanru@61-30-10-70.static.tfn.net.tw] has quit [Ping timeout: 260 seconds] 15:12 -!- artefon [~thiagon@150.164.2.20] has joined #go-nuts 15:15 -!- d_m [d6@SDF.ORG] has quit [Read error: Connection reset by peer] 15:17 -!- d_m [d6@SDF.ORG] has joined #go-nuts 15:18 -!- noktoborus [debian-tor@gateway/tor-sasl/noktoborus] has joined #go-nuts 15:19 -!- MashTomato [~ed@unaffiliated/mashpotato] has quit [Remote host closed the connection] 15:31 -!- liron [~liron@ita4fw1.itasoftware.com] has joined #go-nuts 15:32 -!- artefon [~thiagon@150.164.2.20] has quit [Remote host closed the connection] 15:34 -!- artefon [~thiagon@150.164.2.20] has joined #go-nuts 15:40 -!- wrtp [~rog@92.17.41.119] has quit [Ping timeout: 255 seconds] 15:43 < Gertm> how do I go from []interface{} to []string ? (I'm sure there are strings in there, I just need to get them out) 15:44 < Gertm> also, I can't iterate over []interface{} ? 15:47 < yiyus> Gertm: with a type assertion 15:48 < yiyus> and yes, you can iterate 15:48 -!- zozoR [~zozoR@5634798d.rev.stofanet.dk] has joined #go-nuts 15:50 < Gertm> yiyus: hmm I must be doing something wrong then 15:50 < nsf> you can't convert one slice to another 15:51 < nsf> var is []interface{} 15:51 < nsf> var ss []string 15:51 < nsf> ss = make([]string, len(is)) 15:51 < nsf> for i, iface := range is { ss[i] = iface } 15:51 -!- artefon_ [~thiagon@150.164.2.20] has joined #go-nuts 15:51 < nsf> something like that 15:52 < nsf> oops 15:52 < nsf> the type assertion here should be 15:52 < nsf> of course :) 15:52 < nsf> for i, iface := range is { ss[i] = iface.(string) } 15:53 < Gertm> ok thanks, I'll have a lot when I get home from work. Time to go! 15:53 -!- artefon [~thiagon@150.164.2.20] has quit [Ping timeout: 252 seconds] 15:57 -!- devrim [~Adium@160.79.7.234] has joined #go-nuts 15:57 -!- sauerbraten_ [~sauerbrat@p508CF824.dip.t-dialin.net] has joined #go-nuts 15:59 -!- sauerbraten [~sauerbrat@p508CACA8.dip.t-dialin.net] has quit [Ping timeout: 260 seconds] 15:59 -!- rejb [~rejb@unaffiliated/rejb] has joined #go-nuts 16:02 -!- kanru [~kanru@114-45-231-36.dynamic.hinet.net] has joined #go-nuts 16:11 -!- devrim [~Adium@160.79.7.234] has quit [Ping timeout: 252 seconds] 16:16 -!- lmoura [~lauromour@186.212.109.42] has joined #go-nuts 16:18 -!- devrim [~Adium@160.79.7.234] has joined #go-nuts 16:22 -!- DerHorst [~Horst@e176096086.adsl.alicedsl.de] has joined #go-nuts 16:23 -!- Venom_X [~pjacobs@adsl-99-20-147-171.dsl.aus2tx.sbcglobal.net] has quit [Ping timeout: 276 seconds] 16:24 -!- Venom_X [~pjacobs@66.54.185.131] has joined #go-nuts 16:25 -!- zozoR2 [~zozoR@563461e3.rev.stofanet.dk] has joined #go-nuts 16:26 -!- noktoborus_ [debian-tor@gateway/tor-sasl/noktoborus] has joined #go-nuts 16:27 -!- noktoborus [debian-tor@gateway/tor-sasl/noktoborus] has quit [Ping timeout: 245 seconds] 16:29 -!- skelterjohn [~jasmuth@lawn-gw.rutgers.edu] has joined #go-nuts 16:32 -!- wrtp [~rog@89.240.101.98] has joined #go-nuts 16:32 -!- fumblebee [~kgay@blk-142-24-126.eastlink.ca] has quit [Ping timeout: 245 seconds] 16:34 -!- boscop_ [~boscop@f055067206.adsl.alicedsl.de] has joined #go-nuts 16:35 -!- gnuvince1 [~vince@70.35.171.223] has joined #go-nuts 16:35 -!- boscop [~boscop@f055150095.adsl.alicedsl.de] has quit [Ping timeout: 245 seconds] 16:35 -!- gnuvince_ [~vince@72.0.215.186] has quit [Ping timeout: 276 seconds] 16:40 -!- noktoborus__ [debian-tor@gateway/tor-sasl/noktoborus] has joined #go-nuts 16:42 -!- noktoborus_ [debian-tor@gateway/tor-sasl/noktoborus] has quit [Ping timeout: 245 seconds] 16:42 -!- nsf [~nsf@jiss.convex.ru] has quit [Quit: WeeChat 0.3.3] 16:45 -!- zozoR2 [~zozoR@563461e3.rev.stofanet.dk] has quit [Quit: Morten. Desu~] 16:45 -!- gzmask [~ray@corwin.cat.uregina.ca] has joined #go-nuts 16:46 < gzmask> any easy way to convert string to []uint? 16:48 -!- skejoe [~skejoe@188.114.142.231] has joined #go-nuts 16:49 <+iant> converting to []int is easy, assuming what you want is Unicode code points 16:49 <+iant> there is no easy conversion to []uint 16:49 <+iant> converting to []byte is also easy, and byte is unsigned 16:49 <+iant> so I guess it depends on what you want 16:49 -!- Fish [~Fish@86.65.182.207] has quit [Read error: Connection reset by peer] 16:52 -!- noktoborus__ [debian-tor@gateway/tor-sasl/noktoborus] has quit [Ping timeout: 245 seconds] 16:52 < gzmask> iant: i guess []byte or []int will do 16:53 <+iant> can you give an example of an input string and what you want the result to look like? 16:53 < gzmask> iant: how do I convert to those? 16:53 < gzmask> iant: I am actually just trying to sent arguments to *websocket.Conn.Read([]uint8) 16:54 < mpl> iant: how expensive is transmitting, say a byte, over chan between two goroutines? I'm asking because I currently have some sort of a decoder with two goroutines having each their job to do; and a one way communication. and I've just found out I might need to add some sort of ack for each communication so that will double the number of transmission over the chan. 16:54 <+iant> gzmask: that reads into a buffer; do you mean write? 16:54 <+iant> gzmask: in any case, sounds like you want []byte(stringVariable) 16:54 < gzmask> iant: sorry, yea I meant write 16:55 <+iant> mpl: sending a byte over a channel is quite cheap, it's basically handled by the goroutine scheduler 16:55 < gzmask> iant: thanks. so if it's web socket server side, I need write to *websocket.Conn to sent messages to client? 16:55 <+iant> the more expensive part will be switching between the goroutines more often 16:55 <+iant> gzmask: sounds right, I haven't actually used websockets myself 16:56 < mpl> iant: hmm indeed. thanks. 16:56 < gzmask> iant: it's badass, 4ms for 12 packages. good enough for MMO in browser 16:57 -!- tensorpudding [~user@99.148.202.191] has joined #go-nuts 17:00 -!- artefon_ [~thiagon@150.164.2.20] has quit [Quit: Leaving] 17:03 -!- devrim [~Adium@160.79.7.234] has quit [Quit: Leaving.] 17:05 -!- noktoborus__ [debian-tor@gateway/tor-sasl/noktoborus] has joined #go-nuts 17:08 -!- mbohun [~mbohun@ppp115-156.static.internode.on.net] has quit [Quit: Leaving] 17:09 -!- saschpe [~quassel@77-23-177-40-dynip.superkabel.de] has joined #go-nuts 17:15 -!- d_m [d6@SDF.ORG] has quit [Quit: Lost terminal] 17:21 -!- awidegreen_ [~quassel@p5DF1EE68.dip.t-dialin.net] has joined #go-nuts 17:21 -!- Fish [~Fish@9fans.fr] has joined #go-nuts 17:22 -!- awidegreen [~quassel@p5DF1C39C.dip.t-dialin.net] has quit [Ping timeout: 245 seconds] 17:26 -!- d_m [d6@SDF.ORG] has joined #go-nuts 17:36 -!- Tv [~tv@gige.bur.digisynd.com] has joined #go-nuts 17:38 -!- iomox [~ios@180.191.95.177] has quit [Quit: Leaving] 17:38 -!- artefon [~thiago@189.26.196.57.dynamic.adsl.gvt.net.br] has joined #go-nuts 17:44 < anticw> iant: channels aren't gc'd presently are they? 17:44 <+iant> anticw: channels are gc'd, but goroutines are not, presently 17:44 -!- Venom_X [~pjacobs@66.54.185.131] has quit [Quit: Venom_X] 17:45 <+iant> so if you have only one reference to a channel from some goroutine that is waiting for something to happen on the channel, that will not currently be gc'ed 17:45 <+iant> which is certainly a bug 17:46 -!- willdye [~willdye@fern.dsndata.com] has quit [Read error: Connection reset by peer] 17:46 < anticw> iant: i thought might be the case ... so i tried to create channels, fill them with junk that has finalizerz ... then drop channel references and orce a GC 17:46 < anticw> s/orce/force/ 17:46 < MaybeSo> iant: is this specific to gccgo? 17:47 <+iant> anticw: really? it didn't work? 17:47 < anticw> nope 17:47 <+iant> MaybeSo: no, 6g/8g also 17:47 <+iant> gccgo and 6g/8g use the same garbage collector 17:47 < anticw> iant: i have to drain the channels explicitly 17:47 <+iant> huh 17:47 <+iant> I guess I was wrong 17:47 < anticw> maybe im not trying hard enough 17:47 < anticw> and channel references are harder to purge 17:47 < anticw> than the atoms i stuff into them 17:47 <+iant> yes 17:48 < gzmask> http://golang.org/pkg/websocket/#Handler in the example, what does "io.Copy(ws, ws)" do? Why I can not reproduce the effect using ws.Read()/ws.Write() ? 17:50 < skelterjohn> io.Copy(a, a) strikes me as potentially dangerous 17:50 < skelterjohn> depending on implementation 17:50 < skelterjohn> it could trigger an infinite loop of reading and writing the same data 17:50 < anticw> iant: ok, so if i create enough channels it does work for most of them 17:51 < anticw> iant: i guess there are pts floating about in more places 17:51 <+iant> ok 17:51 -!- willdye [~willdye@fern.dsndata.com] has joined #go-nuts 17:51 < gzmask> skelterjohn: can you explain what it does? 17:51 -!- willdye [~willdye@fern.dsndata.com] has left #go-nuts [] 17:51 < skelterjohn> well, i don't know how it is implemented without scannign the source, but there are two ways that come to mind 17:52 < skelterjohn> 1) read some from the second parameter, write it to teh first parameter, repeat until second parameter is empty 17:52 < skelterjohn> 2) read all from second parameter until its empty, then write it to the first parameter 17:52 < skelterjohn> 1) has an infinite loop if the 2nd and 1st parameters are the same 17:52 < skelterjohn> 2) will use too much memory in some very reasonable cases 17:53 < anticw> iant: ok, what's more is that multiple GC passes seems to make it work better, that's either because each pass is a scan/free/stop ... or because it just shuffles the code about more or dirties more regsiters 17:53 < gzmask> I feel like it's 1) 17:53 < skelterjohn> 1) is more likely 17:53 < skelterjohn> which means that io.Copy(a, a) could go wrong 17:54 < skelterjohn> but like i said, without reading the source, i don't know 17:54 < gzmask> any better way to do the echo websocket effect using only ws.Read() and ws.Write() ? 17:54 < skelterjohn> oh 17:55 < skelterjohn> that would probably be fine 17:55 < skelterjohn> since what is written to it is not hte same as what is read from it 17:55 < gzmask> no, it's reading from the client and writing back to the client 17:56 < skelterjohn> yes, which is consistent with what i said 17:56 -!- willdye [~willdye@fern.dsndata.com] has joined #go-nuts 17:56 < skelterjohn> unless your client is also an echo 17:56 -!- willdye [~willdye@fern.dsndata.com] has left #go-nuts [] 17:56 < gzmask> but how do I extract the client's message, process it then write back to client? 17:57 < skelterjohn> what is the bit that is holding you up? 17:58 < gzmask> well, my client is sending in packets constantly. on server side, ws.Read is picking first packet fine, but then ws.Write replys once and connection is stall where it's supposed to get the second packet and so on 17:58 -!- tux21b [~christoph@trujillo.srv.pocoo.org] has joined #go-nuts 17:59 < skelterjohn> what is your client objects Type? 17:59 < skelterjohn> so i know what to look for in the documentation =p 18:00 < gzmask> server: http://pastebin.com/zJmP7uTY client: http://pastebin.com/GSsLDc1u 18:00 < gzmask> it's probably because I get the channel idea wrong 18:01 < gzmask> client is javascript, so it's not thinking in channels 18:01 < anticw> iant: wrt to goroutinines being collected ... i assume that's for things stuck reading on channels w/ no other references or simliar? 18:01 <+iant> right 18:01 < anticw> i would call that a bug in some cases 18:02 < anticw> if you have lost channels and they are closed so those terminate ... or similar ... when you're code is broken you just have goroutines go away 18:02 < skelterjohn> gzmask: maybe call ws.Close()? 18:02 < gzmask> hmm, let me try 18:02 -!- werdan7 [~w7@freenode/staff/wikimedia.werdan7] has joined #go-nuts 18:03 < anticw> iant: if there are only _reader_ references i think you could arguable close the channel 18:03 -!- femtoo [~femto@95-89-197-196-dynip.superkabel.de] has quit [Ping timeout: 255 seconds] 18:03 < anticw> iant: so then anything stuck reading will eventually come unstuck 18:03 <+iant> yeah, it's not clear how best to handle these cases 18:03 <+iant> one can imagine a goroutine which just sends value on a channel 18:03 <+iant> as in the prime sieve example 18:04 <+iant> do we have to have a way to tell that goroutine to stop, or can we just drop all the read references to the channel? 18:04 < anticw> i dont think cleanup of writers is sane 18:04 <+iant> perhaps not 18:04 < anticw> for readers stuck in something like for event := range someChan 18:04 < anticw> closing event ... means those stop 18:04 < gzmask> skelterjohn: strange thing is, sometimes it picks up the packet, most of the time not 18:04 < anticw> i often do that, have queue workers for example 18:05 < skelterjohn> if there is a channel for which all goroutines who know about it are currently blocking for send, then those goroutines should be dropped, i think 18:05 < anticw> it would just mean i could be more lazy and not close the channels on the work-generator(s) 18:05 < skelterjohn> gzmask: that's a race condition 18:05 -!- noktoborus__ [debian-tor@gateway/tor-sasl/noktoborus] has quit [Ping timeout: 245 seconds] 18:06 < gzmask> isn't what I am doing same as io.Copy(ws, ws) ? 18:06 < skelterjohn> is there a fixed size to the message coming in? 18:06 < skelterjohn> gzmask: no - io.Copy will read until eof 18:06 < skelterjohn> your code reads until 512 or eof 18:07 -!- kanru [~kanru@114-45-231-36.dynamic.hinet.net] has quit [Ping timeout: 260 seconds] 18:07 < skelterjohn> and maybe doesn't even block - that is, when you try to read it just gives you what it has 18:07 -!- ucasano [~ucasano@host153-182-static.227-95-b.business.telecomitalia.it] has quit [Quit: ucasano] 18:07 -!- sk [~simon@cpc2-aztw22-2-0-cust358.aztw.cable.virginmedia.com] has joined #go-nuts 18:08 < gzmask> I see. So what I am doing, I'd better separate the connections for each packet? 18:08 -!- ucasano [~ucasano@host153-182-static.227-95-b.business.telecomitalia.it] has joined #go-nuts 18:08 < skelterjohn> that doesn't make sense to me, i don't know why you'd suggest it 18:08 < skelterjohn> which is not to say you're wrong 18:09 < sk> could anyone tell me how to make a one-to-many channel in go, in such a way that different goroutines can read a value send on the channel concurrently ? 18:09 < gzmask> I mean, I need a way to check the channel for incomming stuffs 18:09 -!- ucasano [~ucasano@host153-182-static.227-95-b.business.telecomitalia.it] has quit [Client Quit] 18:09 < gzmask> else I might getting nothing from ws.Read() 18:10 -!- noktoborus [debian-tor@gateway/tor-sasl/noktoborus] has joined #go-nuts 18:10 <+iant> sk: add a goroutine in the middle which reads from the channel and sends the value on multiple outgoing channels 18:11 < gzmask> or something like a while (ws.Read() != nil) loop 18:12 < skelterjohn> iant: problem with that is that the middle goroutine decides who gets which value, rather than it being a first come-first serve thing 18:12 <+iant> skelterjohn: I mean, send the value on every outgoing channel 18:12 < sk> iant: thanks but what you are suggesting is that the message is "forwarded" sequentially to on other channels, but what i would basically need is to output one value on one channel and be able to read it concurrently in many different goroutines, i don't know if that makes sense. 18:13 <+iant> do you want each goroutine to receive the value, or do you want only one goroutine to receive the value? 18:13 < skelterjohn> iant: ah 18:13 < plexdev> http://is.gd/gQdSs by [Andrey Mirtchovski] in go/doc/codewalk/ -- doc/codewalk: update for changes in log package 18:13 < sk> i want many goroutines to receive the same value at the same time 18:13 <+iant> so, send it on multiple outgoing channels. Make the outgoing channels buffered 18:14 < sk> out := make(chan int) 18:14 < sk> yes but that can only be done sequentially, no? 18:15 <+iant> it will appear to be concurrent; at some level all operations are sequential; what are you concerned about? 18:15 < sk> out := make(chan int) 18:15 < sk> go Routine1(out) 18:15 < sk> go Routine2(out) 18:15 < sk> out <- 1 18:15 < sk> i want to have both doing val := <- in and get the value 18:15 < gzmask> hmmm, what is the thread.sleep for go? 18:15 -!- derferman [~derferman@dsl092-048-218.sfo4.dsl.speakeasy.net] has joined #go-nuts 18:16 < sk> gazmask time.Sleep(seconds*1e9) 18:16 <+iant> sk: I'm saying you need to put a goroutine in the middle which reads from out and sends the value on two outgoing channels; you pass those two outgoing channels to Routine1 and Routine2 18:16 -!- rbraley [~rbraley@ip72-222-128-78.ph.ph.cox.net] has quit [Ping timeout: 255 seconds] 18:17 < gzmask> sk: thanks. 18:17 <+iant> go func() { for { v := <- out; out1 <- v; out2 <- v } }() 18:17 <+iant> go Routine1(out1); go Routine2(out2) 18:17 < sk> i see what you mean 18:18 < sk> but in that case i dont need the middle go routine 18:18 < sk> i could just go it from the first routine 18:18 < gzmask> skelterjohn: exactly what you said, ws.Read() does not block. I sleep before reading then I got the results 18:18 < skelterjohn> that makes sense 18:18 < sk> out := make(chan int) 18:18 < sk> go Routine1(out) 18:18 < sk> go Routine2(out) 18:19 < sk> sorry 18:19 < sk> out1 := make(chan int) 18:19 < sk> out2 := make(chan int) 18:19 < sk> go Routine1(out1) 18:19 < sk> go Routine2(out2) 18:19 < sk> out1 <- 1 18:19 < sk> out2 <- 1 18:19 <+iant> sure 18:20 < sk> thats exactly what i dont want ^^ 18:20 -!- rbraley [~rbraley@ip72-222-128-78.ph.ph.cox.net] has joined #go-nuts 18:20 < sk> if i have 100, i need to declare 100 channels 18:20 < sk> what i am looking at is a sort of producer consumer problem 18:20 <+iant> yes, but you can wrap it all up in functions so it's pretty simple 18:21 <+iant> I don't think there is another way in Go 18:21 < sk> :( 18:21 < skelterjohn> for val := range inChannel { for out := range outChannels { go func(val type, out chan type) { out <- val }(val, out) } } 18:21 < skelterjohn> wait - does the number of channels you want to write to depend on the value? 18:21 < sk> no 18:22 < sk> its fixed 18:22 < skelterjohn> then you can just have a slice of them 18:22 < skelterjohn> and do what i said 18:22 < skelterjohn> and it will work 18:22 < skelterjohn> well, that might be out of order, actually 18:22 < sk> thanks im checkin that code now 18:22 < skelterjohn> so you need to be a bit more clever 18:22 < skelterjohn> nvm 18:23 -!- zcram_ [~zcram@78-28-92-201.cdma.dyn.kou.ee] has joined #go-nuts 18:24 < sk> thanks skelterjohn 18:24 < skelterjohn> nooo - my code doesn't work in all cases :) 18:24 < sk> but i think this code is still writing a value to each channel sequentially 18:24 -!- virtualsue [~chatzilla@nat/cisco/x-hsuouhmezwemnhte] has quit [Quit: ChatZilla 0.9.86 [Firefox 3.5.15/20101026200251]] 18:24 < sk> i guess go does not support one - to - many channels :( 18:24 < skelterjohn> you are drawing a false conclusion 18:25 < skelterjohn> what does your use of "sequentially" apply to 18:25 <+iant> Go does not support arbitrary copying of values on a channel, that is correct; I don't see how that could be made coherent in general 18:25 < sk> out <- val is done sequentially 18:26 <+iant> what do you mean? 18:26 < skelterjohn> out <- val was done in a goroutine in my code 18:26 < skelterjohn> which means that it can happen any time after the "go" statement happens 18:26 -!- Project_2501 [~Marvin@dynamic-adsl-94-36-178-119.clienti.tiscali.it] has joined #go-nuts 18:26 < skelterjohn> (which is why my code was wrong - it did not preserve the order of the items from in to out 18:26 < sk> yes i know what you mean 18:27 < skelterjohn> then i don't know what you mean 18:27 -!- rbraley [~rbraley@ip72-222-128-78.ph.ph.cox.net] has quit [Ping timeout: 255 seconds] 18:27 -!- zcram [~zcram@77-233-77-110.cdma.dyn.kou.ee] has quit [Ping timeout: 255 seconds] 18:27 < sk> what your code is doing is firing up a go routine, that does the send 18:27 < sk> my problem is i want to declare only ONE channel 18:27 < sk> out <- val to it 18:27 -!- derferman [~derferman@dsl092-048-218.sfo4.dsl.speakeasy.net] has quit [Quit: derferman] 18:27 < skelterjohn> i thought you wanted many 18:27 < sk> and have many go routines picking the same value 18:28 < skelterjohn> that is not the semantics for a channel 18:28 < sk> it is for a one-to-many channel 18:28 < skelterjohn> it is not the semantics for a go chan type 18:28 <+iant> Go does not have the concept of a one-to-many channel 18:28 < skelterjohn> which is not the same as saying you can't have one-to-many data flow 18:29 < sk> yes that is true 18:30 < skelterjohn> any object that did that would have to keep track of state for many different destinations 18:30 < skelterjohn> might as well have a bunch of different channels 18:31 < sk> well i needed this concept for synchronizing go routines 18:31 < sk> so that when they receive a value from that channel they all start working on the value concurrently 18:31 < sk> a bit like using signals for pthreads 18:31 < skelterjohn> do you know how many values might be sent? 18:32 < sk> no 18:32 < sk> its variable 18:32 -!- femtoo [~femto@95-89-197-196-dynip.superkabel.de] has joined #go-nuts 18:32 < skelterjohn> do they have to all be working on the same one at the same time? or do they just have to do all of them, eventually? 18:32 -!- MaksimBurnin [~max@44.188-224-87.telenet.ru] has joined #go-nuts 18:33 < sk> they have to get the value at the same time 18:33 < skelterjohn> do they have to run in lock-step? can't move onto the next until all finish the previous? 18:33 < sk> yes 18:34 < skelterjohn> then this can be done with the outChannels being buffered with 1 slot 18:34 < sk> you mean with the previous code? 18:35 < skelterjohn> no 18:35 < skelterjohn> http://pastebin.com/ViCeFFZv 18:35 < skelterjohn> with that code 18:35 < skelterjohn> no goroutines launched 18:35 < skelterjohn> but it will keep things in lock step, and the buffer of size 1 will allow it to be sent to all channels 18:36 -!- Venom_X [~pjacobs@74.61.90.217] has joined #go-nuts 18:36 < sk> ok i see 18:37 < sk> this is pretty much what i need! 18:37 < skelterjohn> :) 18:37 < sk> thanks skelterjohn :) 18:37 < skelterjohn> my pleasure 18:37 < sk> still think Google should add an easy one-to-many channel implementation! 18:37 < skelterjohn> i disagree 18:38 < anticw> you could write one 18:38 < anticw> it's not clear that should be in the language 18:38 < skelterjohn> it would be fairly complicated, internally, and from syntax it wouldn't be clear where it should be applied 18:38 < sk> well with this example if i had 100 go routines waiting for value val, i would have to declare 100 channels 18:39 < sk> thats my only concern 18:39 < skelterjohn> channels are light weight 18:39 < sk> it would still work 18:40 < sk> also eventually, if i had 1000 channels say, by the time the for loop has arrived at the last iteration, the go routine that has gotten the value at the first iteration, could already have finished its work 18:41 < skelterjohn> whose fault is that :) 18:41 < skelterjohn> when the messaging takes more time than the processing, maybe you should just run things sequentially from the beginning 18:42 < sk> well maybe if i described my problem it would make more sense! 18:42 < skelterjohn> parallelization always has overhead, and running things on N goroutines will never be N times as fast 18:43 < sk> i am trying to write a processor simulation, for MIPS32 slightly changed.. , i need to have a clock channel as a mean to synchronize all elements of the processor pipeline, fetch decode execute writeback, i want all these to execute their operation upon receiving the clock signal, if you know what i mean? 18:43 < sk> fetch decode execute writeback are all go routines 18:44 < sk> but, i'll find a way! 18:44 < sk> :P 18:45 < skelterjohn> i have a different suggestion, then 18:45 < skelterjohn> one sec 18:45 < sk> thanks! 18:47 < skelterjohn> actually, no i don't :) 18:47 < skelterjohn> false alarm 18:47 < sk> ah don't worry about it 18:47 < sk> i'll use the example u gave me, i only have to write to 4 different channels 18:47 -!- ucasano [~ucasano@host153-182-static.227-95-b.business.telecomitalia.it] has joined #go-nuts 18:47 < sk> ^^ 18:49 < sk> i just wanted to make that look cleaner with a single value written written the clock channel, and picked up by all units at the same time, just like a real processor does.. 18:49 < sk> written to* the clock channel 18:49 < sk> thanks for your help! 18:49 < sk> im back to coding.. 18:52 -!- SirPsychoS [~sp@c-24-13-132-255.hsd1.il.comcast.net] has quit [Ping timeout: 245 seconds] 18:53 < skelterjohn> it can certainly be cleaner than what i suggested 18:54 -!- derferman [~derferman@dsl092-048-218.sfo4.dsl.speakeasy.net] has joined #go-nuts 18:54 -!- derferman [~derferman@dsl092-048-218.sfo4.dsl.speakeasy.net] has quit [Client Quit] 18:58 -!- tvw [~tv@212.79.9.150] has joined #go-nuts 19:02 < plexdev> http://is.gd/gQhY6 by [Luuk van Dijk] in go/src/cmd/ld/ -- 6l/8l: generate dwarf variable names with disambiguating suffix. 19:04 -!- tvw [~tv@212.79.9.150] has quit [Remote host closed the connection] 19:12 -!- snearch [~snearch@f053011234.adsl.alicedsl.de] has joined #go-nuts 19:14 -!- derferman [~derferman@dsl092-048-218.sfo4.dsl.speakeasy.net] has joined #go-nuts 19:19 -!- fabled [~fabled@mail.fi.jw.org] has quit [Quit: Ex-Chat] 19:21 -!- iant [~iant@216.239.45.130] has quit [Ping timeout: 245 seconds] 19:24 -!- noktoborus [debian-tor@gateway/tor-sasl/noktoborus] has quit [Ping timeout: 245 seconds] 19:29 -!- TheMue [~TheMue@p5DDF6443.dip.t-dialin.net] has joined #go-nuts 19:34 -!- noktoborus [debian-tor@gateway/tor-sasl/noktoborus] has joined #go-nuts 19:34 -!- femtooo [~femto@95-89-197-196-dynip.superkabel.de] has joined #go-nuts 19:36 -!- femtoo [~femto@95-89-197-196-dynip.superkabel.de] has quit [Ping timeout: 252 seconds] 19:37 -!- iant [~iant@adsl-71-133-8-30.dsl.pltn13.pacbell.net] has joined #go-nuts 19:37 -!- mode/#go-nuts [+v iant] by ChanServ 19:38 -!- ucasano [~ucasano@host153-182-static.227-95-b.business.telecomitalia.it] has quit [Quit: ucasano] 19:45 < gzmask> why is this: http://pastebin.com/9tMzdx0R 19:45 < skelterjohn> because that read only happens once 19:46 < skelterjohn> if you do 19:46 < skelterjohn> for a; b; c { 19:46 < skelterjohn> a is executed exactly one time, before any looping 19:46 < skelterjohn> in the second code block, the read happens for every loop iteration 19:47 < gzmask> :( woot can't believe I didn't see this.... 19:49 -!- cskau [~user@0x573984e6.arcnqu1.dynamic.dsl.tele.dk] has joined #go-nuts 19:49 < cskau> hey 19:49 < gzmask> must be using that damn ruby for too long and haven't got a chance to use the for loop again.... 19:50 < cskau> I need a pointer on distributing a compile Go program .. any easy way to go about that ? 19:52 < cskau> to clarify: By distributing I mean deploying on a machine without Go "installed", sorry 19:52 < skelterjohn> the binary created can be distributed to machines with the right architecture 19:52 < skelterjohn> the runtime is included in the binary 19:52 < cskau> I get "missing lib" 19:53 < skelterjohn> it's all statically linked. or mostly statically linked 19:53 < skelterjohn> then iant is the guy to ask 19:53 -!- SirPsychoS [~sp@c-24-13-132-255.hsd1.il.comcast.net] has joined #go-nuts 19:53 < cskau> so I thought there might be a repacked solution 19:53 < cskau> *prepacked 19:53 < skelterjohn> it's probably something outside of the runtime 19:53 < skelterjohn> a glibc version or something 19:54 < cskau> 'libcgo.so' 19:54 < skelterjohn> ah 19:55 < skelterjohn> cgo stuff is harder 19:55 < skelterjohn> and i have no personal experience, sorry 19:55 < SirPsychoS> I'm working with cgo right now, what's going on? 19:56 < cskau> SirPsychoS: after deploying my tiny compiled program I get 'libcgo.so: cannot open shared object file: No such file or directory' 19:57 < cskau> is there an easy way of packing my program with all the necesary libs ? 19:57 < SirPsychoS> ooh, I don't know that :/ 19:57 < SirPsychoS> locate libcgo.a ? 19:57 < SirPsychoS> (maybe there's a static version) 19:58 < skelterjohn> it probably needs to be compiled specifically for the target platform 19:58 < skelterjohn> (not just the target architecture) 19:58 < SirPsychoS> ah, true 19:59 < cskau> so every machine I plan on deploying it on, I'll have to break out my compieler D: 19:59 < cskau> ? 20:00 < skelterjohn> if they're the same platform, you might be able to get away with sharing 20:00 < skelterjohn> both running similar versions of linux, for example 20:01 < cskau> still seems like a lot of work simply to deply your tiny program 20:01 -!- deso [~deso@x0561a.wh30.tu-dresden.de] has joined #go-nuts 20:01 < skelterjohn> i bet there is a way to have a package that just creates libcgo.so 20:01 < cskau> I was hoping too ;) 20:02 -!- devrim [~Adium@160.79.7.234] has joined #go-nuts 20:04 -!- saschpe [~quassel@77-23-177-40-dynip.superkabel.de] has quit [Remote host closed the connection] 20:10 -!- plainhao [~plainhao@mail.xbiotica.com] has quit [Quit: plainhao] 20:16 -!- femtooo [~femto@95-89-197-196-dynip.superkabel.de] has quit [Quit: Leaving] 20:18 < SirPsychoS> "cannot define new methods on non-local type" -> does this mean there's no way to split a (somewhat disjointed) package into two different packages that provide methods for the same type, without creating a new type in each one? 20:19 -!- zcram_ [~zcram@78-28-92-201.cdma.dyn.kou.ee] has quit [Quit: Leaving] 20:19 -!- zcram [~zcram@78-28-92-201.cdma.dyn.kou.ee] has joined #go-nuts 20:21 -!- ville-_ [~ville@a107.ath.cx] has quit [Remote host closed the connection] 20:21 -!- smw [~smw@pool-70-104-128-58.nycmny.fios.verizon.net] has joined #go-nuts 20:30 < cskau> if anyone is interested a quick fix for the problem with missing shared object files is simply to manually deploy said files and run you executable with 'LD_LIBRARY_PATH=.' .. 20:30 < cskau> it's rather stupid, and of course requires that you have the right SO files for the platform 20:34 -!- snearch [~snearch@f053011234.adsl.alicedsl.de] has quit [Quit: Verlassend] 20:37 < SirPsychoS> cskau: you could make a wrapper script so your users don't have to type out LD_LIBRARY_PATH= 20:40 < cskau> SirPsychoS: sure, only in this case I am the user :) I'm just deploying in the cloud 20:40 -!- ville- [~ville@a107.ath.cx] has joined #go-nuts 20:41 -!- zcram [~zcram@78-28-92-201.cdma.dyn.kou.ee] has quit [Quit: Leaving] 20:42 < SirPsychoS> ahh, makes sense 20:53 -!- SirPsychoS [~sp@c-24-13-132-255.hsd1.il.comcast.net] has quit [Ping timeout: 264 seconds] 20:54 -!- Tv [~tv@gige.bur.digisynd.com] has quit [Quit: Leaving.] 20:54 -!- Tv [~tv@gige.bur.digisynd.com] has joined #go-nuts 20:56 -!- [Pete_27] [~noname@110-174-103-31.static.tpgi.com.au] has quit [Ping timeout: 264 seconds] 20:56 -!- iant1 [~iant@nat/google/x-uhcumitegolleapw] has joined #go-nuts 20:57 -!- [Pete_27] [~noname@110-174-103-31.static.tpgi.com.au] has joined #go-nuts 20:59 -!- iant [~iant@adsl-71-133-8-30.dsl.pltn13.pacbell.net] has quit [Ping timeout: 264 seconds] 20:59 -!- gmilleramilar [~gmiller@184-106-207-119.static.cloud-ips.com] has left #go-nuts [] 21:03 -!- sk [~simon@cpc2-aztw22-2-0-cust358.aztw.cable.virginmedia.com] has left #go-nuts [] 21:04 -!- mode/#go-nuts [+v iant] by ChanServ 21:18 -!- rbraley [~rbraley@ip72-204-243-243.ph.ph.cox.net] has joined #go-nuts 21:25 -!- zozoR [~zozoR@5634798d.rev.stofanet.dk] has quit [Quit: Morten. Desu~] 21:28 -!- skejoe [~skejoe@188.114.142.231] has quit [Quit: Lost terminal] 21:34 -!- b00m_chef [~watr@66.183.108.186] has joined #go-nuts 21:36 -!- TheMue [~TheMue@p5DDF6443.dip.t-dialin.net] has quit [Quit: TheMue] 21:37 < plexdev> http://is.gd/gQuYc by [Rob Pike] in go/src/pkg/os/ -- os: add Expand function to evaluate environment variables. 21:40 -!- derferman [~derferman@dsl092-048-218.sfo4.dsl.speakeasy.net] has quit [Ping timeout: 252 seconds] 21:40 -!- deso [~deso@x0561a.wh30.tu-dresden.de] has quit [Remote host closed the connection] 21:41 -!- franksalim [~frank@108-65-76-174.lightspeed.sntcca.sbcglobal.net] has joined #go-nuts 21:42 -!- derferman [~derferman@dsl092-048-218.sfo4.dsl.speakeasy.net] has joined #go-nuts 21:43 -!- Eridius [~kevin@unaffiliated/eridius] has joined #go-nuts 21:46 -!- Project_2501 [~Marvin@dynamic-adsl-94-36-178-119.clienti.tiscali.it] has quit [Quit: E se abbasso questa leva che succ...] 21:47 -!- tvw [~tv@e176000183.adsl.alicedsl.de] has joined #go-nuts 21:57 -!- |Craig| [~|Craig|@panda3d/entropy] has joined #go-nuts 22:00 -!- sauerbraten [~sauerbrat@p508CF824.dip.t-dialin.net] has quit [Remote host closed the connection] 22:03 -!- skelterjohn [~jasmuth@lawn-gw.rutgers.edu] has quit [Quit: skelterjohn] 22:07 -!- falconindy [~noclaf@unaffiliated/falconindy] has quit [Quit: Lost terminal] 22:09 -!- falconindy [~noclaf@ool-18bba97a.dyn.optonline.net] has joined #go-nuts 22:09 -!- falconindy [~noclaf@ool-18bba97a.dyn.optonline.net] has quit [Changing host] 22:09 -!- falconindy [~noclaf@unaffiliated/falconindy] has joined #go-nuts 22:16 -!- b00m_chef [~watr@66.183.108.186] has quit [Ping timeout: 272 seconds] 22:18 < gzmask> hmm... I got "can't find import:" error when importing my own package at the same folder... 22:19 -!- wrtp [~rog@89.240.101.98] has quit [Ping timeout: 240 seconds] 22:20 < gzmask> well nvm, forgot the 6g the package first 22:20 < gzmask> forgot to* 22:25 -!- artefon [~thiago@189.26.196.57.dynamic.adsl.gvt.net.br] has quit [Read error: Connection reset by peer] 22:25 -!- wrtp [~rog@89.240.101.98] has joined #go-nuts 22:29 -!- b00m_chef [~watr@66.183.108.186] has joined #go-nuts 22:30 -!- Venom_X [~pjacobs@74.61.90.217] has quit [Quit: Venom_X] 22:34 -!- DerHorst [~Horst@e176096086.adsl.alicedsl.de] has quit [Remote host closed the connection] 22:39 -!- Fish [~Fish@9fans.fr] has quit [Remote host closed the connection] 22:39 -!- cskau [~user@0x573984e6.arcnqu1.dynamic.dsl.tele.dk] has quit [Quit: leaving] 22:40 -!- dj2 [~dj2@216.16.242.254] has quit [Remote host closed the connection] 22:41 -!- photron [~photron@port-92-201-102-143.dynamic.qsc.de] has quit [Ping timeout: 245 seconds] 22:48 -!- franksalim [~frank@108-65-76-174.lightspeed.sntcca.sbcglobal.net] has quit [Quit: Ex-Chat] 22:58 -!- rbraley [~rbraley@ip72-204-243-243.ph.ph.cox.net] has quit [Ping timeout: 240 seconds] 23:07 -!- wrtp [~rog@89.240.101.98] has quit [Quit: wrtp] 23:11 < plexdev> http://is.gd/gQCSd by [Rob Pike] in go/src/pkg/strconv/ -- strconv: quote erroneous string in errors 23:13 -!- kanru [~kanru@114-45-231-36.dynamic.hinet.net] has joined #go-nuts 23:18 -!- sk [~simon@cpc2-aztw22-2-0-cust358.aztw.cable.virginmedia.com] has joined #go-nuts 23:18 < sk> can anyone tell me how do to ParseInt on a string thx 23:20 < cbeck> sk: check out the strconv package 23:20 < smw> sk, read http://golang.org/pkg/strconv/ 23:21 < sk> thanks 23:29 < gzmask> is there a thing to let the main thread wait till all goroutine finishes then exit correctly? 23:30 < gzmask> like Thread.Waitall() ? 23:30 < Soultaker> isn't that the default behaviour? 23:30 < plexdev> http://is.gd/gQEqg by [Robert Griesemer] in go/src/pkg/os/ -- os.Expand: don't call append for each non-variable char 23:30 < gzmask> hmm, my websocket goroutine got kill after the main thread is done 23:31 < cbeck> No, when the main thread returns, the program exits 23:31 < Soultaker> seems so, yeah. 23:32 < cbeck> You can wait on a value back from each one 23:32 < gzmask> any built-in stuff instead of doing my channel to cooperate the threads? 23:34 < Soultaker> not that I know of, sorry. 23:35 < gzmask> hmm, thanks anyways. it's not that hard to make it 23:39 -!- liron [~liron@ita4fw1.itasoftware.com] has quit [Quit: liron] 23:42 -!- rlab [~Miranda@91.200.158.34] has quit [Quit: Miranda IM! Smaller, Faster, Easier. http://miranda-im.org] 23:50 < plexdev> http://is.gd/gQFZU by [Rob Pike] in go/src/pkg/json/ -- json: don't indirect before testing for custom unmarshaler 23:58 -!- dj2 [~dj2@CPE001f5b35feb4-CM0014048e0344.cpe.net.cable.rogers.com] has joined #go-nuts --- Log closed Tue Nov 09 00:00:15 2010