--- Log opened Tue Mar 22 00:00:50 2011
00:01 -!- ako [~nya@fuld-590c62a4.pool.mediaWays.net] has quit [Ping timeout: 255
seconds]
00:04 -!- jhawk28 [~jhawk28@user-387c58d.cable.mindspring.com] has quit [Quit:
Linkinus - http://linkinus.com]
00:04 -!- |Craig| [~|Craig|@panda3d/entropy] has quit [Read error: Connection
timed out]
00:06 -!- |Craig| [~|Craig|@panda3d/entropy] has joined #go-nuts
00:09 -!- napsy [~luka@88.200.96.18] has quit [Quit: Lost terminal]
00:09 -!- mertimor [~Adium@p5DC1DE8E.dip.t-dialin.net] has joined #go-nuts
00:10 -!- shakesoda [~colby@c-67-168-136-89.hsd1.wa.comcast.net] has joined
#go-nuts
00:10 -!- shakesoda [~colby@c-67-168-136-89.hsd1.wa.comcast.net] has quit [Read
error: Connection reset by peer]
00:11 -!- shakesoda [~colby@c-67-168-136-89.hsd1.wa.comcast.net] has joined
#go-nuts
00:12 -!- m4dh4tt3r [~Adium@c-69-181-223-245.hsd1.ca.comcast.net] has quit [Quit:
Leaving.]
00:13 -!- jhawk28 [~jhawk28@user-387c58d.cable.mindspring.com] has joined #go-nuts
00:17 < plexdev> http://is.gd/SKciRO by [Robert Griesemer] in 5 subdirs of
go/src/ -- go/printer, gofmt: avoid exponential layout algorithm
00:30 < steven> is converting to/from interface{} the same as "boxing"?
00:30 < steven> (and unboxing)
00:30 < steven> the end.
00:30 < steven> (of my question)
00:34 -!- adu [~ajr@softbank220043139062.bbtec.net] has quit [Quit: adu]
00:36 < kamaji> ..  how do you check if a map key doesn't have a value?
00:36 < kamaji> I tried myMap[key] == nil
00:36 < exch> kamaji: v, ok := m[key]; ok is false when key doesnt exist
00:36 < kamaji> oh, right
00:36 < kamaji> thanks
00:37 < dfc> value, exists := m[key] ; if exists { ...  }
00:37 -!- adu [~ajr@softbank220043139062.bbtec.net] has joined #go-nuts
00:43 -!- Scorchin [~Scorchin@host109-157-104-50.range109-157.btcentralplus.com]
has quit [Quit: Scorchin]
00:50 < kamaji> wait, "value" doesn't get set in that assignment?
00:51 < kamaji> oh god damnit, nevermind >_>
00:52 -!- adu [~ajr@softbank220043139062.bbtec.net] has quit [Quit: adu]
00:52 < kamaji> goinstall didn't update a library properly
00:52 < kamaji> or .....  at all
00:52 < steven> i havent used goinstall yet
00:52 < steven> seems sketchy
00:53 < kamaji> Well it's not working for me :\
00:54 < kamaji> setting a map value is like this, right: myMap[index] =
value
00:55 -!- mertimor [~Adium@p5DC1DE8E.dip.t-dialin.net] has quit [Quit: Leaving.]
00:59 < kamaji> skelterjohn: Is there a reason that Get/GetRow/GetColumn
aren't in an interface in gomatrix?
01:02 -!- nettok [~quassel@200.119.186.102] has joined #go-nuts
01:05 -!- Niedar [~bleh@ip68-99-166-222.hr.hr.cox.net] has joined #go-nuts
01:05 < steven> yes kamaji
01:06 < steven> what language are you best with or most-familiar with,
kamaji?
01:07 < kamaji> not sure really, I tend to skip around between them a bit
01:08 -!- Tuller [~tuller@c-69-143-52-174.hsd1.va.comcast.net] has quit [Quit:
Computer has gone to sleep.]
01:09 < kamaji> Just having a weird bug which I fixed but I don't know why
it worked
01:09 < steven> not good
01:12 < kamaji> yeah :\
01:12 < shakesoda> I love bugs that only occur once you've realized they
shouldn't have worked in the first place.
01:12 < kamaji> essentially when I did the V, ok := myMap[value]; if(ok ==
false) { initialize V }
01:12 < kamaji> V becomes unset after the if statement
01:12 < kamaji> no idea why
01:12 < kamaji> so I just added a V = myMap[value]
01:15 < kamaji> shakesoda: Had one of those earlier :D
01:15 -!- Tuller [~tuller@c-69-143-52-174.hsd1.va.comcast.net] has joined #go-nuts
01:15 < kamaji> library was doing bounds checking and fixing my shit code
01:19 -!- saturnfive [~saturnfiv@210.74.155.131] has joined #go-nuts
01:22 -!- werdan7 [~w7@freenode/staff/wikimedia.werdan7] has quit [Quit: Hi, I'm a
quit message virus.  Please replace your old one with this and help me take over
the world of IRC.]
01:32 -!- shvntr [~shvntr@116.26.130.226] has joined #go-nuts
01:45 -!- pothos [~pothos@111-240-170-131.dynamic.hinet.net] has quit [Remote host
closed the connection]
01:45 -!- pothos [~pothos@111-240-170-131.dynamic.hinet.net] has joined #go-nuts
01:46 -!- saturnfive [~saturnfiv@210.74.155.131] has quit [Read error: Connection
reset by peer]
01:46 < str1ngs> kamaji: you dont need the () in if statements
01:47 -!- saturnfive [~saturnfiv@210.74.155.131] has joined #go-nuts
01:47 < str1ngs> if ok { doStuff }
01:48 < str1ngs> if !of { fixIt }
01:48 < str1ngs> !ok*
01:51 < steven> i wonder why there is no wrapper around io.Writer to keep a
buffer of sendable data so that when its ready to be sent it will send whatevers
left even if it doesnt send all data each time
01:52 < kamaji> str1ngs: it makes me happy :p
01:52 < kamaji> but i'll stop doing
01:52 < kamaji> it
01:54 < str1ngs> kamaji: also if you did if V, ok := myMap[value]; ok ==
false { init V } then V would lose scope and you would have to declare it first
outside of the if statement
01:57 < str1ngs> steven: I'd have to see the context but probably because
there is stuff like bufio that work on Writer interfaces.  the interface needs to
be generic
01:58 < skelterjohn> kamaji: uh, because it didn't occur to me
02:00 < skelterjohn> what would be the purpose?
02:00 -!- bXi [bluepunk@irssi.co.uk] has quit [Ping timeout: 250 seconds]
02:01 -!- Tuller [~tuller@c-69-143-52-174.hsd1.va.comcast.net] has quit [Quit:
muffins]
02:08 -!- wtfness [~dsc@78.101.73.79] has joined #go-nuts
02:09 -!- nixness [~dsc@178.152.67.119] has quit [Ping timeout: 255 seconds]
02:09 -!- foocraft [~dsc@178.152.67.119] has quit [Ping timeout: 255 seconds]
02:09 -!- foocraft [~dsc@78.101.73.79] has joined #go-nuts
02:11 -!- Natch [~natch@c-6dcde155.25-4-64736c10.cust.bredbandsbolaget.se] has
joined #go-nuts
02:12 -!- Natch| [~natch@c-6dcde155.25-4-64736c10.cust.bredbandsbolaget.se] has
quit [Read error: Operation timed out]
02:12 -!- bXi [bluepunk@irssi.co.uk] has joined #go-nuts
02:15 -!- saturnfive [~saturnfiv@210.74.155.131] has quit [Ping timeout: 250
seconds]
02:15 -!- saturnfive1 [~saturnfiv@210.74.155.131] has joined #go-nuts
02:16 < kamaji> skelterjohn: well it's hard to reference a general matrix
type if you use those functions
02:16 < kamaji> skelterjohn: you have to specify Dense or Sparse
02:16 -!- |Craig| [~|Craig|@panda3d/entropy] has quit [Ping timeout: 260 seconds]
02:16 < skelterjohn> the idea is that if you want to actually get something
done, you specify which matrix impl you want to use
02:17 < skelterjohn> if you're just experimenting, you can use the interface
02:18 -!- m4dh4tt3r [~Adium@245.sub-75-210-48.myvzw.com] has joined #go-nuts
02:18 < kamaji> Ah right, I figured i'd be ok with not knowing which kind I
need at start
02:19 < skelterjohn> usually depends on what you want to do, rather than
what your data ends up being like :)
02:20 < kamaji> I was trying to generalize because some datasets are really
sparse and some are really dense
02:20 < kamaji> like imaging stuff tends to be dense, and text mining is
pretty sparse
02:21 < kamaji> but yeah, also not really sure what is necessarily being
done with the data, hehe
02:22 < skelterjohn> you don't usually write one program to do both image
processing and text mining :)
02:22 < Namegduf> What is your program doing, then?
02:23 -!- |Craig| [~|Craig|@panda3d/entropy] has joined #go-nuts
02:23 < skelterjohn> however, if you feel like making it part of the
interface, go for
02:23 < skelterjohn> it
02:23 < skelterjohn> it just didn't occur to me
02:23 < skelterjohn> but you'll need to add some extra code to make
everything fit
02:23 < Namegduf> Is that really going to be fast enough to be useful?
02:24 * Namegduf isn't sure.
02:24 < kamaji> Namegduf: well it's supposed to be a machine learning
library
02:24 < skelterjohn> i can't answer that question, because i don't know what
bottle neck you're thinking about, or what task it needs to be fast/useful for
02:24 < kamaji> I'm thinking storing data as matrices may have been a
mistake, but it does make stuff like PCA easier
02:25 < kamaji> and I want to avoid copying stuff a lot
02:26 < skelterjohn> then maybe making those functions part of the Matrix
interface makes sense
02:26 < kamaji> but I need a 2D structure for storing features anyway, so it
might as well be a matrix
02:26 < kamaji> skelterjohn: What extra code were you talking about?  Aren't
those methods already implemented?
02:27 < skelterjohn> i don't think pivot has them
02:27 < skelterjohn> also, the current methods return the same matrix type
as they're called on
02:27 < skelterjohn> the Matrix interface would have to return Matrix
02:27 < skelterjohn> not *DenseMatrix
02:28 < kamaji> oh, true.  I didn't think of that
02:29 < skelterjohn> but pivot doesn't implement Matrix anyway - just
MatrixRO
02:30 < kamaji> ok, so just the type check
02:30 < kamaji> which I think is already implemented in some places, right?
02:31 < skelterjohn> not sure what you mean
02:32 < kamaji> I mean it does the check to return the correct type
02:32 < kamaji> I can basically copy/paste without fucking up :p
02:33 < skelterjohn> i might be dense, but...  what "it" are you referring
to
02:33 < skelterjohn> and what would you be copy/pasting
02:33 < str1ngs> kamaji: maybe pastebin some code be easier for skelterjohn
to help you
02:34 < kamaji> sorry, just nattering, I haven't started yet
02:35 < str1ngs> ah ok
02:35 < kamaji> i'm gonna do it when I get up this morning
02:35 < kamaji> because apparently it's 2:30AM
02:35 < skelterjohn> well that's a mistake
02:35 < skelterjohn> 2:30AM, that is
02:35 < kamaji> you're right, it's 2:38 :\
02:36 < kamaji> UTC is the only time :D
02:36 < kamaji> anyway, night!
02:36 < skelterjohn> night
02:41 < str1ngs> tabwriter is to much fun
02:41 < skelterjohn> what's tabwriter
02:41 < str1ngs> it does elastic tabs
02:41 < skelterjohn> what's an elastic tab
02:42 < str1ngs> http://golang.org/pkg/tabwriter/
02:42 < skelterjohn> oh very nice
02:42 < str1ngs> I do all my console output with it.  I'm hooked
02:43 < str1ngs> gofmt uses it to ..  I would think
02:45 < skelterjohn> gofmt has been around longer than that pkg, i think
02:45 < skelterjohn> then again, it's possible i just never noticed
tabwriter
02:45 < skelterjohn> and it'd been there all along
02:46 < str1ngs> well I would think it uses elastic tabs.  for stuff like
var ( foo = "stuff )
02:46 -!- Eladith [~valtias@gzrrplox.kortex.jyu.fi] has joined #go-nuts
02:47 < skelterjohn> i understand where it would be useful
02:47 < skelterjohn> but the whole "if it ain't broke" thing
02:47 < skelterjohn> my point was, gofmt already had code to do these things
02:49 < str1ngs> I guess so now that I look at it.  but you cant import
gofmt :P
02:49 -!- keithcascio [~keithcasc@nat/google/x-ivgngxdihcgounln] has quit [Quit:
Leaving]
02:49 < skelterjohn> if someone were to write gofmt now, it would probably
use tabwriter
02:49 < skelterjohn> well, i dunno
02:49 < str1ngs> ya I guess thats why I assumed it used tabwriter
02:55 < str1ngs> I should probably write a console ouput package.  with some
half ass terminal checking.
02:55 < skelterjohn> to what purpose?
02:56 < str1ngs> well for one Fprintf(os.Stderr,"stuff") is tedious
02:56 < str1ngs> when you want to use color raw ansi codes is bad
02:57 < str1ngs> checking terminal width would be sane to
03:03 < str1ngs> or you get stuff that looks like this
https://gist.github.com/880688
03:04 < str1ngs> but the nice thing is that the tabwriter work nice.  since
I have it use spaces
03:09 < str1ngs> terminal stuff can wait.  native decompressor and http
client more important
03:11 -!- jhawk28 [~jhawk28@user-387c58d.cable.mindspring.com] has quit [Quit:
Linkinus - http://linkinus.com]
03:12 -!- itrekkie [~itrekkie@ip72-201-208-165.ph.ph.cox.net] has quit [Quit:
itrekkie]
03:13 -!- leczb_ [~leczb@nat/google/x-qvkkojfukhyolxlw] has joined #go-nuts
03:13 -!- Xenith [~xenith@xenith.org] has quit [Ping timeout: 248 seconds]
03:13 -!- dfr|work [~dfr|work@nat/google/x-uwutdxfrweniavqp] has quit [Ping
timeout: 248 seconds]
03:13 -!- leczb [~leczb@nat/google/x-mnirqgoeamktmhxx] has quit [Ping timeout: 248
seconds]
03:20 -!- m4dh4tt3r [~Adium@245.sub-75-210-48.myvzw.com] has quit [Ping timeout:
276 seconds]
03:20 -!- Xenith [~xenith@xenith.org] has joined #go-nuts
03:26 -!- dfr|work [~dfr|work@nat/google/x-himjhpxteuphynkm] has joined #go-nuts
03:35 < steven> i dont really understand how bufio.Writer works or what it
does
03:35 < steven> the source isnt helping much honestly
03:37 < str1ngs> my take on it is it wraps a Reader Writer when then allows
you to preform buffer read/writes
03:37 < str1ngs> the second part confuses me to though about
03:38 < str1ngs> abit*
03:40 < str1ngs> I guess it all depends on what function you use to Read and
Write?
03:41 < steven> now im more confused
03:41 < steven> i joined #freenode and the member count was 666.  good sign
to get the fuck out, amirite?
03:42 < str1ngs> blind leading the blind bro :P
03:42 -!- nettok [~quassel@200.119.186.102] has quit [Ping timeout: 250 seconds]
03:43 < str1ngs> what do you need to do?
03:44 < steven> i have code that buffers my io.Writer, basically it sends
from the buffer when theres availability to send, and it adds to the buffer on the
other end of the client
03:45 < steven> and i was hoping this could be replaced by something in the
stdlib since its so boilerplate
03:45 < str1ngs> ah your buffering the writer by hand but you want to use
bufio instead?
03:45 < steven> yea
03:46 < steven> but im not sure how to use bufio to do what im doing.
03:46 < steven> i cant tell how the api is supposed to be used.
03:46 < str1ngs> I used bufio last year but stupid me I threw the toy
project away.  the trick is in the forloop.  if you are sue to while loops its
strange
03:46 < steven> currently, my send() method just appends to sendBuffer, and
i write from sendBuffer and remove the amount from the beginning of sendBuffer
that was successfully sent
03:47 < steven> ah
03:47 < steven> what language are you strongest with?
03:47 < str1ngs> gosh I know so may hard to say.  ..  Logo?
03:47 < str1ngs> many*
03:48 < steven> which ones then
03:48 < str1ngs> they vary on the language personlly I like ruby.  that was
before Go though
03:48 < steven> ok
03:48 < steven> i mean, which one are you most intimately familiar with?
03:48 -!- jesusaurus [jesusaur@firefly.cat.pdx.edu] has joined #go-nuts
03:49 < steven> as in, which one do you understand the most thoroughly?
03:49 < str1ngs> I understand most C type syntax languages.  the concepts
are not much differnt
03:49 < str1ngs> when it comes to pointers though I fail
03:49 < steven> ahh
03:49 < jesusaurus> is it possible to 'unget' a value from a channel, as in
to push it back onto the front?
03:50 < steven> jesusaurus: i dont think so.  why would you want to?
03:50 < jesusaurus> ok, i guess i should be using some sort of list then,
instead of a channel
03:51 < steven> or possibly rethinking your design
03:51 < steven> whichever
03:52 < jesusaurus> yeah, that too...
03:52 < jesusaurus> but i won't be able to tell if i've read too much data
until it's too late
03:53 < jesusaurus> its a context-sensitive problem
03:53 < str1ngs> steven: I guess what I ment about Logo joke is when you
have been hacking away since logo programming concepts blur together.  one
language cant define what you are good at.
03:55 < steven> k
03:55 < str1ngs> for loops are find are more C ish.  lack of while is
strange
03:55 < steven> know any lisp?
03:55 < str1ngs> but good
03:55 < str1ngs> never got into lisp or small talk
03:56 < steven> lisp + smalltalk = ruby
03:56 < steven> (lisp + smalltalk + perl = ruby, actually)
03:56 < str1ngs> perl,ruby,bash,minimal C.C# whole bunch of now defunct
stuff
03:56 < steven> not good to invest time in defunkt stuff
03:57 < str1ngs> at the time some of it was not defunct
03:57 < str1ngs> example ihtml.  which was like a early version of php
03:57 < str1ngs> pre asp even
03:58 < str1ngs> before that it was straight up CGI
03:59 < str1ngs> anyways where you work often dictates what you use.  not so
much now of course.  but back then it was
03:59 * steven is writing a web framework in Go :)
03:59 < steven> bypassing apache and cgi altogether :D
04:00 < str1ngs> web frameworks are great.  but hindsight is always 50/50 :P
04:00 < str1ngs> I'am instrested in you framework btw.  I hope its a nice
simple one
04:01 -!- gogogrrl_ [~max@p5DE8F93F.dip.t-dialin.net] has joined #go-nuts
04:02 -!- gogogrrl [~max@p5DE8F5C0.dip.t-dialin.net] has quit [Ping timeout: 260
seconds]
04:03 < steven> thanks
04:03 < steven> at the rate its going it wont hit 0.1 until 2015
04:03 < steven> that is, unless Jesus comes back before then.
04:03 < str1ngs> amen!
04:03 < steven> <3
04:04 < str1ngs> see I didnt even put php in that list
04:05 < steven> :D
04:05 < str1ngs> now I cant stand php :(
04:05 < steven> who can?
04:06 < plexdev> http://is.gd/hIUDCM by [Andrew Gerrand] in go/src/cmd/ld/
-- ld: return > 0 exit code on unsafe import
04:06 < steven> only mediocre programmers enjoy mediocre languages
04:06 < str1ngs> I think Go is about the most fun I've had in along time.  I
know that sound fanboish
04:07 -!- arun__ [~arun@pool-108-18-145-233.washdc.fios.verizon.net] has joined
#go-nuts
04:07 -!- arun_ [~arun@unaffiliated/sindian] has quit [Read error: Connection
reset by peer]
04:10 -!- arun__ [~arun@pool-108-18-145-233.washdc.fios.verizon.net] has quit
[Read error: Connection reset by peer]
04:10 < steven> its fun
04:10 < steven> i just wish it had better concurrency support
04:10 < steven> i was disappointed that my "threaded" quicksort
implementation wasnt much faster than my synchronous one
04:13 -!- rejb [~rejb@unaffiliated/rejb] has quit [Ping timeout: 246 seconds]
04:15 < str1ngs> have you tried gccgo?
04:17 -!- adu [~ajr@softbank220043139062.bbtec.net] has joined #go-nuts
04:19 -!- itrekkie [~itrekkie@ip72-201-208-165.ph.ph.cox.net] has joined #go-nuts
04:19 -!- tensai_cirno [~cirno@77.232.15.216] has quit [Ping timeout: 252 seconds]
04:21 < steven> nah
04:23 < str1ngs> they way they handle threads is different.  6g multiplex's
them and gccgo doesnt.  which iirc from what I read in passing makes gccgo more
optimized but limited in other regards
04:23 < str1ngs> I'll try and find the thread I was reading it was in
passing
04:25 < str1ngs> http://gcc.gnu.org/ml/gcc/2009-11/msg00420.html
04:26 < str1ngs> hmm seems thought gc is the preffered way so maybe I read
this wrong
04:27 < str1ngs> anyways I would not worry about speed, channels are meant
to be easy to use.  but there is room for optimization later
04:28 -!- krutcha1 [~krutcha@S010600045a27676a.vs.shawcable.net] has joined
#go-nuts
04:33 -!- krutcha1 [~krutcha@S010600045a27676a.vs.shawcable.net] has quit [Client
Quit]
04:33 -!- shvntr [~shvntr@116.26.130.226] has quit [Ping timeout: 248 seconds]
04:39 -!- edsrzf [~chickench@122-61-221-144.jetstream.xtra.co.nz] has joined
#go-nuts
04:43 -!- adu [~ajr@softbank220043139062.bbtec.net] has quit [Quit: adu]
04:45 -!- Niedar [~bleh@ip68-99-166-222.hr.hr.cox.net] has quit [Ping timeout: 250
seconds]
04:49 < jessta> str1ngs: gccgo generates more optimised code with the help
of gcc
04:50 < jessta> str1ngs: but it doesn't currently multiplex goroutines on to
threads, so you end up with one thread per go-routine
04:50 < jessta> makes creating go-routines slower and switching between them
slower too
04:50 < str1ngs> ah ok so ya I did read that part wrong
04:51 < str1ngs> I did notice gccgo make for smaller binaries if you do not
static build stuff
04:51 < str1ngs> but I'll working on a gccgo toolchain so I'll have more
time to play with it soon
04:54 < jessta> steven: did you set GOMAXPROCS?
04:56 < jessta> more threads just means more context switching unless you
have the cores to run them
04:57 < steven> yes.
04:57 < steven> i have an intel core i7
04:57 < steven> 4 cpus
04:59 < uriel> fuck, gnu grep is totally fucking broken
04:59 < uriel> I bet it is locale-related
05:01 < jessta> steven: the GC also seems to get in the way sometimes
05:01 < uriel> [A-Z] matches lower case letters with gnu grep!
05:02 < uriel> what the fucking hell?
05:03 < uriel> can somebody explain to me how the fucking hell is this
possible:
05:03 < uriel> $ ls |grep '^[ a-z]*\.pdf$'|sed 1q
05:03 < uriel> ACCESS.pdf
05:04 < uriel> unless gnu/grep is case insensitive by default
05:05 < uriel> ouch, wrong channel
05:05 < uriel> sorry :))
05:07 < exch> gnufail(tm)
05:08 -!- zozoR [~Morten@56344966.rev.stofanet.dk] has joined #go-nuts
05:08 < uriel> you got to wonder if they can get *anything* right
05:09 < str1ngs> though shall not take the gnu name in vain!  :P
05:09 < str1ngs> thou*
05:12 -!- fluf^arr [~camelid@s.pl0rt.org] has joined #go-nuts
05:12 -!- fluffle [~camelid@s.pl0rt.org] has quit [Read error: Connection reset by
peer]
05:14 -!- jyxent [~jyxent@129.128.191.96] has quit [Ping timeout: 276 seconds]
05:15 -!- jyxent [~jyxent@129.128.191.96] has joined #go-nuts
05:19 -!- Niedar [~bleh@ip68-99-166-222.hr.hr.cox.net] has joined #go-nuts
05:49 <@adg> meanwhile, "grep -i [A-Z]" _doesn't_ match lowercase
05:49 <@adg> figure that out
05:49 <@adg> oh wait
05:49 <@adg> echo A | grep -i '[a-z]'
05:50 <@adg> that is empty, on my mac
05:50 -!- dfc [~dfc@sydfibre2.atlassian.com] has quit [Ping timeout: 250 seconds]
05:50 <@adg> works in gnu grep though
05:54 -!- fabled [~fabled@mail.fi.jw.org] has joined #go-nuts
06:08 < plexdev> http://is.gd/nXUlUV by [Russ Cox] in go/src/cmd/prof/ --
gopprof: fix bug: do not rotate 180 degrees for large scrolls
06:08 -!- cmccabe [~cmccabe@c-24-23-254-199.hsd1.ca.comcast.net] has left #go-nuts
[]
06:10 -!- aho [~nya@fuld-590c6476.pool.mediaWays.net] has quit [Quit:
EXEC_over.METHOD_SUBLIMATION]
06:24 -!- zozoR [~Morten@56344966.rev.stofanet.dk] has quit [Remote host closed
the connection]
06:32 -!- itrekkie [~itrekkie@ip72-201-208-165.ph.ph.cox.net] has quit [Quit:
itrekkie]
06:43 -!- ExtraSpice [XtraSpice@88.118.35.153] has joined #go-nuts
06:43 -!- itrekkie [~itrekkie@ip72-201-208-165.ph.ph.cox.net] has joined #go-nuts
06:48 -!- adu [~ajr@softbank220043138128.bbtec.net] has joined #go-nuts
06:59 -!- rtharper [~tomh@unaffiliated/sioraiocht] has joined #go-nuts
07:01 -!- chomp [~ken@c-71-206-216-232.hsd1.pa.comcast.net] has quit [Remote host
closed the connection]
07:03 -!- Project_2501 [~Marvin@82.84.90.218] has joined #go-nuts
07:06 -!- nsf [~nsf@jiss.convex.ru] has joined #go-nuts
07:07 -!- rbraley [~rbraley@114.246.166.217] has quit [Ping timeout: 250 seconds]
07:07 -!- rbraley [~rbraley@114.246.166.217] has joined #go-nuts
07:23 < pingveno> I was just thinking...  Is there a chance that goinstall's
mechanisms could be adjusted to make packaging easier?
07:24 -!- shvntr [~shvntr@116.26.130.226] has joined #go-nuts
07:24 < pingveno> Actually, I'll just head over to the mailing list instead.
nvm
07:28 < str1ngs> goinstall's mechanism can handle it.
07:28 < str1ngs> pingveno: use go-hg.  use GOROOT_FINAL the reset is
PKGBUILD basics.  if you need to pastebin your PKGBUILD I can help you
07:30 < pingveno> I'm pretty sure that goinstall can't build without being
in the goinst group.
07:30 < pingveno> I get permissions issues.
07:31 < str1ngs> if you use goinstall from Community yes.  if you use
goinstall in a PKGBUILD no should not be an issue
07:31 -!- rtharper [~tomh@unaffiliated/sioraiocht] has quit [Remote host closed
the connection]
07:31 -!- Project_2501 [~Marvin@82.84.90.218] has quit [Read error: Connection
reset by peer]
07:31 < str1ngs> so my question is which one are you using?
07:32 < pingveno> ah
07:32 < pingveno> I'd like to be able to do both.
07:32 < str1ngs> ok.  which go PKGBUILD are you using go from community or
aur?
07:32 < pingveno> AUR
07:32 < pingveno> go-hg
07:32 < pingveno> But I changed it to use release, not a specific version
number.
07:33 < str1ngs> ok so all you need to do is change ownership of /opt/go .
assuming this is not a multiuser system
07:33 < pingveno> Ah, that's the thing.
07:33 < pingveno> I want this to work without screwing with permissions.
07:34 < str1ngs> well thats my point about those PKGBUILD's :P
07:34 < str1ngs> let me look at the aur PKGBUILD
07:34 < pingveno> The one I wrote?
07:36 < str1ngs> you wrote go-hg?
07:36 < str1ngs> ok ya so gpasswd -a $USER golang ..  then profit
07:36 < pingveno> no, no, no
07:36 < pingveno> That would be awesome
07:37 < pingveno> But no, I'm just trying to write a PKGBUILD for the AUR.
07:37 < str1ngs> why cant you do that
07:37 < str1ngs> ok for Aur it doesnt matter
07:37 < str1ngs> fakeroot takes care of that
07:37 < pingveno> http://pastebin.com/QJAKFCRi
07:38 < str1ngs> ok so what happens?
07:38 < pingveno> goinstall: github.com/hoisie/web.go: mkdir
/opt/go/src/pkg/github.com: permission denied
07:38 < pingveno> It still wants to immediately screw with $GOROOT.
07:39 < str1ngs> ok give me sec.  I need to find docs on GOROOT_FINAL.  do
you have any pointers to some?
07:40 < str1ngs> make go-hg the depencacy
07:40 < str1ngs> not go
07:40 < pingveno>
http://code.google.com/p/go/source/browse/src/cmd/goinstall/main.go#35
07:40 < pingveno> go-hg has provides=(go)
07:40 < pingveno> It's enough.
07:40 < str1ngs> no not is this case go is broken as far as I'm concerned
07:41 < str1ngs> and since you are using AUR its safe to assume then can
install go-hg
07:41 < str1ngs> when I say go broken I mean go Community
07:42 < str1ngs> http://golang.org/doc/install.html?h=GOROOT_FINAL much
better then source code :P
07:44 < str1ngs> pingveno: does go from community use goinst group?
07:44 < pingveno> Not sure.  I'm using go-hg.  It uses the "provides"
mechanism to allow me to ignore the go dependency.
07:45 < str1ngs> ya but that means if they have go from community installed
it should work
07:45 < str1ngs> ok for now lets do that.
07:46 -!- skelterjohn [~jasmuth@c-68-46-33-145.hsd1.nj.comcast.net] has quit [Ping
timeout: 255 seconds]
07:47 -!- skelterjohn [~jasmuth@c-68-46-33-145.hsd1.nj.comcast.net] has joined
#go-nuts
07:48 < pingveno> Okay, I switched over the dependency.
07:49 < str1ngs> hold up because that might be an issue
07:49 < str1ngs> what release was GOROOT_FINAL added?
07:51 < pingveno> I modified the go-hg PKGBUILD to use release.
07:51 < pingveno> It's as recent as I care to test.  :P
07:53 < str1ngs> ok one sec I'm not using release but shouldnt matter
07:53 < str1ngs> and you are better of using go-hg not release
07:53 < str1ngs> since that's what the end result will be
07:53 < pingveno> It doesn't really matter, me thinks.
07:54 < pingveno> I'll not do a modification next time, though.
07:54 < str1ngs> hmm why does he have a wrapper
07:55 < pingveno> go-hg PKGBUILD?
07:55 < str1ngs> ya
07:55 < str1ngs> I dont like that but w/e
07:55 < pingveno> Oh, yeah, I remember seeing that.
07:56 < str1ngs> anyways not the issue here
07:56 < str1ngs> lets assume that there for a good reason for now
07:58 < str1ngs> hmm GOROOT_FINAL assumes DESTDIR is GOROOT/src/GOROOT_FINAL
07:58 < str1ngs> let me verify this though
07:58 < pingveno> That seems...  odd...
07:59 < str1ngs> noinot
07:59 < str1ngs> no thats not it
08:01 < str1ngs> export GOROOT_FINAL=blah
08:01 < str1ngs> goinstall github.com/hoisie/web.go
08:01 < str1ngs> goinstall: github.com/hoisie/web.go: mkdir
/opt/go/src/pkg/github.com: permission denied
08:01 < pingveno> yup
08:01 < pingveno> I think that problem is from goinstall's logging.
08:02 < str1ngs> ok lets test that theory
08:02 < str1ngs> chown -R strings /opt/go :P
08:03 < pingveno> That is an easy way to take care of it.  :)
08:03 < str1ngs> you know use goinstall might not be the best way to do this
08:04 < str1ngs> maybe useing make . with install would be better
08:05 < pingveno> It looks like some projects might rely on goinstall to
write the Makefile for them.
08:05 < str1ngs> ok I need a pkg that works web.go is api broken..
08:05 < str1ngs> goinstall makes its own makefile if you use goinstall as
your devel makefile that just messed up imo
08:06 < pingveno> *shrug*
08:06 < str1ngs> quick I need a working package :P
08:06 < pingveno> It does look handy.
08:07 < pingveno> http://godashboard.appspot.com/package // pick your
package
08:07 < pingveno> Are you on Arch?
08:07 < pingveno> Or some other distro?
08:07 < str1ngs> I use arch
08:08 < pingveno> k
08:08 < str1ngs> goprotobuf*
08:08 < str1ngs> rawr
08:11 < pingveno> Exact same problem.  Do you still want the PKGBUILD?
08:11 < str1ngs> err oh side note you need to add git hg and bzr as a make
depend
08:11 < str1ngs> depending on where the goinstall PKGBUILD is hosted
08:11 < pingveno> Oh, right, of course
08:11 < str1ngs> naw stilling hacking away here
08:12 < str1ngs> I'm worried using tip might not be agood idea
08:12 < str1ngs> because I know there is some changes in goinstall comeing
up
08:13 < pingveno> If something that solves this problem gets in, that would
be ultra awesome.
08:13 < pingveno> goinstall -root=$pkgdir <source>
08:14 < pingveno> -fakeroot, -pkgroot, etc
08:14 < str1ngs> GOROOT_FINAL is fine
08:14 < str1ngs> same as DESTDIR
08:14 < pingveno> huh?
08:15 < str1ngs> make DESDIR=
08:15 < str1ngs> its good they use that its unifrom
08:15 < pingveno> It works right now or it will work?
08:15 < str1ngs> no
08:15 < str1ngs> I need a package that builds nothing builds
08:15 < str1ngs> one sec
08:15 -!- |Craig| [~|Craig|@panda3d/entropy] has quit [Quit: |Craig|]
08:16 < edsrzf> There will be a new environment variable: GOPATH.
08:17 -!- piranha [~piranha@5ED42E59.cm-7-5a.dynamic.ziggo.nl] has joined #go-nuts
08:17 < pingveno> edsrzf: Can it fit this exact use case?
08:17 < edsrzf> Proposal and discussion here:
http://groups.google.com/group/golang-dev/browse_thread/thread/92c7413c64fce3ed/f38ce695318aed55
08:17 -!- petrux [~petrux@host16-224-static.53-82-b.business.telecomitalia.it] has
joined #go-nuts
08:17 < edsrzf> Possibly
08:20 < str1ngs> edsrzf: GOPATH is intended to act as say DESTDIR would?
08:20 < str1ngs> GOPATH wont help
08:20 < str1ngs> I just read that
08:20 < pingveno> I'm thinking something close to:
https://aur.archlinux.org/packages/python-blist/PKGBUILD
08:20 < pingveno> Third line up from the bottom
08:23 < str1ngs> GOROOT_FINAL may not help.  and might be contingent on
GOROOT being unset
08:24 < str1ngs> The value assumed by installed binaries and scripts when
$GOROOT is not set.  It defaults to the value used for $GOROOT.  If you want to
build the Go tree in one location but move it elsewhere after the build, set
$GOROOT_FINAL to the eventual location.
08:25 < str1ngs> so this doesnt not do what you and I thought
08:25 < str1ngs> this is for building go into $pkgdir then moveing after the
fact
08:25 < pingveno> After reading a bit more, I had come to the same
conclusion.
08:25 < str1ngs> ie GOROOT=$pkgdir GOROOT_FINAL=/opt/go
08:26 < str1ngs> ok so..
08:26 < str1ngs> forget goinstall.  its work in progress
08:26 < str1ngs> use make
08:26 < str1ngs> with install
08:26 < str1ngs> not make install
08:26 < str1ngs> use run make
08:26 < str1ngs> then use /usr/bin/install to place into $pkgdir
08:27 < str1ngs> I hope that made sense :P
08:27 < pingveno> It did indeed make sense.
08:27 < pingveno> I wanted to avoid doing that.
08:28 < str1ngs> which is fine just use git hg bzr hook
08:28 < pingveno> Code duplication = bad.
08:28 < str1ngs> its not
08:28 < str1ngs> if the the projects dont have Makefile there not worth
packageing
08:28 < pingveno> Well...
08:28 < pingveno> That's a bit harsh.
08:28 < str1ngs> goinstall imo is not designed for this or should not be
expected to handle this
08:29 < str1ngs> the truth is harsh
08:29 < str1ngs> honestly go Makefile are simpel
08:29 < str1ngs> simple*
08:29 < pingveno> I wonder if something as sophisticated as setuptools will
eventually appear.
08:29 < str1ngs> no need goinstall handles that
08:30 < pingveno> setuptools for Python.  It's a nice package, from my
experience.
08:30 < str1ngs> and python is how old?
08:31 < pingveno> "...will eventually appear." ;)
08:31 < str1ngs> use make.  I fail to see why a package would not have a
Makefile
08:31 < str1ngs> package I mean go package
08:32 < pingveno> Yes, of course, of course.
08:32 < str1ngs> at the end odds are you will have either 1) a foo.a or 2)
/bin/foo
08:33 -!- dju_ [dju@fsf/member/dju] has quit [Quit: Quitte]
08:33 < pingveno> My other problem is that I'd like to make this as
automated as possible.
08:33 < str1ngs> this way is even better.  you can install /bin/foo to
/usr/bin/foo and go-hg is only a make depend
08:34 < str1ngs> the whole PKGBUILD think is redundant.  and scales badly
08:34 < str1ngs> like really badly
08:34 < pingveno> What do you mean by that?
08:34 * pingveno is just starting with packaging.
08:35 < str1ngs> case in point
http://projects.archlinux.org/svntogit/packages.git/tree/glibc/trunk/PKGBUILD
08:36 < str1ngs> that is for glibc look how massive that PKGBUILD's
footprint is
08:36 < pingveno> That's not *that* bad.
08:36 < str1ngs> shall I link the one for gcc :P
08:37 < pingveno> Me thinks those be just difficult to package.
08:38 < str1ngs> anyways that's offtopic.  just use make for now :P
08:38 < pingveno> k
08:39 < str1ngs> make a follow up on the ML about a DESTDIR equivilant
08:40 < str1ngs> its possible it exists but we are over looking it
08:42 < pingveno> I need to get to sleep.
08:42 < pingveno> Good night.  I'll do the follow up later.
08:43 -!- skejoe [~skejoe@188.114.142.162] has joined #go-nuts
08:44 < str1ngs> kk laters
08:51 -!- tensai_cirno [~cirno@nat.canmos.ru] has joined #go-nuts
09:00 -!- saturnfive1 [~saturnfiv@210.74.155.131] has quit [Quit: Leaving.]
09:00 -!- napsy [~luka@193.2.66.6] has joined #go-nuts
09:10 -!- tvw [~tv@212.79.9.150] has joined #go-nuts
09:12 -!- edsrzf [~chickench@122-61-221-144.jetstream.xtra.co.nz] has quit [Remote
host closed the connection]
09:27 -!- skejoe_ [~skejoe@188.114.142.162] has joined #go-nuts
09:28 -!- skejoe [~skejoe@188.114.142.162] has quit [Read error: Operation timed
out]
09:34 -!- shvntr [~shvntr@116.26.130.226] has quit [Ping timeout: 252 seconds]
09:42 -!- shvntr [~shvntr@116.26.130.226] has joined #go-nuts
09:44 -!- eaburns [~eaburns@c-24-62-248-129.hsd1.nh.comcast.net] has joined
#go-nuts
09:44 -!- tensai_cirno [~cirno@nat.canmos.ru] has quit [Ping timeout: 252 seconds]
09:54 -!- petrux [~petrux@host16-224-static.53-82-b.business.telecomitalia.it] has
quit [Read error: Connection reset by peer]
10:38 -!- rbraley [~rbraley@114.246.166.217] has quit [Ping timeout: 246 seconds]
10:47 -!- rbraley [~rbraley@114.246.166.217] has joined #go-nuts
10:52 -!- rbraley [~rbraley@114.246.166.217] has quit [Read error: Connection
reset by peer]
10:58 -!- foocraft [~dsc@78.101.73.79] has quit [Quit: Leaving]
10:58 -!- wtfness [~dsc@78.101.73.79] has quit [Remote host closed the connection]
11:03 -!- sacho [~sacho@46.10.16.35] has quit [Ping timeout: 276 seconds]
11:04 -!- gogogrrl_ [~max@p5DE8F93F.dip.t-dialin.net] has quit [Quit: leaving]
11:16 -!- jokoon [~jorinovsk@LMontsouris-156-26-32-176.w80-14.abo.wanadoo.fr] has
joined #go-nuts
11:23 -!- foocraft [~dsc@78.101.73.79] has joined #go-nuts
11:27 -!- boscop [~boscop@g227151009.adsl.alicedsl.de] has joined #go-nuts
11:30 -!- plainhao [~plainhao@208.75.85.237] has quit [Quit: plainhao]
11:33 -!- adu [~ajr@softbank220043138128.bbtec.net] has quit [Quit: adu]
11:35 -!- saturnfive [~saturnfiv@124.114.68.184] has joined #go-nuts
11:35 -!- saturnfive [~saturnfiv@124.114.68.184] has left #go-nuts []
11:44 -!- artefon [~thiago@dhcp10.usuarios.dcc.ufmg.br] has joined #go-nuts
11:56 -!- tensorpudding [~user@99.148.205.193] has quit [Read error: Connection
reset by peer]
12:12 -!- niemeyer [~niemeyer@201-66-179-18.pltce701.dsl.brasiltelecom.net.br] has
joined #go-nuts
12:12 -!- jokoon [~jorinovsk@LMontsouris-156-26-32-176.w80-14.abo.wanadoo.fr] has
quit [Quit: Quitte]
12:13 -!- foocraft [~dsc@78.101.73.79] has quit [Remote host closed the
connection]
12:16 -!- jgonzalez [~jgonzalez@173-14-137-134-NewEngland.hfc.comcastbusiness.net]
has joined #go-nuts
12:16 -!- tensai_cirno [~cirno@81.211.0.142] has joined #go-nuts
12:20 -!- wrtp [~rog@92.17.43.168] has joined #go-nuts
12:28 -!- tensai_cirno [~cirno@81.211.0.142] has quit [Ping timeout: 260 seconds]
12:39 -!- shvntr [~shvntr@116.26.130.226] has quit [Read error: Connection reset
by peer]
12:40 -!- shvntr_ [~shvntr@116.26.130.226] has joined #go-nuts
12:41 -!- shakesoda [~colby@c-67-168-136-89.hsd1.wa.comcast.net] has quit [Ping
timeout: 240 seconds]
12:42 -!- bortzmeyer [~bortzmeye@batilda.nic.fr] has joined #go-nuts
13:03 -!- MX80 [~MX80@cust151.253.117.74.dsl.g3telecom.net] has quit [Ping
timeout: 250 seconds]
13:05 -!- sauerbraten [~sauerbrat@p508CB41D.dip.t-dialin.net] has joined #go-nuts
13:06 -!- MX80 [~MX80@cust151.253.117.74.dsl.g3telecom.net] has joined #go-nuts
13:07 -!- zozoR [~Morten@56344966.rev.stofanet.dk] has joined #go-nuts
13:09 -!- unofficialmvp [~dev@94-62-164-227.b.ipv4ilink.net] has joined #go-nuts
13:09 -!- unofficialmvp [~dev@94-62-164-227.b.ipv4ilink.net] has left #go-nuts []
13:32 -!- foocraft [~dsc@78.101.73.79] has joined #go-nuts
13:33 -!- napsy [~luka@193.2.66.6] has quit [Quit: leaving]
13:34 < nsf> uhm, guys, what do you think about Go's type system?  I'm
trying to imagine how it would look like if there was a pointer arithmetic
13:34 < nsf> because converting each time integer offsets to a pointer type
would be painful
13:36 < taruti> parametric polymorphism would be nice
13:38 < nsf> yeah, that's a closed question for me, templates are a must,
but their form is an opened question
13:39 < nsf> regarding pointer arithmetic, I think I should allow mixing
pointer types with any integer types
13:39 < nsf> as array/slice indexing in Go does
13:40 < nsf> e.g.: var arr = [...]int{1,2,3,4,5}; var x uint8 = 2;
fmt.Println(arr[x])
13:40 < nsf> Go doesn't care about integer type used as index
13:41 < nsf> hm..  makes sense
13:45 < nsf> also another interesting aspect of Go is 'int'
13:45 < nsf> it's 32 bits on x86, and 64 bits on x86_64
13:45 < nsf> D has fixed-sized types
13:46 < nsf> C/C++ is a crazy story, but 'int' is 32 bits on both platforms
13:46 < nsf> I'm wondering what's the point of having 'int' as
platform-specific integer type
13:47 < eaburns> why not?  It seems desirable, to me, that 'int' without any
specification of the size is just the default word size for the current machine.
Most of the time the number of bits is unimportant.
13:47 < nsf> if one needs portability, one can define a config.go with
appropriate type definition
13:48 < nsf> but frankly it just confuses a bit
13:48 < nsf> most of the time 32 bit integer is enough
13:49 < nsf> in fact 64 bit integer is used in rare 'special type cases'
like unix time for example
13:49 < nsf> (e.g.  timers in general with high precision)
13:50 < nsf> and Go devs have removed the 'float' type
13:50 < nsf> why can't it be like an int then
13:51 < nsf> what's the point :(
13:52 < aiju> non-word sized data is a pain on some arches
13:52 < nsf> aiju: like?
13:52 < nsf> Go compiler supports arm, x86 and x86_64
13:52 < aiju> yeah, not on any of those
13:52 < nsf> are we talking here about one of them?
13:52 < nsf> hehe
13:52 < nsf> then what's the point?  :)
13:52 < aiju> in fact, 32 bit data is nicer than 64 bit data on amd64
13:53 < aiju> there are no 64 bit immediates except for MOV
13:54 < nsf> well, I guess I postpone this question for later, it's easy to
change the meaning of int anyway
13:54 * nsf is working on basics of his type system
13:54 < eaburns> my plan is to use 'int' whenever I don't care about the
size (99% of the time) and assume that the compiler uses the correct size :)
13:54 < nsf> eaburns: 32 bit size is ok in that case too
13:55 < nsf> but variable int size adds confusion in other places
13:55 < aiju> int used to be a 16 bit type
13:55 < nsf> for example it implicitly changes sizes of structs
13:55 < aiju> char/int/long/long long makes so much sense
13:55 < nsf> and in my case, even alignment
13:55 < nsf> I plan to use C compatible alignment of structs
13:55 < aiju> too much sense for whoever invented the current type system
13:55 < aiju> nsf: "C compatible alignment"?
13:55 < aiju> there is such a thing?
13:56 < aiju> shouldn't it rather be "GCC compatible alignment"?
13:56 < nsf> uhm..  C standard specifies alignment isn't it?
13:56 < eaburns> nsf: What do you mean by it changes sizes of structs?  You
mean across archs?
13:56 < nsf> eaburns: yeah
13:56 < aiju> nsf: not as far as i know
13:56 < aiju> 14:59 < eaburns> nsf: What do you mean by it changes
sizes of structs?  You mean across archs?
13:56 < nsf> aiju: I see, then gcc compatible, yeah
13:56 < aiju> structures need to be padded
13:56 < aiju> depending on the arch
13:57 < aiju> some arches (older ARM!) choke heavily on unaligned data
13:57 < aiju> some don't give a shit (x86)
13:57 < eaburns> aiju: sure, but if you need your structure to have a fixed
size across all archs then you probably want to specify the field size explicitly.
That sounds like a case where you don't want to use the variable sized int
13:57 < nsf> eaburns: good point
13:57 < aiju> you need a packed struct, then
13:57 < aiju> with specified endianness
13:58 < eaburns> then you probably want to use a byte array :)
13:59 < eaburns> Even C doesn't specify an int to be 32 bits it just happens
to be the case in practice.  If I write C code that needs a fixed size struct,
array or word then I never trust 'int', instead I use stdint.h for something with
a guaranteed size
14:01 < nsf> and stdint.h is unportable, hahaha
14:01 < nsf> but yeah, I got your point
14:02 < eaburns> Why is stdint.h unportable?  I always assume that it is (at
least with c99 which is what I try to use)
14:02 < skelterjohn> morning
14:02 < nsf> msvc doesn't implement c99
14:02 < nsf> for some weird reason
14:03 < nsf> I mean stdint.h being standard doesn't make it portable
14:03 < nsf> the same way as snprintf for example
14:03 < nsf> a lot of compiler has crappy libs where snprintf doesn't work
as C99 defines
14:04 < nsf> compilers*
14:04 < aiju> 15:05 < nsf> for some weird reason
14:04 < nsf> standard library isn't portable, hahaha
14:04 < aiju> it's called "there is C++"
14:04 < aiju> 15:06 < nsf> a lot of compiler has crappy libs where
snprintf doesn't work as C99 defines
14:04 < aiju> yeah, that's fucking C99's fault
14:04 < aiju> i mean how retarded can you be
14:04 < kimelto> :}
14:04 < eaburns> I see.  I really never use anything other than gcc and I
never really actually need to port any code that I write across platforms anyway
so I usually assume that adhering to the standard is good enough :)
14:05 < aiju> "let's take a function which does X and make it from one day
to another do Y"
14:05 < nsf> eaburns: exactly, that's practical!
14:05 < aiju> it's like passing a law that steering wheels have to work
backwards
14:05 < nsf> for me being portable for now means: x86, x86_64 support
14:05 < aiju> nsf: http://aiju.phicode.de/rant/portability
14:06 < nsf> "it can easily be ported, albeit requiring some rewrites (e.g.
UNIX)"
14:06 < nsf> that one is closer to me
14:06 -!- waqas [~waqas@jaim.at] has joined #go-nuts
14:06 < nsf> but for example if app runs on win/linux x86/x86_64
14:06 < nsf> and passes all tests
14:06 < nsf> I would call it portable
14:06 < aiju> then OS X users will complain
14:07 < nsf> well, OSX is close to *nix, it can be ported
14:07 < skelterjohn> yeah wtf let's get some os x love here
14:07 -!- sauerbraten [~sauerbrat@p508CB41D.dip.t-dialin.net] has quit [Remote
host closed the connection]
14:07 < aiju> you just have to figure out what the library is called this
week
14:07 < nsf> personally I don't care about OS X at all
14:07 -!- sauerbraten [~sauerbrat@p508CB41D.dip.t-dialin.net] has joined #go-nuts
14:08 < nsf> I think in my country it's less spread than linux :)
14:09 < nsf> although, maybe I'm wrong
14:09 < nsf> especially after iphone/ipad boom
14:09 -!- chou_ [~chou@softbank220014026215.bbtec.net] has joined #go-nuts
14:10 < skelterjohn> it's becoming very popular among academics
14:10 < aiju> shit is popular with academics
14:10 < nsf> aiju: :D
14:10 < aiju> i mean, they love scheme and what not
14:10 < skelterjohn> oh, aiju, always right there with good and useful
comments
14:10 < nsf> skelterjohn: well, I understand that
14:10 < nsf> accessible unix environment
14:10 < skelterjohn> but you can develop stuff on os x in the nice unix-y
way
14:11 < nsf> but, I don't care about OS X :)
14:11 < skelterjohn> much harder to do that with windows
14:11 < nsf> I have my linux here
14:11 < nsf> up and running
14:11 < aiju> Plan 9 Herrensystem
14:11 < nsf> it eats 100 megs after startup, and I know every daemon's face
14:11 < nsf> :D
14:12 -!- chou_ [~chou@softbank220014026215.bbtec.net] has left #go-nuts
["Leaving..."]
14:21 < nsf> oh, I have one more question
14:21 < nsf> what do you think about bitfields?
14:22 < nsf> D and Go don't have them
14:22 < aiju> evil
14:22 < nsf> why?  they are masking erm..  masking operations
14:22 < nsf> problems with atomic stuff
14:22 < aiju> hu?  what do you want to say?
14:23 < aiju> i don't see much point in bitfields
14:23 < skelterjohn> what is a bitfield?  something more than an int type
that you run & and | on?
14:23 < aiju> skelterjohn: looks like a struct, but it's actually bits of an
integer
14:23 < nsf> skelterjohn: struct { int a:4; int b:4; };
14:23 < nsf> struct fields that are smaller than 8 bits
14:23 < nsf> or well, they can be bigger
14:23 < skelterjohn> go can do that with unsafe
14:23 < nsf> 26 bits or something
14:24 < skelterjohn> [4]byte -> int64
14:24 < nsf> you can do that without unsafe
14:24 < skelterjohn> how?
14:24 < nsf> with bit ops
14:24 < skelterjohn> in one operation, i mean
14:24 < aiju> how do you do that with unsafe?
14:24 < skelterjohn> unsafe can just use that [4]byte as if it were an int64
14:24 < nsf> but that's only if you want to access bytes
14:24 < nsf> what about bits?
14:24 < skelterjohn> yes...
14:24 < skelterjohn> &, |
14:24 < nsf> exactly
14:25 < steven> is there any way to use real threads in Go?
14:25 < nsf> compiler translates access to bit fields to that..
14:25 < steven> like, manually?
14:25 < aiju> what the fuck
14:25 < skelterjohn> aiju: *(*int64(unsafe.Pointer(&the4Byte)))
14:25 < nsf> steven: afaik no
14:25 < steven> forcing a goroutine to execute simultaneously with another?
14:25 < steven> aw
14:25 < aiju> g++: deperecated conversion from string constant to 'char*'
14:25 < skelterjohn> steven: you can have gomaxprocs set to 2
14:25 < nsf> aiju: const char* vs.  char*
14:25 < aiju> oic
14:25 < aiju> (yuck)
14:26 < skelterjohn> then you will have two goroutines going at the same
time, if they can
14:26 < iTonnerre> ::c_str?
14:26 < nsf> aiju: in my lang string literal will be able to convert itself
implicitly to *byte
14:26 < nsf> no consts here
14:26 < nsf> :)
14:26 < aiju> compiling some older code
14:26 < nsf> yeah, that hurts sometimes
14:27 < nsf> some X11 interfaces has char**
14:27 < aiju> fucking gcc breaking code everytime
14:27 < nsf> and ask for this: const char *names[] = {"1", "2"};
14:27 < nsf> but you can't do that in gcc anymore
14:27 < aiju> there are ridiculous incompatibilities between GNU programs
14:27 < skelterjohn> char const *names[]
14:27 < aiju> like you can't build binutils-n.m.o with gcc-a.b.c
14:27 < nsf> skelterjohn: it's the same, at least in C++
14:27 -!- rejb [~rejb@unaffiliated/rejb] has joined #go-nuts
14:28 < aiju> const is evil
14:28 < skelterjohn> one applies to the (char*[])
14:28 < nsf> char * const names[] is something different
14:28 < skelterjohn> one applies to the (char*)s
14:28 < skelterjohn> oh
14:28 < skelterjohn> well i don't know it well enough :)
14:28 < aiju> i don't use const (and C++).  problem solved.
14:28 < nsf> const placement matters relative to '*'
14:28 < nsf> aiju: true
14:28 < skelterjohn> this is why i like go
14:28 < skelterjohn> it's not confusing
14:28 < nsf> any type qualifier has ugly property of being viral
14:29 < nsf> it spreads across function call hierarchy and then it's painful
to change it
14:29 < nsf> 'const' is amongst them
14:29 < skelterjohn> should never use const directly - always use a typedef
14:29 < nsf> hehe
14:30 < nsf> and interesting rule
14:30 < nsf> never tried it
14:32 < nsf> in fact, type specifier is viral too
14:32 < nsf> templates try to address that issue
14:32 < nsf> dynamic languages don't have that issue
14:33 < nsf> some langs (like clay programming language) have full program
type propagation (global type inference)
14:33 < nsf> http://tachyon.in/clay/
14:33 < aiju> dynamic languages have other issues
14:33 < aiju> i find their error handling extremely poor
14:33 < nsf> yeah
14:33 < nsf> no tests - no life
14:34 < nsf> although, it's true for any serious app
14:34 < nsf> :D
14:34 < aiju> refactoring is hell with dynamic languages
14:34 < aiju> to the point i rather rewrite the whole thing
14:34 < nsf> hm..  never heard that kind of opinion
14:35 < aiju> simple example: i change a variable name
14:35 < nsf> but I had zero practice writing big apps in dynamic languages
14:35 < aiju> in C the compiler yells at me
14:35 < nsf> aiju: ah, true
14:35 < aiju> in Javascript the value becomes "undefined"
14:35 < nsf> but you see, that's why there are tests
14:35 < aiju> (though Javascript is exceptionally bad)
14:35 < nsf> without tests you're doomed
14:35 < aiju> yeah, the compiler spits at me a line
14:35 < aiju> javascript can conceal the error very well
14:36 < aiju> undefined in an array does not cause an error etc
14:36 < aiju> simple in that example (a lint tool solves that case)
14:36 < aiju> try changing a structure slightly or something like that
14:36 < nsf> tests..  you need tests
14:37 < nsf> the only possible option
14:37 < aiju> yeah
14:37 < aiju> tests tell me it DOES fail
14:37 < aiju> but not WHY
14:37 < nsf> hm..
14:37 < nsf> I guess
14:38 < nsf> amongst other things static type system leads to better code
generation
14:38 < aiju> MUCH better code generation
14:38 < aiju> Common LISP has optional type specifications just for that
14:39 -!- pharris [~Adium@rhgw.opentext.com] has joined #go-nuts
14:39 < nsf> and in fact sometimes very strict type system helps you
optimize the code
14:39 < nsf> in tight C graphics loops, where things like integers and
floats got messed up
14:39 -!- plainhao [~plainhao@208.75.85.237] has joined #go-nuts
14:40 < nsf> it's useful to have zero implicit type conversions between
floats and ints
14:40 < nsf> because it's a bit slow
14:40 < nsf> (one way or another, I mean int -> float or float -> int,
don't remember)
14:40 < aiju> and it causes all kind of trouble
14:40 < nsf> yeah
14:41 < nsf> I'm wondering what should I do with structs
14:42 < nsf> tight packing like in Go, or gcc-like alignment by default
14:42 -!- tensai_cirno [~cirno@77.232.15.216] has joined #go-nuts
14:42 < nsf> because while importing C header I can do the same as cgo does
14:42 < nsf> insert all the padding members
14:42 < nsf> and if I want to use my lang from C
14:42 < nsf> there is #pragma pack(1)
14:42 -!- eaburns [~eaburns@c-24-62-248-129.hsd1.nh.comcast.net] has left #go-nuts
[]
14:43 < waqas> Hi guys, why would the compiler complain on the '++' in
tokens[tok_count++] = Token{ start: start, end: i - 1 }?  Removing it makes it
compile.
14:43 < aiju> waqas: x++ is a statement, not an expression
14:43 < aiju> tokens[tok_count] = ...  ; tok_count++
14:43 < waqas> Oh
14:43 < aiju> perhaps one of the worst Go design decisions ;P
14:43 < waqas> Unexpected
14:43 < nsf> aiju: why?  I think it's nice
14:44 < aiju> nsf: i like writing array[index++] =
14:44 < aiju> or actually i write *p++ = ..  :D
14:44 < nsf> *p = ..; p++;
14:44 -!- sauerbraten [~sauerbrat@p508CB41D.dip.t-dialin.net] has quit [Remote
host closed the connection]
14:44 < nsf> not a big difference to me
14:44 < waqas> I generally prefer all statements being expressions :)
14:44 < aiju> it's an extra line
14:45 < nsf> but simplifies compilator programming a bit
14:45 < aiju> bad enough ;P
14:45 < aiju> a tiny bit
14:45 < nsf> hehe, too bad, I'm doing the same in my lang
14:46 < aiju> and hurr durr it can even be more efficient on some arches :D
14:46 < nsf> although, I don't mind if someone will try to convert some of
the statements to expressions in future
14:46 < aiju> i'm currently playing with CL macros
14:46 < aiju> they are truly impressive
14:48 < nsf> but even if it's ok to have incdec expression
14:48 < nsf> I don't like the idea of assignment expression
14:48 < aiju> me neither
14:48 < nsf> e.g.  bool a = (x = true);
14:48 < aiju> the only point is providing multiple assignment
14:48 < nsf> a = b = c = true;
14:48 < nsf> hm..
14:48 -!- shvntr_ [~shvntr@116.26.130.226] has quit [Ping timeout: 246 seconds]
14:48 < aiju> even the while((c = getchar()) >= 0) is better rewritten as
14:49 < aiju> while(c = getchar(), c >= 0)
14:49 < waqas> nsf: Is a = b = c = true; bad?  :)
14:49 < aiju> i find it *much* clearer
14:49 < nsf> waqas: not necessary
14:49 < nsf> aiju: comma expression, yuck
14:49 < nsf> :)
14:50 < aiju> comma expressions are another thing i miss in Go
14:50 < nsf> for (c = getchar(); c >= 0; c = getchar())?
14:50 < aiju> they eliminate all the special cases Go has on control
structures
14:50 < aiju> what the fuck is wrong with while(c = getchar(), c >= 0)?
14:50 < nsf> I don't know
14:51 < nsf> c = getchar() is an expression here
14:51 < nsf> :D
14:51 < nsf> assignment expressions are evil
14:51 < nsf> hahaha
14:51 < aiju> duh
14:55 < waqas> Lua goes beyond Go in this.  There is no ++ :)
14:55 < waqas> That's the other language I'm working with
14:55 < nsf> 'expression' comes from 'to express'
14:55 -!- pothos [~pothos@111-240-170-131.dynamic.hinet.net] has quit [Remote host
closed the connection]
14:55 -!- pothos_ [~pothos@111-240-170-131.dynamic.hinet.net] has joined #go-nuts
14:56 < nsf> it sounds like having more kinds of expressions improves
expressiveness
14:56 < nsf> maybe it's true, but it also increases learning curve
14:56 < waqas> Does it really?
14:57 < nsf> try to remember days when you weren't understading what a
pointer is
14:57 < waqas> I could argue concurrency increases the learning curve, and
should be done away with :)
14:57 < nsf> and then you see these:
14:57 < nsf> *p++
14:57 < nsf> *++p
14:57 < nsf> omg
14:57 < aiju> haha
14:57 < nsf> it is scary
14:57 < aiju> 15:59 < nsf> maybe it's true, but it also increases
learning curve
14:58 < aiju> yay, BASIC thinking
14:58 < aiju> go QBASIC!
14:58 < nsf> I'm not saying that it should be as simple as possible
14:58 < nsf> a compromise is a must
14:58 < aiju> *p++ is what distinguishes C from BASIC
14:59 < nsf> I think it's good to have a moderate amount of
expression/statement/declaration types in any langauge
14:59 < nsf> without overloading user's memory
14:59 < nsf> and keywords, of course
14:59 < nsf> :)
15:00 -!- jbooth1 [~jay@209.249.216.2] has joined #go-nuts
15:00 < nsf> D is a bad example of this
15:00 < nsf> in D each keyword has 5 more meanings in different contexts,
lol
15:00 < nsf> (joking, but close)
15:00 < waqas> Hmm, nested functions not allowed..  not sure what I think
about that
15:01 < aiju> which D?
15:01 < aiju> the broken or the unfinished one?  ;P
15:01 < nsf> aiju: you're repeating yourself
15:01 < aiju> yeah
15:01 < nsf> :)
15:01 < nsf> D is an interesting language design experiment anyway
15:01 < aiju> waqas: someone who uses nested functions?
15:01 < aiju> D seems like --C++ to me
15:02 < nsf> lol
15:02 < nsf> waqas: no nested functions, but full closure support
15:02 < nsf> you can use closure as a nested function
15:02 < waqas> aiju: Ah, closures work.  I was trying Lua's syntax, which
makes x=func..  and func x..  be the same.
15:03 < iTonnerre> C±±
15:03 < nsf> hahaha
15:03 < nsf> nice one
15:04 < waqas> C/0 could be a fine language..  I can just imagine the
rants..
15:04 < aiju> i truly hate "for i = 0 to 100" style loops
15:05 -!- napsy [~luka@88.200.96.18] has joined #go-nuts
15:05 < iTonnerre> You prefer for(;;); ?
15:05 < aiju> yeah, an infinite amount
15:05 < iTonnerre> for (i = endvalue; i; i--)
15:05 < aiju> it's much simpler and much more flexible
15:05 < waqas> aiju: I partially agree
15:05 < iTonnerre> Yes, and when you reached 0 you just call panic()
15:06 < nsf> I write this in C++ a lot: for (int i = 0, n = arr.size(); i
< n; ++i) { }
15:06 < aiju> any CL programmer here?
15:06 < nsf> but mostly I like loops in ruby
15:06 < nsf> arr.each do |element| ...  end
15:06 < nsf> :)
15:06 < aiju> yuck
15:06 < waqas> nsf: +1
15:06 < nsf> or something like:
15:06 < nsf> str.each_line do |line| ...  end
15:07 < aiju> nsf: what does this do?
15:07 < nsf> iterates over each line in str
15:07 < nsf> in ruby there is a thing called blocks
15:07 < nsf> you can basically create any loop you like
15:07 < nsf> and use that kind of syntax
15:08 < nsf> and I haven't seen a statically typed language yet
15:08 < nsf> with the same feature
15:08 < aiju> i don't like it; syntactic sugar causes cancer of the
semicolon
15:08 < waqas> nsf: Which is surprising, since this could be done just fine
in a statically typed language
15:08 < nsf> but it removes the need of any kind of foreach of for range
loop
15:08 < nsf> waqas: yeah
15:09 < nsf> especially in a language with closures support
15:09 < nsf> but other question is how to make it efficient
15:09 < waqas> aiju: I much prefer this for one reason: I tell the compiler
what I want, and leave the details to it.  This allows better optimizations too.
15:10 < waqas> nsf: Closures can just be inlined of course.  The ones used
in this kind of loop tend to be expandable into a normal loop.
15:10 < kamaji> waqas: you must like haskell :D
15:10 < waqas> kamaji: I do, but haven't used it much :)
15:11 < kamaji> it's super nice :)
15:11 < kamaji> but nor have I
15:11 < waqas> Indeed.  Haskell's only weak point is deployment IMO :)
15:11 < aiju> Haskell is nice until you write a program in it
15:12 < nsf> I tend to think about haskell as DSL
15:12 < aiju> Haskell divides code into two parts
15:12 < aiju> aryan and jewish code
15:12 < kamaji> aiju: it's not that bad, I did some programming competitions
with it
15:12 < kamaji> haha, that's so true :D
15:12 < waqas> Heh
15:12 < kamaji> It does make sense though :)
15:13 < aiju> it totally doesn't to me
15:13 < kamaji> IO & icky real world stuff -> transforms on data ->
output
15:14 < aiju> yeah, EVA principle
15:14 < kamaji> eva?
15:14 < aiju> eingabe, verarbeitung, ausgabe (input, procession, output)
15:14 < aiju> i wonder whether there is an english equivalent
15:14 < kamaji> input, process, output
15:14 < kamaji> probably...
15:15 < kamaji> oh, "IPO model"
15:15 < kamaji> I think it makes more sense for some things
15:16 < kamaji> it's really nice for doing mathematical problems
15:16 < nsf> it's nice for everything
15:16 < nsf> because everything is A -> xform -> B
15:17 < kamaji> I can't really envision using it for like a website backend
tbh
15:17 < kamaji> but I haven't too much experience with it
15:17 < aiju> i have no clue what i would use haskell for
15:17 < nsf> and the most important part is data definitions of A and B
15:17 < aiju> i do my math with C (or FORTRAN because it does vector
operations more nicely)
15:17 < nsf> kamaji: uhm..  why not?
15:18 < nsf> POST/GET request -> xform -> reply
15:19 < kamaji> nsf: sorry I meant more for stuff where people are
interacting with each other thru a server
15:21 -!- unofficialmvp [~dev@94-62-164-227.b.ipv4ilink.net] has joined #go-nuts
15:21 -!- unofficialmvp [~dev@94-62-164-227.b.ipv4ilink.net] has left #go-nuts []
15:21 < kamaji> seems more suited to something like Go or Erlang
15:22 < aiju> VIM's = command for LISP is awesome
15:22 -!- zimsim [~simon@87.72.77.195] has quit [Read error: Operation timed out]
15:22 < waqas> Interesting, fmt.Println([]Token) is not calling String() on
my tokens apparently :/
15:23 < nsf> kamaji: but they are interacting through a database anyway
15:23 < nsf> it doesn't matter, really
15:23 < kamaji> nsf: no not necessarily
15:23 -!- arun_ [~arun@unaffiliated/sindian] has joined #go-nuts
15:23 < nsf> it is necessary
15:23 < aiju> no state, no fun
15:23 < nsf> database could be in ram
15:23 < nsf> whatever
15:23 < xyproto> waqas: is it because you have implemented String() for
Token and not for []Token?
15:24 -!- skelterjohn [~jasmuth@c-68-46-33-145.hsd1.nj.comcast.net] has quit
[Quit: skelterjohn]
15:24 < nsf> but everything in programming is about transforming data A to
data B
15:24 < kamaji> you could just be message passing and stuff?  I'm not saying
i'm right, I just don't see that it's the best language for that sort of thing
15:24 < waqas> xyproto: That's right.  Token has String.  I didn't know I
could implement it for []Token.  Can I?
15:24 < kamaji> certainly it's possible
15:24 -!- sysiphus [~opera@unaffiliated/sysiphus] has joined #go-nuts
15:24 < xyproto> waqas: yes, I think so
15:24 < nsf> and calling it a model is a heresy
15:25 < kamaji> calling what a model?
15:25 < nsf> IPO
15:25 < aiju> because it's just what it is
15:25 < nsf> everything is IPO
15:25 < xyproto> waqas: then the .String() function for []Token could go
through all the Tokens and gather the strings from their .String()-methods, for
example
15:25 < nsf> it's a way of looking at things
15:25 < nsf> a right way of course
15:25 < xyproto> waqas: I would have to try it myself to be 100% sure,
though
15:25 < waqas> xyproto: The default behavior is still interesting though.
It seems to be recursively printing all data in the passed object.
15:25 < nsf> especially in concurrency
15:26 < kamaji> yeah I guess that's true actually
15:26 < xyproto> waqas: I'll try it myself
15:26 < kamaji> I basically have no experience with concurrent stuff and
very little with monads
15:27 < kamaji> I mainly use it for just the lovely transformy part
15:27 < nsf> ugh, I should be coding my type system, time passes by
15:27 * nsf is back to coding
15:27 < kamaji> :)
15:30 < waqas> nsf: Does your lang have a public webpage/repo?
15:31 < nsf> waqas: I'm keeping a slightly out-dated version at my home PC,
here: http://jiss.convex.ru/git/crawl.git
15:31 < nsf> but there are nothing interesting
15:31 -!- rlab [~Miranda@91.200.158.34] has joined #go-nuts
15:31 < nsf> (it's gitweb page, git repo is available as well)
15:31 < nsf> there is*
15:32 < nsf> no spec, no comments, no anything
15:32 < nsf> partially completed parser that outputs an AST in yaml :)
15:33 < nsf> so..  it's not even public really
15:33 < nsf> :D
15:33 < nsf> but if you're really interested, clone the repo
15:34 < aiju> *** CAR: 135040 is not a list
15:34 < waqas> I was curious about the syntax decisions you made
15:34 < aiju> aaahh CLISP verbosity
15:34 < nsf> waqas: mostly it's Go, with few minor differences
15:34 < nsf> currently there is only two differences
15:34 < nsf> var x float; var y int = <float>x;
15:34 < aiju> (1) it's not called Go
15:34 < aiju> (2) it's not by Google
15:34 < nsf> for type casting
15:34 < nsf> and var x = <[]int>{1, 2, 3, 4}
15:35 < nsf> for compound literals
15:35 < nsf> and I have no slices, maps, strings
15:35 < nsf> this definition is like C's
15:35 < nsf> int x[] = {1, 2, 3, 4};
15:35 < aiju> C with Go syntax
15:35 < nsf> yeah
15:35 < nsf> something like that
15:35 < nsf> in fact it's a first major milestone
15:35 < nsf> provide all the C stuff using Go's syntax
15:36 < aiju> even auto?  :D
15:36 < nsf> no
15:36 < aiju> aww
15:36 < nsf> I mean in general :)
15:36 < aiju> ))))))))
15:36 < aiju> i like how parentheses stack up at the end of LISP functions
15:36 < waqas> My current language experiment is similar to Go and Ruby as
it happens.  Ruby mainly for the block syntax.
15:36 < xyproto> waqas: no, you're right, I get "invalid receiver type
[]Token" if I try to make a .String() function for it.
15:37 < nsf> semantics contain much more differences
15:37 < nsf> than syntax
15:37 < nsf> *void is back, pointer arithmetic is back
15:37 < nsf> etc.
15:37 < aiju> var blackHole *void
15:38 < xyproto> waqas: just implementing a .String() function that covers
each Token seems to make the printout of a []Token pretty sensible, though.  Also,
it
15:38 < nsf> things are zero initialized, but there will be a D's form: int
x = void;
15:38 < nsf> which avoids zero init
15:38 -!- zimsim [~simon@87.72.77.195] has joined #go-nuts
15:38 < nsf> in case if you really need that
15:38 < xyproto> wawas: it's possible to make your own .PrettyPrint function
for []Token objects, of course
15:38 < nsf> but it's all in my head right now :)
15:38 < nsf> nothing is solid
15:39 < waqas> xyproto: Implementing .String() on Token doesn't change the
printout of []Token for me.  Of course, I can do it with a manual loop.
15:39 < xyproto> waqas: did you use this signature?  (where "my" can be
anything): func (my Token) String() string {
15:39 < waqas> xyproto: func (t *Token) String() string { return "Hello" }
15:40 < xyproto> waqas: ah, drop the "*" and it works
15:40 < waqas> Oh
15:40 < waqas> It does
15:40 < xyproto> yey, I helped solve my first problem on #go-nuts, usually I
only bring problems here.  ;)
15:41 < waqas> Thanks :)
15:41 < nsf> waqas: interesting, is your language dynamic?  I'm cursious
about block implementations in static langauges
15:41 < nsf> curious*
15:42 < waqas> nsf: It's eventually both.  The difference is kind of
artificial.  I'm starting on the static side however.
15:42 < nsf> hm..
15:50 -!- eaburns [~eaburns@c-24-62-248-129.hsd1.nh.comcast.net] has joined
#go-nuts
15:50 < waqas> nsf: Your ragel scanner by the way, wouldn't it take 'if' out
of 'ifabc', when it shouldn't?
15:50 < nsf> no, ifabc is an identifier
15:51 < nsf> it extracts the longest match
15:51 < waqas> Ah, I had assumed it would extract the first match
15:51 < nsf> it's a special scanner state machine
15:51 < nsf> it seeks for a longest
15:52 < nsf> and if error happens fallbacks to previously longest
15:52 < nsf> thanks to ragel it knows how to do a scanner :)
15:52 < waqas> I quite like Ragel
15:52 * nsf too
15:53 < waqas> Which makes me wonder again if something like Ragel is
integrated in any language at the language level.  That would be an interesting
experiment.
15:53 < waqas> I think Perl 6 has grammars, but never looked at them much.
15:53 < nsf> an interesting idea, but I like DSLs
15:53 < nsf> and mixing everything together isn't the best choice
15:54 < waqas> Ragel syntax wouldn't be hard to turn into a DSL
15:55 < nsf> well, it is a DSL
15:55 < nsf> for state machines :)
15:55 < waqas> Everything is :)
15:55 < nsf> I guess
15:55 < nsf> everything that describes something in text and has special
semantics is a language
15:56 < waqas> With 'text' being rather broad in this case, and not limited
to bytes or characters
15:57 < nsf> uhm, whatever :) too abstract to me now
15:58 < waqas> True enough :)
15:58 < aiju> FORTHer and LISPers call writing functions "defining a DSL"
16:00 < nickbp> digital subscriber line
16:01 < nickbp> (acronym namespace collision)
16:01 < nickbp> (ANC)
16:04 < nsf> DSL stands for domain specific language
16:04 < aiju> haha
16:04 < aiju> constant namespace collisions are worse
16:05 < aiju> physicists sometimes use e for two different things in one
equation
16:05 -!- femtoo [~femto@95-89-249-242-dynip.superkabel.de] has joined #go-nuts
16:06 * nsf is looking at iant's code
16:06 < nsf> C++...
16:06 < nsf> http://pastie.org/1700197
16:06 < nsf> tons of stuff that does nothing
16:06 < aiju> haha
16:07 < nsf> and it can be avoided in C++ via fallback to C style
16:08 < aiju> but C is obsolete
16:08 < aiju> C++ is future
16:08 < aiju> therefore you must use C++
16:08 < aiju> or it will kill your family
16:08 < nsf> hopefully my code won't look like that
16:08 < iTonnerre> What the …
16:08 < nsf> although it is a bit
16:09 < iTonnerre> Java is dead, use JavaScript?  Or what?
16:09 < nsf> iTonnerre: it was a joke
16:09 < nsf> aiju likes to make jokes
16:09 < nsf> :)
16:09 < nsf> but every joke has some truth in it
16:09 < nsf> and a bit of philosophy
16:10 -!- rtharper [~tomh@unaffiliated/sioraiocht] has joined #go-nuts
16:10 -!- rtharper [~tomh@unaffiliated/sioraiocht] has quit [Remote host closed
the connection]
16:11 < nsf> most non-programmers think that C++ is an advanced version of C
with a bunch of improvements
16:11 < nsf> and some programmers too, lol
16:11 < nsf> argh..  I need to close the irc
16:11 -!- eaburns [~eaburns@c-24-62-248-129.hsd1.nh.comcast.net] has left #go-nuts
[]
16:15 -!- nsf [~nsf@jiss.convex.ru] has quit [Quit: WeeChat 0.3.4]
16:15 -!- rtharper [~tomh@unaffiliated/sioraiocht] has joined #go-nuts
16:16 -!- waqas [~waqas@jaim.at] has left #go-nuts []
16:17 -!- piranha [~piranha@5ED42E59.cm-7-5a.dynamic.ziggo.nl] has quit [Quit:
Computer has gone to sleep.]
16:19 < iTonnerre> C++ is C with classes?
16:19 < iTonnerre> How 1980
16:20 -!- bortzmeyer [~bortzmeye@batilda.nic.fr] has quit [Quit: Leaving.]
16:23 < steven> no.
16:23 < steven> C++ is C in bizarro-world
16:24 < steven> Go is C in 2011
16:27 -!- iant [~iant@nat/google/x-njfpjoxqrzfacjkg] has joined #go-nuts
16:27 -!- mode/#go-nuts [+v iant] by ChanServ
16:30 -!- sysiphus [~opera@unaffiliated/sysiphus] has quit [Quit: sysiphus]
16:30 -!- rlab_ [~Miranda@91.200.158.34] has joined #go-nuts
16:30 -!- rlab [~Miranda@91.200.158.34] has quit [Ping timeout: 252 seconds]
16:36 -!- shakesoda [~colby@c-24-19-215-56.hsd1.wa.comcast.net] has joined
#go-nuts
16:39 -!- waqas [~waqas@jaim.at] has joined #go-nuts
16:40 < str1ngs> https://gist.github.com/881535 I think my glibcPostBuild
function is awesome
16:40 < str1ngs> what do you guys think?
16:43 -!- skelterjohn [~jasmuth@lawn-gw.rutgers.edu] has joined #go-nuts
16:44 -!- ShadowIce [~pyoro@unaffiliated/shadowice-x841044] has joined #go-nuts
16:44 -!- shakesoda [~colby@c-24-19-215-56.hsd1.wa.comcast.net] has quit [Ping
timeout: 260 seconds]
16:46 -!- niemeyer_lunch
[~niemeyer@201-66-179-18.pltce701.dsl.brasiltelecom.net.br] has quit [Ping
timeout: 252 seconds]
16:46 < waqas> Oh yay, Go has goto.  I thought it did not.
16:46 < skelterjohn> it does - but it's not used very much as far as i know
16:47 < skelterjohn> break and continue with labels is used more frequently
16:47 < waqas> Useful for code generation
16:47 < skelterjohn> and that is *very* useful
16:47 < xyproto> str1ngs: what does it do?  :)
16:47 < aiju> goto is useful all over the place
16:48 < skelterjohn> "useful" is not the same as "used"
16:48 < str1ngs> xyproto: its a ugly hack I need to rewrite it in go.
basically it adjusts the dynamic linker to link to this glibc instead of the
system glibc
16:48 < aiju> i consider a language without goto castrated
16:48 < xyproto> str1ngs: aha
16:48 < aiju> skelterjohn: i use it all over the place
16:48 < skelterjohn> hence the "as far as i know"
16:48 < skelterjohn> i've never seen your code
16:48 < aiju> although many cases can be replaced with break/continue with
labels
16:48 < str1ngs> xyproto: the build system ideally wasnt meant to do this
but I figured it would be fun to see if I could do it
16:49 < aiju> but i don't like it, i consider it less readable than goto
16:49 < skelterjohn> if it's used for escaping loops, then yes, use
break/continue
16:49 < aiju> also, error handling
16:51 * waqas wonders what jumping over x:=make(something) with goto would result
in x being
16:51 < aiju> waqas: that's illegal according to the spec
16:51 -!- shakesoda [~colby@c-24-19-215-56.hsd1.wa.comcast.net] has joined
#go-nuts
16:51 < zozoR> what happens if you jump into another function and it reach a
return?
16:51 < zozoR> reaches*
16:51 < aiju> you can't do inter-function gotos
16:51 < zozoR> awesome :D
16:51 < zozoR> so its like goto, with epicness installed
16:52 < waqas> "Implementation does not honor the restriction on goto
statements and targets (no intervening declarations)." -
http://golang.org/doc/go_spec.html - which if of course just the current
implementation
16:52 < aiju> zozoR: you CAN'T
16:52 < skelterjohn> how do you use gotos for error handling?  not trying to
be contrary, it's just something i'm not familiar with
16:52 < aiju> waqas: oh well, it's probably undefined
16:52 -!- werdan7 [~w7@freenode/staff/wikimedia.werdan7] has joined #go-nuts
16:52 < aiju> skelterjohn: if fucked up { goto err }
16:52 < zozoR> aiju, that is whats making it awesome
16:52 < aiju> when there are many places where it could fuck up
16:52 < aiju> and the handling is always the same
16:52 < skelterjohn> no return err / defer errorHandling()?
16:53 < skelterjohn> that's how i've been doing it
16:53 < aiju> skelterjohn: not always possible / a good idea
16:53 < aiju> say, you have to set a global error flags or something like
that
16:53 < skelterjohn> eek
16:53 < skelterjohn> don't do that
16:54 < aiju> you sometimes have to
16:54 < aiju> pastie.org/1700365 example of me using goto
16:55 -!- waqas [~waqas@jaim.at] has left #go-nuts []
16:55 < aiju> any other solution would drastically reduce performance and/or
be terribly ugly
16:55 < zozoR> it is terrible that people are taught that goto are devils
16:56 < aiju> writing structured code (entirely without goto, i.e.  not
goto/break/continue) is *REALLY TERRIBLE*
16:56 < aiju> you have to introduce over 9000 auxiliary variables and checks
all over the place
16:56 < zozoR> true that
16:57 -!- shakesoda [~colby@c-24-19-215-56.hsd1.wa.comcast.net] has quit [Quit:
shakesoda]
16:57 -!- shakesoda [~colby@c-24-19-215-56.hsd1.wa.comcast.net] has joined
#go-nuts
16:58 < skelterjohn> "goto considered harmful" considered harmful
16:58 -!- unofficialmvp [~dev@94-62-164-227.b.ipv4ilink.net] has joined #go-nuts
16:58 -!- unofficialmvp [~dev@94-62-164-227.b.ipv4ilink.net] has left #go-nuts []
17:02 < steven> why so skelterjohn?
17:03 -!- rtharper [~tomh@unaffiliated/sioraiocht] has quit [Remote host closed
the connection]
17:03 -!- shakesoda [~colby@c-24-19-215-56.hsd1.wa.comcast.net] has quit [Ping
timeout: 252 seconds]
17:04 -!- niemeyer [~niemeyer@189.27.151.82.dynamic.adsl.gvt.net.br] has joined
#go-nuts
17:08 -!- zimsim [~simon@87.72.77.195] has quit [Ping timeout: 255 seconds]
17:10 -!- shakesoda [~colby@c-24-19-215-56.hsd1.wa.comcast.net] has joined
#go-nuts
17:11 -!- slashus2 [~slashus2@74-141-110-130.dhcp.insightbb.com] has joined
#go-nuts
17:15 < skelterjohn> interpreting aiju's opinion
17:16 -!- shakesoda [~colby@c-24-19-215-56.hsd1.wa.comcast.net] has quit [Ping
timeout: 240 seconds]
17:16 * exch <3 goto
17:16 < zozoR> i dont see why goto's are dangerous when it creates cleaner
code :s
17:17 < str1ngs> those anto goto's can goto hell?
17:17 < str1ngs> anti*
17:17 < aiju> exactly ;P
17:17 < skelterjohn> dijkstra wrote a very famous article called "goto
considered harmful"
17:17 < zozoR> reminds me of a danish rap song "With a goto here and ..
WAIT!  STOP!  he didnt just say the G word did he?"
17:17 < zozoR> :D
17:17 < skelterjohn> since he was so influential in early algorithmic
theory, it caught on
17:17 < aiju> which is complete bullcrap
17:17 < aiju> actually dijkstra usually makes lots of sense
17:17 < skelterjohn> read his article, then form your opinion on what he
said
17:18 < skelterjohn> (instead of the other way around)
17:18 < aiju> haha
17:18 < aiju> i haven't been able to find it yet
17:18 < zozoR> skelterjohn, which article?
17:18 < aiju> i have read a summary
17:18 < skelterjohn> http://en.wikipedia.org/wiki/Considered_harmful
17:18 -!- skejoe_ [~skejoe@188.114.142.162] has quit [Quit: leaving]
17:19 < skelterjohn> for what it's worth, knuth disagreed with him
17:19 < aiju> oh now i found it ;P
17:19 < str1ngs> anyways you can not have a language called go and not have
goto's that's just crazy
17:19 < skelterjohn> and i'd put knuth as a more authorative figure for
programmig (as opposed to algorithmic theory)
17:20 < skelterjohn> reference #2 in the wiki link is the paper
17:20 < aiju> dijkstra just says "goto is not needed therefore evil"
17:20 < skelterjohn> hah and #5
17:20 < skelterjohn> is "goto considered harmful" considered harmful
17:21 < aiju> i suppose the article was written behind a different
background
17:21 < aiju> times when people used FORTRAN and EVERYTHING was written with
GOTO
17:21 < aiju> 10 WRITE (*,*) I
17:21 < aiju> I = I + 1
17:22 < exch> functions and methods and variables and loop constructs are
also not necessary when you use straight up cpu instructions.  but that doesnt
make them evil
17:22 < aiju> IF I < 10 THEN GOTO 10
17:22 < aiju> something along that
17:22 -!- niemeyer [~niemeyer@189.27.151.82.dynamic.adsl.gvt.net.br] has quit
[Ping timeout: 255 seconds]
17:23 -!- shakesoda [~colby@c-24-19-215-56.hsd1.wa.comcast.net] has joined
#go-nuts
17:23 -!- |Craig| [~|Craig|@panda3d/entropy] has joined #go-nuts
17:24 -!- zimsim [~simon@87.72.77.195] has joined #go-nuts
17:24 -!- emjayess [~emjayess@pix1.i29.net] has quit [Quit: Leaving]
17:27 -!- czr_ [czr@nexus.iohazard.net] has quit [Remote host closed the
connection]
17:29 -!- shakesoda [~colby@c-24-19-215-56.hsd1.wa.comcast.net] has quit [Ping
timeout: 252 seconds]
17:31 -!- nsf [~nsf@jiss.convex.ru] has joined #go-nuts
17:31 -!- niemeyer [~niemeyer@189.27.151.82.dynamic.adsl.gvt.net.br] has joined
#go-nuts
17:35 -!- shakesoda [~colby@c-24-19-215-56.hsd1.wa.comcast.net] has joined
#go-nuts
17:37 -!- slashus2 [~slashus2@74-141-110-130.dhcp.insightbb.com] has quit [Quit:
slashus2]
17:41 -!- pharris [~Adium@rhgw.opentext.com] has quit [Quit: Leaving.]
17:45 < plexdev> http://is.gd/M2z8pn by [Robert Hencke] in
go/test/fixedbugs/ -- test: enable tests using v, ok := <-ch syntax
17:48 -!- pharris [~Adium@rhgw.opentext.com] has joined #go-nuts
17:48 -!- rtharper [~tomh@unaffiliated/sioraiocht] has joined #go-nuts
17:50 -!- rlab_ [~Miranda@91.200.158.34] has quit [Ping timeout: 264 seconds]
17:57 -!- shakesoda [~colby@c-24-19-215-56.hsd1.wa.comcast.net] has quit [Ping
timeout: 240 seconds]
18:01 -!- artefon [~thiago@dhcp10.usuarios.dcc.ufmg.br] has quit [Quit: bye]
18:02 < steven> phew!
18:02 < steven> finally was able to reproduce a bug at work that only
happened when you clicked the same link on two different mongrels within 0.7 to
0.9 seconds of each other
18:03 < steven> took 4 months to figure that one out :)
18:04 -!- shakesoda [~colby@c-24-19-215-56.hsd1.wa.comcast.net] has joined
#go-nuts
18:05 < skelterjohn> what's a mongrel
18:08 -!- bortzmeyer [~stephane@2a01:e35:8bd9:8bb0:9ed:bd17:3073:a110] has joined
#go-nuts
18:09 -!- TheMue [~TheMue@p5DDF7B7C.dip.t-dialin.net] has joined #go-nuts
18:10 < dforsyth> isnt it that zed shaw thing?
18:10 -!- wrtp [~rog@92.17.43.168] has quit [Quit: wrtp]
18:11 -!- shakesoda [~colby@c-24-19-215-56.hsd1.wa.comcast.net] has quit [Ping
timeout: 276 seconds]
18:17 < plexdev> http://is.gd/XrdJy4 by [Robert Griesemer] in 3 subdirs of
go/ -- go/printer, gofmt: simplify struct formatting and respect line breaks
18:21 < zozoR> aiju, do you use goto's to travel up in the code?
18:21 -!- waqas [~waqas@jaim.at] has joined #go-nuts
18:22 < aiju> zozoR: yeah, occasionally
18:22 < aiju> goto retry
18:22 < aiju> to restart a function
18:22 < waqas> aiju: Link to a code example?
18:23 < waqas> Your code I meant
18:23 < zozoR> ok ^^
18:26 < waqas> Assuming this is the right conversation, the only thing I
have against goto is how it can make automatic code transformations so complex.
18:29 -!- m4dh4tt3r [~Adium@33.sub-75-208-177.myvzw.com] has joined #go-nuts
18:33 -!- cenuij [~cenuij@78.112.175.207] has joined #go-nuts
18:33 -!- cenuij [~cenuij@78.112.175.207] has quit [Changing host]
18:33 -!- cenuij [~cenuij@base/student/cenuij] has joined #go-nuts
18:38 -!- tvw [~tv@212.79.9.150] has quit [Remote host closed the connection]
18:42 -!- ronnyy [~quassel@p4FF1C45C.dip0.t-ipconnect.de] has joined #go-nuts
18:45 -!- artefon [~thiago@189.59.182.216.dynamic.adsl.gvt.net.br] has joined
#go-nuts
18:46 -!- Fish- [~Fish@9fans.fr] has joined #go-nuts
18:46 -!- rlab [~Miranda@91.200.158.34] has joined #go-nuts
18:47 -!- tensai_cirno [~cirno@77.232.15.216] has quit [Quit: Leaving]
18:49 < plexdev> http://is.gd/CmdciY by [Rob Pike] in go/src/pkg/gob/ --
gob: use pointers in bootstrapType so interfaces behave properly
18:50 -!- Natch [~natch@c-6dcde155.25-4-64736c10.cust.bredbandsbolaget.se] has
joined #go-nuts
18:52 -!- codelurker [~codelurke@2002:62e3:bbdb:0:e60:76ff:fe66:2bd3] has joined
#go-nuts
18:52 -!- codelurker [~codelurke@2002:62e3:bbdb:0:e60:76ff:fe66:2bd3] has quit
[Read error: Connection reset by peer]
18:53 -!- Natch| [~natch@c-6dcde155.25-4-64736c10.cust.bredbandsbolaget.se] has
quit [Read error: Operation timed out]
18:56 -!- virtualsue [~chatzilla@nat/cisco/x-najehrhsolgcsaan] has joined #go-nuts
18:58 -!- nsf [~nsf@jiss.convex.ru] has quit [Quit: WeeChat 0.3.4]
18:59 -!- czr_ [czr@nexus.iohazard.net] has joined #go-nuts
19:00 -!- huin [~huin@91.84.76.70] has joined #go-nuts
19:06 < plexdev> http://is.gd/z7eZDK by [Rob Pike] in go/src/pkg/gob/ --
gob: fix up ugly formatting introduced by buggy (now fixed) gofmt.
19:18 -!- m4dh4tt3r [~Adium@33.sub-75-208-177.myvzw.com] has quit [Ping timeout:
252 seconds]
19:19 -!- stepso [~stepso@88-134-14-178-dynip.superkabel.de] has joined #go-nuts
19:20 -!- stepso [~stepso@88-134-14-178-dynip.superkabel.de] has quit [Client
Quit]
19:20 -!- stepso [~stepso@88-134-14-178-dynip.superkabel.de] has joined #go-nuts
19:21 -!- niemeyer [~niemeyer@189.27.151.82.dynamic.adsl.gvt.net.br] has quit
[Ping timeout: 255 seconds]
19:21 -!- stepso [~stepso@88-134-14-178-dynip.superkabel.de] has quit [Remote host
closed the connection]
19:26 -!- zimsim [~simon@87.72.77.195] has quit [Read error: Operation timed out]
19:30 -!- tvw [~tv@e176014066.adsl.alicedsl.de] has joined #go-nuts
19:31 -!- eaburns [~eaburns@c-24-62-248-129.hsd1.nh.comcast.net] has joined
#go-nuts
19:33 -!- madcapfizzle [~username@nat/google/x-skjmxgklgjetraev] has joined
#go-nuts
19:34 -!- niemeyer [~niemeyer@189.27.151.82.dynamic.adsl.gvt.net.br] has joined
#go-nuts
19:44 -!- zimsim [~simon@87.72.77.195] has joined #go-nuts
19:47 -!- plainhao [~plainhao@208.75.85.237] has quit [Quit: plainhao]
19:50 -!- rlab_ [~Miranda@91.200.158.34] has joined #go-nuts
19:52 -!- rlab [~Miranda@91.200.158.34] has quit [Ping timeout: 276 seconds]
19:56 < steven> am i understanding properly, that goroutines are only
helpful when dealing with blocking-IO calls?
19:57 < steven> like network reads/writes or waiting on a PID or something
19:57 < waqas> Or whenever you need concurrecy
19:59 -!- keithcascio [~keithcasc@nat/google/x-jugdexvwzyyiipcv] has joined
#go-nuts
19:59 < steven> no,
19:59 < steven> goroutines do not yield to other goroutines unless they are
stuck in a blocking system call
19:59 < steven> ive tried writing a concurrent quicksort implementation, and
it doesnt yield at all.
20:00 < |Craig|> not true
20:00 < steven> rather,
20:00 < steven> it doesnt execute simultaneously.
20:00 < |Craig|> I wrote a parallel image processor, rand twice as fast with
to goroutines on my duel core
20:00 < steven>
https://github.com/sdegutis/go-quicksort/blob/master/quicksort-concurrent.go
20:00 < steven> this doesnt run any faster than this:
20:00 < steven>
https://github.com/sdegutis/go-quicksort/blob/master/quicksort.go
20:00 < |Craig|> steven: perhaps you have go configured to only use one os
thread?
20:01 < steven> even for tens of thousands of elements to be sorted.
20:01 < steven> nope.
20:01 < |Craig|> that is the default
20:01 < steven> i had GOMAXPROCS=4
20:01 < steven> https://github.com/sdegutis/go-quicksort/blob/master/main.go
20:01 < xulfer> How did you determine there is no yield?  Since underlying
synchronization often causes a slow down rather than a speed up in algorithms of
that nature.
20:02 < xulfer> So a lack of performance boost wouldn't be an accurate way
to tell.
20:02 < steven> how else can you tell?
20:02 < steven> is there another way to determine it?
20:02 < |Craig|> steven: if one way does not work, its not "how else can you
tell" its "how can you tell"
20:02 < steven> thats what im asking
20:03 < steven> how can you tell?
20:04 < |Craig|> if you run 2 goroutines with shared memory you can observe
that the other is getting time
20:04 < waqas> steven: I'd expect your goroutine based code to be much
slower.  All that goroutine creation and channel sending isn't free of cost.
20:04 < |Craig|> ideally though, you should not know, or care how/when the
yielding.  Use explicit sync like channels
20:04 < steven> it should be cheap though
20:04 < |Craig|> its not very cheap
20:05 < steven> then why is it useful?
20:05 < |Craig|> it is cheap, but not very cheap
20:05 < |Craig|> especially if the go routines are in different os threads.
Its quite cheap if they are in the same one, which is why you default to only one
20:06 < |Craig|> run the sample prime generator example with multiple
threads, not that it slows down a lot
20:06 < waqas> steven: It's cheap.  But how cheap?  It's probably a memory
allocation at the very minimum.  For a 1000 element slice you are probably
creating 500 goroutines.
20:06 < steven> oh.
20:06 < steven> also i noticed it was never using more than one processor on
my computer, even when GOMAXPROCS=4
20:06 < steven> it was always only using the same processor.
20:07 < waqas> steven: Instead of creating 500 goroutines, just try with
two.  Call the non-goroutine function in two separate goroutines, sorting the
first half in one, the second half in the other.  Then you should see an
improvement.
20:07 < plexdev> http://is.gd/4T2aSs by [Ian Lance Taylor] in 3 subdirs of
go/ -- Make.pkg: add support for SWIG, and add two SWIG examples
20:07 < xulfer> It is useful, but concurrency comes with a 'relatively high'
overhead.  Synchronization comes at an even higher cost when that gets involved.
20:07 < |Craig|> you want a number of active go routines close to GOMAXPROCS
if GOMAXPROCS>1 from my experience
20:08 < |Craig|> just spamming a hundred go routines across a bunch of os
threads, and having them sync back and forth all over is slow
20:09 < xulfer> and ymmv on cores.  Threads and what not are generally never
guaranteed to run on separate cores.
20:09 -!- jgonzalez [~jgonzalez@173-14-137-134-NewEngland.hfc.comcastbusiness.net]
has quit [Read error: Connection reset by peer]
20:09 -!- jgonzalez [~jgonzalez@173-14-137-134-NewEngland.hfc.comcastbusiness.net]
has joined #go-nuts
20:10 -!- madcapfizzle [~username@nat/google/x-skjmxgklgjetraev] has quit [Quit:
Farewell]
20:10 -!- werdan7 [~w7@freenode/staff/wikimedia.werdan7] has quit [Excess Flood]
20:11 < skelterjohn> how can i run a godoc server that uses an extra place
to examine source?  adding -path=.  doesn't seem to do it...
20:13 -!- Project_2501 [~Marvin@82.84.84.232] has joined #go-nuts
20:14 -!- rlab [~Miranda@91.200.158.34] has joined #go-nuts
20:15 -!- awidegreen [~quassel@c-eacae555.08-2-73746f39.cust.bredbandsbolaget.se]
has joined #go-nuts
20:15 -!- rlab_ [~Miranda@91.200.158.34] has quit [Ping timeout: 246 seconds]
20:16 -!- madcapfizzle [~username@nat/google/x-jkmejsnhsliaoedc] has joined
#go-nuts
20:18 -!- werdan7 [~w7@freenode/staff/wikimedia.werdan7] has joined #go-nuts
20:21 < steven> i want to add to bufio: func (b *Reader) ReadLen(int length)
(line string, err os.Error)
20:21 < steven> it would just read up to a given number of bytes.  wuold be
very useful.
20:22 < steven> but the code-submission-process is intimidating.
20:23 < pharris> steven: Typically, you slice your buffer to the maximum
length you want read.
20:23 -!- wrtp [~rog@92.17.43.168] has joined #go-nuts
20:24 < steven> well the idea is, for implementing certain protocols,
sometimes you want to change up what you're reading.
20:24 < skelterjohn> right - any io.Reader has a Read([]byte) method - you
give it a []byte backed by an array of size "length"
20:24 < skelterjohn> it will read no more than "length" bytes
20:24 < steven> sometimes i want to read just 1 byte, sometimes 3, sometimes
up until "\r\n", and it can change all within the same connection
20:25 < steven> oh
20:25 < steven> but, it might not read len(b)
20:25 < steven> it might read < len(b)
20:25 < skelterjohn> yes
20:25 < steven> which is why im talking about adding it to bufio
20:25 < skelterjohn> if there aren't len(b) bytes to read
20:25 < skelterjohn> it will read all that it can
20:25 -!- eaburns [~eaburns@c-24-62-248-129.hsd1.nh.comcast.net] has left #go-nuts
[]
20:25 < steven> well sometimes a single message can be split between two
sends, on the other end of the connection.
20:26 < steven> over tcp at least
20:26 < pharris> Maybe you want http://golang.org/pkg/io/#ReadFull
20:26 < skelterjohn> you can use LimitReader
20:26 < steven> so it might read less than len(b) but in the next call it
would read the remainder
20:26 < skelterjohn> and ReadFull from it
20:26 < steven> yeah ReadFull looks like it will suffice
20:27 < skelterjohn> seems better than what i was about to suggest,
certianly
20:27 < steven> actually,
20:28 < steven> ReadFull uses ReadAtLeast
20:28 < steven> which means it could end up reading more than len(buf)
20:28 < skelterjohn> no - ReadAtLeast is capped by the size of the buffer
20:29 < skelterjohn> ReadAtLeast takes the minimum
20:29 < skelterjohn> ReadFull sets the minimum to the size of the buffer
20:29 < skelterjohn> the maximum is always the size of the buffer
20:29 < skelterjohn> for any read
20:29 < skelterjohn> i mean, no one is just going to throw out data
20:29 -!- madcapfizzle [~username@nat/google/x-jkmejsnhsliaoedc] has quit [Quit:
Farewell]
20:31 -!- madcapfizzle [~username@nat/google/x-pzqfcxxtcpyzrzvl] has joined
#go-nuts
20:33 < steven> k
20:33 < steven> well
20:33 < steven> there go my plans of finally contributing to OSS
20:33 < steven> on a project that isnt my own.
20:39 -!- jyxent [~jyxent@129.128.191.96] has quit [Ping timeout: 240 seconds]
20:39 < plexdev> http://is.gd/pqyl23 by [Ian Lance Taylor] in go/src/ --
Make.pkg: Always define _CGO_CFLAGS and friends.
20:40 -!- jyxent [~jyxent@129.128.191.99] has joined #go-nuts
20:48 -!- m4dh4tt3r
[~Adium@75.144.24.109-BusName-walnutcreek.ca.hfc.comcastbusiness.net] has joined
#go-nuts
20:48 -!- waqas [~waqas@jaim.at] has left #go-nuts []
20:48 -!- madcapfizzle [~username@nat/google/x-pzqfcxxtcpyzrzvl] has quit [Ping
timeout: 250 seconds]
20:55 -!- iant [~iant@nat/google/x-njfpjoxqrzfacjkg] has quit [Quit: Leaving.]
20:55 -!- femtoo [~femto@95-89-249-242-dynip.superkabel.de] has quit [Read error:
Connection reset by peer]
20:59 -!- wrtp [~rog@92.17.43.168] has quit [Quit: wrtp]
21:02 -!- jyxent [~jyxent@129.128.191.99] has quit [Remote host closed the
connection]
21:02 -!- jyxent [~jyxent@129.128.191.96] has joined #go-nuts
21:04 -!- iant [~iant@nat/google/x-tbypwgbyqcngmnif] has joined #go-nuts
21:04 -!- mode/#go-nuts [+v iant] by ChanServ
21:09 < zozoR> is there a place i can read about compiler feedback
21:09 < zozoR> i get a
21:09 < zozoR> non-name var on left side of :=
21:09 < zozoR> i have no idea what that means
21:09 -!- TMKCodes [~TMKCodes@unaffiliated/tmkcodes] has joined #go-nuts
21:11 <+iant> zozoR: what does the line look like?
21:12 < zozoR> web.File, err := os.Open(path, os.O_RDONLY, 0666)
21:12 < zozoR> non-name web.File on left side of :=
21:12 <+iant> web.File is not a variable; you need to use =, not :=
21:12 <+iant> := declares a variable
21:12 < zozoR> err is not declared
21:12 <+iant> you can't combine a non-variable like web.File with a
declaration like err
21:13 <+iant> var err os.Error
21:13 <+iant> web.File, err = os.Open()
21:13 < zozoR> im confused now
21:13 < zozoR> why is web.File not a variable
21:13 <+iant> OK, maybe it is a variable, but it's not a variable you can
declare
21:13 <+iant> if it is a variable, it's in some other package
21:14 < zozoR> oh ok
21:14 <+iant> you could do: x, err := os.Open() and then web.File = x
21:14 < zozoR> :)
21:14 < zozoR> i got it working, thanks
21:14 <+iant> sure
21:14 <+iant> using := there is no crazy, but Go doesn't currently permit it
21:14 < zozoR> :p
21:17 -!- skejoe [~skejoe@188.114.142.162] has joined #go-nuts
21:17 -!- zimsim [~simon@87.72.77.195] has quit [Remote host closed the
connection]
21:26 < plexdev> http://is.gd/aNs2Sz by [Robert Griesemer] in 4 subdirs of
go/src/ -- go/printer: Revert API change of CL 4274075.
21:32 -!- GilJ [~GilJ@zeus.ugent.be] has quit [Read error: Operation timed out]
21:33 < TMKCodes> Hey i ordered http://www.goprogrammingbook.com/ is it
worth reading?
21:33 -!- bortzmeyer [~stephane@2a01:e35:8bd9:8bb0:9ed:bd17:3073:a110] has quit
[Quit: Leaving.]
21:34 < huin> it had better be, now that you ordered it :)
21:34 < TMKCodes> ;D
21:34 < TMKCodes> Well it's just 20 euros
21:36 < aiju> the cover art is not nearly as well as done on the o'reilly
books
21:36 < aiju> must be real shit
21:36 <+iant> I recall some saying about books and covers, what was it?
21:36 -!- zozoR [~Morten@56344966.rev.stofanet.dk] has quit [Remote host closed
the connection]
21:39 < skelterjohn> burn
21:40 -!- waqas [~waqas@jaim.at] has joined #go-nuts
21:41 -!- GilJ [~GilJ@zeus.ugent.be] has joined #go-nuts
21:46 -!- TheMue [~TheMue@p5DDF7B7C.dip.t-dialin.net] has quit [Quit: TheMue]
21:47 -!- rlab [~Miranda@91.200.158.34] has quit [Ping timeout: 248 seconds]
21:48 -!- Scorchin [~Scorchin@host86-145-18-208.range86-145.btcentralplus.com] has
joined #go-nuts
21:53 -!- piranha [~piranha@5ED43A0B.cm-7-5a.dynamic.ziggo.nl] has joined #go-nuts
21:54 -!- skelterjohn [~jasmuth@lawn-gw.rutgers.edu] has quit [Quit: skelterjohn]
21:54 -!- olegfink [~olegfink@ppp92-100-71-138.pppoe.avangarddsl.ru] has joined
#go-nuts
21:56 < olegfink> a quickie: seems it's not a good idea to have chans in
named result list?
21:59 -!- ExtraSpice [XtraSpice@88.118.35.153] has quit [Read error: Connection
reset by peer]
22:05 -!- huin [~huin@91.84.76.70] has quit [Quit: leaving]
22:11 -!- ShadowIce [~pyoro@unaffiliated/shadowice-x841044] has quit [Quit:
Verlassend]
22:12 -!- tensai_cirno [~cirno@77.232.15.216] has joined #go-nuts
22:12 -!- awidegreen [~quassel@c-eacae555.08-2-73746f39.cust.bredbandsbolaget.se]
has quit [Remote host closed the connection]
22:21 -!- Fish- [~Fish@9fans.fr] has quit [Quit: So Long, and Thanks for All the
Fish]
22:24 -!- Project_2501 [~Marvin@82.84.84.232] has quit [Quit: E se abbasso questa
leva che succ...]
22:26 -!- MizardX [MizardX@ip-18-40-149-91.dialup.ice.net] has joined #go-nuts
22:26 -!- MizardX [MizardX@ip-18-40-149-91.dialup.ice.net] has quit [Changing
host]
22:26 -!- MizardX [MizardX@unaffiliated/mizardx] has joined #go-nuts
22:26 -!- rtharper [~tomh@unaffiliated/sioraiocht] has quit [Remote host closed
the connection]
22:27 -!- rtharper [~tomh@unaffiliated/sioraiocht] has joined #go-nuts
22:34 -!- dfc [~dfc@sydfibre2.atlassian.com] has joined #go-nuts
22:39 -!- piranha [~piranha@5ED43A0B.cm-7-5a.dynamic.ziggo.nl] has quit [Quit:
Computer has gone to sleep.]
22:42 -!- Scorchin_ [~Scorchin@host109-157-105-12.range109-157.btcentralplus.com]
has joined #go-nuts
22:43 -!- Scorchin_ [~Scorchin@host109-157-105-12.range109-157.btcentralplus.com]
has quit [Client Quit]
22:43 < plexdev> http://is.gd/p7MFOx by [Andrew Gerrand] in
go/src/cmd/godoc/ -- godoc: add -template flag to specify custom templates
22:44 -!- Scorchin [~Scorchin@host86-145-18-208.range86-145.btcentralplus.com] has
quit [Ping timeout: 255 seconds]
22:49 -!- ronnyy [~quassel@p4FF1C45C.dip0.t-ipconnect.de] has quit [Remote host
closed the connection]
22:50 -!- madcapfizzle [~username@nat/google/x-irylmdwwjkfeqqlp] has joined
#go-nuts
22:52 -!- madcapfizzle [~username@nat/google/x-irylmdwwjkfeqqlp] has quit [Client
Quit]
23:00 -!- iant [~iant@nat/google/x-tbypwgbyqcngmnif] has quit [Quit: Leaving.]
23:00 -!- skejoe [~skejoe@188.114.142.162] has quit [Quit: Lost terminal]
23:02 -!- madcapfizzle [~username@nat/google/x-gckojurtwviwypjx] has joined
#go-nuts
23:05 -!- nsf [~nsf@jiss.convex.ru] has joined #go-nuts
23:08 -!- tvw [~tv@e176014066.adsl.alicedsl.de] has quit [Read error: Connection
reset by peer]
23:09 -!- GilJ [~GilJ@zeus.ugent.be] has quit [Ping timeout: 260 seconds]
23:10 -!- virtualsue [~chatzilla@nat/cisco/x-najehrhsolgcsaan] has quit [Ping
timeout: 252 seconds]
23:11 -!- enherit [~enherit@24-176-217-66.dhcp.lnbh.ca.charter.com] has joined
#go-nuts
23:13 -!- codelurker [~codelurke@c-98-227-187-219.hsd1.il.comcast.net] has joined
#go-nuts
23:18 -!- skelterjohn [~jasmuth@c-68-46-33-145.hsd1.nj.comcast.net] has joined
#go-nuts
23:19 -!- codelurker [~codelurke@c-98-227-187-219.hsd1.il.comcast.net] has quit
[Quit: Leaving]
23:19 -!- m4dh4tt3r
[~Adium@75.144.24.109-BusName-walnutcreek.ca.hfc.comcastbusiness.net] has quit
[Quit: Leaving.]
23:20 -!- madcapfizzle [~username@nat/google/x-gckojurtwviwypjx] has quit [Quit:
Farewell]
23:21 -!- codelurker [~codelurke@c-98-227-187-219.hsd1.il.comcast.net] has joined
#go-nuts
23:23 -!- codelurker [~codelurke@c-98-227-187-219.hsd1.il.comcast.net] has quit
[Client Quit]
23:23 -!- codelurker [~codelurke@c-98-227-187-219.hsd1.il.comcast.net] has joined
#go-nuts
23:26 -!- GilJ [~GilJ@zeus.ugent.be] has joined #go-nuts
23:29 -!- codelurker [~codelurke@c-98-227-187-219.hsd1.il.comcast.net] has quit
[Quit: Leaving]
23:29 -!- niemeyer [~niemeyer@189.27.151.82.dynamic.adsl.gvt.net.br] has quit
[Ping timeout: 255 seconds]
23:30 -!- codelurker [~codelurke@c-98-227-187-219.hsd1.il.comcast.net] has joined
#go-nuts
23:31 -!- aho [~nya@fuld-4d00d393.pool.mediaWays.net] has joined #go-nuts
23:33 -!- iant [~iant@67.218.107.6] has joined #go-nuts
23:33 -!- mode/#go-nuts [+v iant] by ChanServ
23:34 <@adg> TMKCodes: it hasn't had good reviews on amazon
23:34 <@adg> olegfink: "result list" ?
23:35 -!- pharris [~Adium@rhgw.opentext.com] has quit [Quit: Leaving.]
23:36 -!- m4dh4tt3r [~Adium@61.sub-69-99-167.myvzw.com] has joined #go-nuts
23:40 -!- nsf [~nsf@jiss.convex.ru] has quit [Quit: WeeChat 0.3.4]
23:41 -!- napsy [~luka@88.200.96.18] has quit [Ping timeout: 250 seconds]
23:41 -!- skelterjohn [~jasmuth@c-68-46-33-145.hsd1.nj.comcast.net] has quit [Ping
timeout: 248 seconds]
23:45 -!- jgonzalez [~jgonzalez@173-14-137-134-NewEngland.hfc.comcastbusiness.net]
has quit [Ping timeout: 240 seconds]
23:57 -!- tensorpudding [~user@99.148.205.193] has joined #go-nuts
--- Log closed Wed Mar 23 00:00:04 2011