apeiros_ changed the topic of #ruby-lang to: Ruby 2.0.0-p0: http://ruby-lang.org (Ruby 1.9.3-p392) || Paste >3 lines of text on http://gist.github.com
krohrbaugh1 has quit [Quit: Leaving.]
vlad_starkov has quit [Ping timeout: 256 seconds]
tomzx_mac has joined #ruby-lang
jovy88 has quit [Read error: Connection reset by peer]
headius has quit [Quit: headius]
jovy88 has joined #ruby-lang
<erikh> hello I wish to subscribe to your lack of tty knowledge^W^W^W^Wnewsletter
* erikh sprinkles snark all over the channel
roadt has joined #ruby-lang
ryez has quit [Ping timeout: 245 seconds]
<MouseTheLuckyDog> erikh, ?
<MouseTheLuckyDog> Feel free to decrease my lack.
<erikh> man 4 tty
nathanstitt has joined #ruby-lang
<MouseTheLuckyDog> erikh, I don't see how that applys to my problem?
tylersmith has joined #ruby-lang
pskosinski has quit [Remote host closed the connection]
tylersmi_ has joined #ruby-lang
tylersmith has quit [Read error: Connection reset by peer]
charliesome has joined #ruby-lang
Guest83841 has quit [Quit: Guest83841]
pskosinski has joined #ruby-lang
<r0bgleeson> what do you guys think of the proposal to remove '::' as syntax for calling methods?
<charliesome> r0bgleeson: i mostly support it
<r0bgleeson> :D
tjcravey has joined #ruby-lang
xuser has joined #ruby-lang
ryez has joined #ruby-lang
headius has joined #ruby-lang
cofin has joined #ruby-lang
richcollins has joined #ruby-lang
chessguy has quit [Remote host closed the connection]
dankest has joined #ruby-lang
retro|cz has quit [Ping timeout: 268 seconds]
headius has quit [Quit: headius]
<whitequark> r0bgleeson: should have been done a long time ago
<whitequark> that'll also remove quite a bit of complexity from parse.y... I think
GarethAdams has quit [Quit: Leaving...]
headius has joined #ruby-lang
<erikh> MouseTheLuckyDog: sorry, was being snarky. so usually passing data in via stdin means that a tty can't be used, so it screws up things like readline and so forth
totallymike has joined #ruby-lang
<erikh> you'll see this with sudo too, check out the 'requiretty' setting which is the bane of anyone using net-ssh.
jaimef has quit [Ping timeout: 260 seconds]
headius has quit [Client Quit]
<erikh> now, you can allocate a pty which should work, but I'm not entirely sure what's involved in doing that.
<erikh> but, be aware pty support is not exactly standard
idkazuma has quit [Remote host closed the connection]
<erikh> charliesome: heh, as I see in your defines
<erikh> err, includes. whatev
<erikh> :P
<charliesome> well thats for forkpty()
<erikh> ah I don't really know the API
<charliesome> you can allocate a pty in a totally standard way
<charliesome> but it's extra bullshit busy work
brianpWins has quit [Quit: brianpWins]
<charliesome> forkpty is very easy, but non-standard (i think)
<erikh> I've read it's not as easy as it sounds
<erikh> at least the vim author cited the emacs troubles on OS X for years
<drbrain> charliesome: erikh: there is require 'pty'
<whitequark> charliesome: y u no getopt :/
<erikh> in an argument to say there will never be full pty support
<erikh> drbrain: right
<charliesome> whitequark: iunno
<erikh> but yeah, ultimately, I know only what others have said that I trust
<charliesome> whitequark: patches welcome!!!
<eam> pty: character parsing in the kernel. Great idea
<erikh> eam: really?
<whitequark> eam: linux these days includes complete X.509 impl
<eam> where'd you think it was done? :)
<whitequark> now THAT is a great idea
<erikh> eam: point taken
headius has joined #ruby-lang
<whitequark> (because secure boot, that's why.)
<charliesome> whitequark: berkeley packet filter is also a brilliant idea
<erikh> whitequark: PXE?
<erikh> wait
<whitequark> erikh: nope, that microsoft drm thingy
<erikh> ah
<erikh> UEFI
<whitequark> charliesome: hmmm it has its own bytecode, right?
<drbrain> Awesome libpcap wrapper if I do say so myself: http://github.com/drbrain/capp
<whitequark> but it's limited to 2k ops per packet or smth like that
<erikh> drbrain: heh
<charliesome> whitequark: yeah but i think the linux kernel has a JIT for packet filter bytecode
<eam> it's funny to think that STDIN.readline is, when you peel it away, telling the kernel to read bytes until it sees '\n' in tty a device driver
<whitequark> drbrain: that is actually very neat... I'm too lazy to learn wireshark's scripting
<whitequark> charliesome: well jits for these kinds of stuff are very easy
<charliesome> eam: i don't think the kernel handles newlines
<eam> charliesome: it sure does
<whitequark> also it's more like aot actually
<charliesome> eam: oh?
<eam> charliesome: that's what the tty does for you
<whitequark> charliesome: google "line discipline"
<whitequark> it's even called so
<erikh> it's at the top of man 4 tty
<erikh> if you don't want to google.
<whitequark> aka "why you can use backspace together with gets()"
<charliesome> oh ok disregard me
<eam> /dev/pts/???, and you can instruct the tty device driver on what to do and what characters to worry about with ioctl()
<erikh> eam: STDIN.readline likely doesn't consult tty though, does it?
<charliesome> unix is so complex
<drbrain> whitequark: a) pcapr or whatever the current one is doesn't interpret packet structure and b) it is GPL
<eam> erikh: sure dude, it doesn't happen at userland right?
<drbrain> so I wrote my own
<erikh> I mean, in the standard echo blah | program case
<drbrain> I also didn't like that it used rb_thread_wait*
<eam> erikh: it hangs out blocking in a read() -- what ends the read?
<erikh> eof on stdin?
<erikh> oh
<eam> erikh: not in a pipe, run it controlling your tty :)
<erikh> err, yeah, isn't ... shit
<erikh> damnit
<erikh> i'm scared now
<erikh> I don't wanna look
<eam> seriously it's kinda crazy to think about
<erikh> but yeah, I was thinking of the pipe case
<eam> yeah totally
<erikh> which should be read with an index
<whitequark> ugh, IO#readline is SCARY
<erikh> and some leftover buffer
<whitequark> http://rxr.whitequark.org/mri/source/io.c#2891 and several hundred lines next
<erikh> whitequark: heh, have you looked at the dispatch for system() ?
<erikh> it might have gotten better.
<whitequark> erikh: ...
<whitequark> I think I don't want to.
<whitequark> I had a nice day.
<erikh> yeah, probably best
<erikh> but if you're bored:
<erikh> strace these two lines
wesside_ has quit [Quit: Computer has gone to sleep.]
<erikh> system(*%w[echo hi])
<erikh> system(*%w[echo 'hi'])
<erikh> it might have changed, but they're very different
<whitequark> O_O
<whitequark> why the fcntl weirdness
<erikh> the latter involves strtok
<erikh> or strscan, can remember now
jaimef has joined #ruby-lang
<r0bgleeson> drbrain: what license does rubygems use now?
<whitequark> erikh: they seem to perform about the same thing
<drbrain> r0bgleeson: ruby license (still)
<whitequark> and for some reason invoke fcntl(F_GETFD) on first 256 fds
<erikh> whitequark: maybe it's changed. the ticks used to dispatch a mini-shellwords in C
<erikh> might need to strace -f to see it
<whitequark> erikh: not sure... strtok isn't a syscall?
<r0bgleeson> drbrain: what's your preferred license?
<erikh> rihgt, but you'll see it in the exec
<whitequark> (I strace -f'd)
<drbrain> r0bgleeson: MIT
<whitequark> erikh: what?
<r0bgleeson> cool, same here
<drbrain> r0bgleeson: ruby license is now Ruby or GPL or BSD 2-clause
tjcravey has quit [Quit: ["Textual IRC Client: www.textualapp.com"]]
<whitequark> erikh: as in, it used to launch a supplementary binary?
<erikh> no
<erikh> well, yes,
<erikh> system with an array may or may not spawn a subshell
<whitequark> now it's just execve("/bin/echo", ["echo", "'hi'"], [/* 45 vars */]) = 0
<erikh> guess which one causes it to
<erikh> really? for both?
<drbrain> oh, right, I mis-negotiated the license change of rubygems to MIT instead of BSD 2-clause
<whitequark> and execve("/bin/echo", ["echo", "hi"], [/* 45 vars */]) = 0
<erikh> oh, interesting
<whitequark> seems so
<erikh> whitequark: do you have a 1.8 around?
<whitequark> erikh: yep
<erikh> mind trying it on that?
<erikh> I did a source dive after raggi and I had an argument about this ages ago
tjcravey has joined #ruby-lang
<erikh> with raggi, and we found the relevant code
vlad_starkov has joined #ruby-lang
jaymes has quit [Remote host closed the connection]
<whitequark> erikh: 1.8.7-p370 seems to do the same thing.
<erikh> f'n what
<erikh> maybe I'm not using the right trigger. it's been ... over a year since I looked at it
<erikh> oh well
<erikh> whitequark: sorry to waste your time
<whitequark> np :)
<whitequark> lazy 5am anyway
<erikh> heh
<erikh> apartment manager asked me why I'm up until 5am most nights
<erikh> she doesn't know many nerds
<r0bgleeson> where is raggi these days?
<erikh> r0bgleeson: around
<r0bgleeson> is he still hacking on ruby?
<erikh> rack I think, doing a lot of go too
<erikh> and he was trying to do the rubygems infosec stuff a while back.
<erikh> he lives down the street.
<r0bgleeson> you work together right?
<erikh> not anymore
<r0bgleeson> alright
<erikh> he's at the googles now
<r0bgleeson> oh wow, nice
<erikh> I left before the company got bought
<r0bgleeson> google bought the company?
<erikh> yep
<erikh> 400mil + 100mil retention bonuses
<r0bgleeson> hm cool
<erikh> silly money
dhruvasagar has joined #ruby-lang
vlad_starkov has quit [Ping timeout: 256 seconds]
tsion has joined #ruby-lang
tjcravey has quit [Quit: ZNC - http://znc.in]
tjcravey has joined #ruby-lang
chessguy has joined #ruby-lang
brianpWins has joined #ruby-lang
Bosox20051 has quit [Remote host closed the connection]
Wardrop has left #ruby-lang [#ruby-lang]
wmoxam has joined #ruby-lang
ryez has quit [Quit: Page closed]
jaimef has quit [Ping timeout: 276 seconds]
arubin has joined #ruby-lang
<whitequark> the world living 9-23 is... annoying
bzalasky has joined #ruby-lang
dankest has quit [Quit: Leaving...]
marr has quit [Ping timeout: 264 seconds]
jovy88 has quit [Read error: Connection reset by peer]
jovy88 has joined #ruby-lang
io_syl has quit [Read error: Operation timed out]
bzalasky has quit [Remote host closed the connection]
richcollins has quit [Quit: richcollins]
chimkan has joined #ruby-lang
jaimef has joined #ruby-lang
robbyoconnor has joined #ruby-lang
pskosinski has quit [Quit: pskosinski]
pskosinski has joined #ruby-lang
Domon has joined #ruby-lang
bzalasky has joined #ruby-lang
richcollins has joined #ruby-lang
symm- has quit [Ping timeout: 252 seconds]
mezamashiman has joined #ruby-lang
havenwood has joined #ruby-lang
lsegal has joined #ruby-lang
brianpWins has quit [Ping timeout: 264 seconds]
dankest has joined #ruby-lang
tylersmi_ has quit [Remote host closed the connection]
tylersmith has joined #ruby-lang
tylersmith has quit [Remote host closed the connection]
brettchalupa has joined #ruby-lang
brianpWins has joined #ruby-lang
havenwood has quit [Remote host closed the connection]
pskosinski has quit [Quit: pskosinski]
havenwood has joined #ruby-lang
dhruvasagar has quit [Read error: Operation timed out]
havenwood has quit [Ping timeout: 264 seconds]
tjcravey has quit [Ping timeout: 264 seconds]
tjcravey has joined #ruby-lang
dhruvasagar has joined #ruby-lang
DomKM has joined #ruby-lang
<MouseTheLuckyDog> erikh, I don't get tjem why it works when I press a regular key but not when I press a cursor key.
<MouseTheLuckyDog> s/tjem/then/
pkrnj has quit [Ping timeout: 260 seconds]
pkrnj has joined #ruby-lang
brettchalupa has quit [Quit: brettchalupa]
seoaqua has joined #ruby-lang
chrishunt has quit [Quit: ZzZzZz...]
chrishunt has joined #ruby-lang
dhruvasagar has quit [Ping timeout: 255 seconds]
tsan has joined #ruby-lang
hahuang65 has joined #ruby-lang
krombr has joined #ruby-lang
seoaqua has quit [Ping timeout: 256 seconds]
robbyoconnor has quit [Read error: Connection reset by peer]
robbyoconnor has joined #ruby-lang
krombr has quit [Client Quit]
krombr has joined #ruby-lang
save_ has joined #ruby-lang
save_ has quit [Client Quit]
srbaker_ has joined #ruby-lang
tjcravey has quit [Ping timeout: 264 seconds]
tjcravey has joined #ruby-lang
io_syl has joined #ruby-lang
totallymike has quit [Ping timeout: 256 seconds]
wmoxam has quit [Ping timeout: 260 seconds]
rickhull has quit [Ping timeout: 264 seconds]
krz has joined #ruby-lang
havenwood has joined #ruby-lang
bzalasky has quit [Read error: Connection reset by peer]
woollyams has quit [Read error: Connection reset by peer]
s0ber has quit [Remote host closed the connection]
bzalasky has joined #ruby-lang
rickhull has joined #ruby-lang
s0ber has joined #ruby-lang
havenwood has quit [Remote host closed the connection]
woollyams has joined #ruby-lang
grandy__ has quit [Ping timeout: 276 seconds]
rwk1 has quit [Read error: Connection reset by peer]
rwk1 has joined #ruby-lang
bryanl_ has quit [Quit: bryanl out]
bryanl has joined #ruby-lang
mezamashiman has quit [Ping timeout: 276 seconds]
levifig has quit [Ping timeout: 276 seconds]
mezamashiman has joined #ruby-lang
ikrima has quit [Quit: Computer has gone to sleep.]
levifig has joined #ruby-lang
tylersmith has joined #ruby-lang
owen1 has left #ruby-lang ["WeeChat 0.4.0"]
richcollins has quit [Quit: richcollins]
tylersmith has quit [Ping timeout: 245 seconds]
kgrz has joined #ruby-lang
dezasseis has quit [Quit: Leaving.]
danrabinowitz has joined #ruby-lang
brianpWins has quit [Quit: brianpWins]
seoaqua has joined #ruby-lang
dhruvasagar has joined #ruby-lang
bentis_ has joined #ruby-lang
seoaqua has quit [Quit: 离开]
bentis has quit [Ping timeout: 264 seconds]
jovy88 has quit [Read error: Connection reset by peer]
dingus_khan has joined #ruby-lang
jovy88 has joined #ruby-lang
cupakromer has left #ruby-lang [#ruby-lang]
<dingus_khan> this is probably a stupid question, but I can't figure out how to pop two items in an array that appear at the top of the stack, and I have no idea how to look that question up...
pabs_ is now known as pabs
<pabs> items = array.pop(2)
chrishunt has quit [Quit: ZzZzZz...]
<pabs> if you want the first two items of the array rather than the last two, you can use .shift instead of .pop
<pabs> items = array.shift(2)
dhruvasagar has quit [Ping timeout: 256 seconds]
<dingus_khan> right, shift... hmmm
richcollins has joined #ruby-lang
chimkan has quit [Quit: chimkan]
<dingus_khan> thanks pabs, I think I may be on the right track now
bnagy has quit [Ping timeout: 246 seconds]
bnagy has joined #ruby-lang
headius has quit [Quit: headius]
vlad_starkov has joined #ruby-lang
havenwood has joined #ruby-lang
brianpWins has joined #ruby-lang
vlad_starkov has quit [Ping timeout: 245 seconds]
mezamashiman has quit [Quit: leaving]
mezamashiman has joined #ruby-lang
DomKM has quit [Quit: Leaving.]
<whitequark> right shift! left pop!
pipework has joined #ruby-lang
cordax has joined #ruby-lang
<dingus_khan> yeah, my thing is not working... I am le dumb
<xuser> use viagra
<dingus_khan> I actually saw that coming, and I deserve it
<dingus_khan> can someone please tell me if this is *the* stupidest attempt at this problem they've ever seen?: http://pastebin.com/yTGpaSby
<charliesome> dingus_khan: pastebin :(
postmodern has quit [Quit: Leaving]
<dingus_khan> umm, is that a yes?
<whitequark> dingus_khan: that is actually OK
<whitequark> but
<whitequark> the pop-inject-block thingy is really, really unnecessary
<whitequark> first, second = result.pop(2); result.push(first + second)
<whitequark> or even
<whitequark> result.pop(2).reduce(:+)
<whitequark> (it'll then use the first value as an accumulator)
<richcollins> Can anyone explain wtf is going on here?
<richcollins> why doesn't that raise an exception?
tomzx_mac has quit [Ping timeout: 264 seconds]
bzalasky has quit [Remote host closed the connection]
<arubin> Why would it?
<richcollins> arubin: because elseif isn't a valid keyword? It should be elsif
<richcollins> if you change elseif to elsif it prints "true"
<arubin> I see.
<arubin> I just noticed that.
kgrz has quit [Ping timeout: 252 seconds]
bright_day has joined #ruby-lang
<richcollins> its like it completely ignores the elseif statement
<tsion> richcollins: reindent it and add optional parens:
<tsion> if false
<tsion> puts("false")
<tsion> elseif(true)
<tsion> puts("true")
<tsion> and so on
<tsion> that branch is never entered (if false) so elseif(true) is never executed
<tsion> it's not a syntax error, elseif is a valid method name
<arubin> richcollins: It does, because it is part of the first block.
tsan has quit [Quit: Leaving.]
<arubin> richcollins: So it never tries to execute it.
brianpWins has quit [Quit: brianpWins]
krohrbaugh has joined #ruby-lang
<richcollins> ah
setmeaway has joined #ruby-lang
DomKM has joined #ruby-lang
havenwood has quit [Remote host closed the connection]
havenwood has joined #ruby-lang
krohrbaugh has quit [Ping timeout: 268 seconds]
rickhull has quit [Quit: Leaving.]
havenwood has quit [Ping timeout: 255 seconds]
nathanstitt has quit [Quit: I growing sleepy]
rwk1 has quit [Remote host closed the connection]
jsullivandigs has quit [Read error: Connection reset by peer]
jsullivandigs has joined #ruby-lang
brianpWins has joined #ruby-lang
vlad_starkov has joined #ruby-lang
vlad_starkov has quit [Ping timeout: 245 seconds]
kgrz has joined #ruby-lang
mistym has quit [Remote host closed the connection]
grandy__ has joined #ruby-lang
<dingus_khan> whitequark: thanks for the tip! I'm definitely going to redo it all with reduce and change the way it pushes to the array, since it has no way to recognize integers in the string right now, sigh
dhruvasagar has joined #ruby-lang
kgrz has quit [Ping timeout: 245 seconds]
headius has joined #ruby-lang
benlovell has joined #ruby-lang
dingus_khan has quit [Ping timeout: 245 seconds]
nettsundere has quit [Read error: Connection reset by peer]
wallerdev has quit [Quit: wallerdev]
srbaker_ has quit [Ping timeout: 252 seconds]
pkrnj has quit [Quit: Textual IRC Client: www.textualapp.com]
bright_day has quit [Quit: Computer has gone to sleep.]
arubin has quit [Quit: Textual IRC Client: www.textualapp.com]
benlovell has quit [Ping timeout: 268 seconds]
ryez has joined #ruby-lang
cordax has quit [Quit: Computer has gone to sleep.]
rwk1 has joined #ruby-lang
rwk1 has quit [Ping timeout: 268 seconds]
chessguy has quit [Ping timeout: 252 seconds]
srbaker has joined #ruby-lang
Mon_Ouie has joined #ruby-lang
bzalasky has joined #ruby-lang
krohrbaugh has joined #ruby-lang
brianpWins has quit [Quit: brianpWins]
nettsundere has joined #ruby-lang
workmad3 has joined #ruby-lang
rwk1 has joined #ruby-lang
sush24 has joined #ruby-lang
krohrbaugh has quit [Ping timeout: 276 seconds]
brianpWins has joined #ruby-lang
dankest has quit [Quit: Leaving...]
dankest has joined #ruby-lang
elia has joined #ruby-lang
headius has quit [Quit: headius]
seoaqua has joined #ruby-lang
<seoaqua> are there any chinese guys in this channel
dhruvasagar has quit [Ping timeout: 256 seconds]
fosky has joined #ruby-lang
kgrz has joined #ruby-lang
elia has quit [Quit: Computer has gone to sleep.]
kgrz has quit [Ping timeout: 256 seconds]
stardiviner has joined #ruby-lang
dankest has quit [Quit: Leaving...]
saarinen has joined #ruby-lang
richcollins has quit [Quit: richcollins]
workmad3 has quit [Ping timeout: 264 seconds]
solars has joined #ruby-lang
seoaqua has quit [Quit: 离开]
kgrz has joined #ruby-lang
headius has joined #ruby-lang
benlovell has joined #ruby-lang
Kabaka has quit [Excess Flood]
krohrbaugh has joined #ruby-lang
rwk1 has quit [Remote host closed the connection]
kgrz has quit [Ping timeout: 255 seconds]
krohrbaugh has quit [Ping timeout: 260 seconds]
headius has quit [Quit: headius]
havenwood has joined #ruby-lang
Kabaka has joined #ruby-lang
gnufied has joined #ruby-lang
saarinen has quit [Quit: saarinen]
Mon_Ouie has quit [Read error: Connection reset by peer]
Mon_Ouie has joined #ruby-lang
Kabaka has quit [Excess Flood]
cofin has quit [Quit: cofin]
lsegal has quit [Quit: Quit: Quit: Quit: Stack Overflow.]
vlad_starkov has joined #ruby-lang
headius has joined #ruby-lang
ruby-lang390 has joined #ruby-lang
Kabaka has joined #ruby-lang
headius has quit [Client Quit]
ruby-lang390 has quit [Client Quit]
fsvehla has joined #ruby-lang
vlad_starkov has quit [Ping timeout: 276 seconds]
blacktulip has joined #ruby-lang
Mon_Ouie has quit [Read error: Connection reset by peer]
Mon_Ouie has joined #ruby-lang
Mon_Ouie has quit [Changing host]
Mon_Ouie has joined #ruby-lang
krombr has quit [Quit: krombr]
scottschecter has quit [Ping timeout: 264 seconds]
megha has joined #ruby-lang
baba has quit [Ping timeout: 260 seconds]
megha is now known as baba
grobb has joined #ruby-lang
tonni has quit [Remote host closed the connection]
headius has joined #ruby-lang
headius has quit [Client Quit]
fsvehla has quit [Quit: fsvehla]
fsvehla has joined #ruby-lang
havenn_ has joined #ruby-lang
Axsuul has joined #ruby-lang
havenwood has quit [Ping timeout: 268 seconds]
Kabaka has quit [Excess Flood]
GarethAdams has joined #ruby-lang
mucker has joined #ruby-lang
scottschecter has joined #ruby-lang
Kabaka has joined #ruby-lang
ikrima has joined #ruby-lang
skade has joined #ruby-lang
solars has quit [Ping timeout: 264 seconds]
grobb has quit [Quit: grobb]
grobb has joined #ruby-lang
mytrile has joined #ruby-lang
GarethAdams has quit [Quit: Leaving...]
dingus_khan has joined #ruby-lang
dezasseis has joined #ruby-lang
mytrile has quit [Remote host closed the connection]
dhruvasagar has joined #ruby-lang
bzalasky has quit [Remote host closed the connection]
krohrbaugh has joined #ruby-lang
mytrile has joined #ruby-lang
krohrbaugh has quit [Ping timeout: 256 seconds]
DomKM has quit [Quit: Leaving.]
headius has joined #ruby-lang
krz has quit [Ping timeout: 276 seconds]
io_syl has quit [Quit: Computer has gone to sleep.]
headius has quit [Client Quit]
headius has joined #ruby-lang
dingus_khan has quit [Quit: Leaving]
<yorickpeterse> morning
pipework has quit [Remote host closed the connection]
tsion has quit [Quit: Leaving]
vlad_starkov has joined #ruby-lang
krz has joined #ruby-lang
Maax has joined #ruby-lang
headius has quit [Quit: headius]
Maax has left #ruby-lang [#ruby-lang]
xxaM has quit [Disconnected by services]
xxaM has joined #ruby-lang
beiter has joined #ruby-lang
bzalasky has joined #ruby-lang
vlad_starkov has quit [Ping timeout: 255 seconds]
postmodern has joined #ruby-lang
woollyams has quit [Ping timeout: 260 seconds]
<gnufied> morning yorick
retro|cz has joined #ruby-lang
benlovell has quit [Read error: Operation timed out]
brianpWins has quit [Quit: brianpWins]
skade has quit [Quit: Computer has gone to sleep.]
benlovell has joined #ruby-lang
mrfelix has joined #ruby-lang
mrfelix has quit [Client Quit]
<yorickpeterse> damn it, it's a national holiday (so everything is closed) and I'm out of milk for my cereal
skade has joined #ruby-lang
<yorickpeterse> whitequark: node.js node.js node.js node.js
alessio_rocco has joined #ruby-lang
fsvehla has quit [Quit: fsvehla]
bzalasky has quit [Remote host closed the connection]
elia has joined #ruby-lang
<whitequark> yorickpeterse: huh, it's national holiday here too, but you can easily buy food
<yorickpeterse> Holland is a weird place
<yorickpeterse> The closest grocery store is about 10 minutes cycling away but doesn't open until 16:00
<yorickpeterse> (normally it's a 1 minute walk, but that one is closed)
<whitequark> I have two just in my house
<whitequark> ... and at least one in every adjacent one. now that I think about it, that's a bit weird.
<yorickpeterse> you live in a shopping mall?
<yorickpeterse> you're not one of those homeless people with a box and internet are you?
<whitequark> lol
<whitequark> well, no, not at least one in every adjacent one, that was an overestimation. but still a lot.
Maax has joined #ruby-lang
beiter has quit [Quit: beiter]
Maax has left #ruby-lang [#ruby-lang]
<yorickpeterse> I live above a parfumer but that's about it
xxaM has quit [Disconnected by services]
<yorickpeterse> The bank below me closed a few months ago
xxaM has joined #ruby-lang
gnufied has quit [Quit: Leaving.]
beiter has joined #ruby-lang
gnufied has joined #ruby-lang
<yorickpeterse> but! I'm pretty sure the view from my balcony is better
nXqd has joined #ruby-lang
adambeynon has joined #ruby-lang
beiter has quit [Client Quit]
beiter has joined #ruby-lang
sush24 has quit [Quit: This computer has gone to sleep]
xxaM has quit [Ping timeout: 260 seconds]
marr has joined #ruby-lang
vlad_starkov has joined #ruby-lang
sush24 has joined #ruby-lang
mytrile has quit [Remote host closed the connection]
vlad_starkov has quit [Ping timeout: 245 seconds]
savagecroc has joined #ruby-lang
<savagecroc> Solve for x where [{:bla => 22}, {:boa => 33}.x => [22, 33]
<savagecroc> [{:bla => 22}, {:boa => 33}].x => [22, 33]
<savagecroc> [{:bla => 22}, {:bla => 33}].x => [22, 33] << ugh third time luck
<savagecroc> lucky*
xxaM has joined #ruby-lang
<yorickpeterse> gah, I hate my wifi
<bnagy> x.map(&:values).flatten?
<yorickpeterse> it really can not handle there being around 25 other networks around me
<savagecroc> [{:bla => 22},{:bla => 33}].map {|w| w[:bla]}
<bnagy> also
<savagecroc> yeah symbol to proc is a bit hard to use with w[:bla]
<injekt> moin
<savagecroc> maybe i'll make [{:bla => 22},{:bla => 33}].extract_key(:boa)
GarethAdams has joined #ruby-lang
<savagecroc> maybe i'll make [{:bla => 22},{:bla => 33}].extract_key(:bla)
PhilG has joined #ruby-lang
retro|cz has quit [Ping timeout: 264 seconds]
<savagecroc> class Array; def extract_key(key); map {|i| i[key]}; end; end
<bnagy> savagecroc: that is disgusting
<savagecroc> go on...
<bnagy> monkeypatching core classes is disgusting in almost all cases
<savagecroc> ok.. reason?
kgrz has joined #ruby-lang
<bnagy> pollutes namespace, which could screw up anything that inherits from them
<yorickpeterse> conflicts
<savagecroc> i've never come across an issue yet
<yorickpeterse> Remember that when you patch something it can potentially affect *everything* in your codebase
<bnagy> and, in general, it's just inelegant
charliesome_ has joined #ruby-lang
<yorickpeterse> that's like saying "Driving drunk is fine, I've never been caught!"
retro|cz has joined #ruby-lang
<bnagy> Arrays shouldn't know how to do that, it's not Arrayish behaviour
<savagecroc> are you talking about things that inherit from array?
<bnagy> so you will confuse the hell out of anyone reading your code
<heftig> just something like module Helpers; def hash_values(hashes, key); hashes.map { |h| h[key] }; end; end
<charliesome_> yorickpeterse: good point
<heftig> er, add module_function :hash_values
<savagecroc> heftig: ah yeah
charliesome has quit [Disconnected by services]
charliesome_ is now known as charliesome
<savagecroc> would you namespace them
<savagecroc> Helpers.hash_values
<bnagy> savagecroc: with something that simple I would just have ary.map {|e| e.fetch :bla}
<charliesome> savagecroc: namespace them with refinements
<bnagy> but if it's more complex then just define a method in wherever you're using it
<heftig> ew, refinements
<charliesome> using DisgustingArrayHacks; ary.extract_key(:yolo!)
<bnagy> or if you reeeeeally want it as an obect behaviour make a DelegateClass to Array
<charliesome> the best way to safely monkey patch is to prepend
<savagecroc> i've got about 20 monkeypatched methods on hash.. but switching them to helper functions would not be difficult
<charliesome> then if someone else monkeypatches the normal way
<charliesome> you still override them!
<savagecroc> things like def deep_copy; Marshal.load( Marshal.dump(self) ); end;
kgrz has quit [Ping timeout: 268 seconds]
<yorickpeterse> The best monkeypatch is no monkeypatch
<charliesome> yorickpeterse: shush fun police
<andrewvos> I agree with fun police
<yorickpeterse> STOP RIGHT THERE CRIMINAL SCUM
<yorickpeterse> NOBODY BREAKS THE CORE CLASSES ON MY WATCH
<charliesome> actually
<yorickpeterse> WE'LL CONFISCATE ANY STOLEN MONKEYPATCHES AND THEN IT'S OFF TO JAIL
<charliesome> i had an idea for a usecase for refinements
<yorickpeterse> get out
<savagecroc> actually
<charliesome> can you imagine something like this
<savagecroc> i think String.. would have to be monkey patched
<charliesome> User.select { |user| user.age >= 18 }
<charliesome> being turned into SELECT * FROM users WHERE age >= 18
<charliesome> or maybe you'd write
<charliesome> User.select { :age >= 18 }
<yorickpeterse> charliesome: Sequel does that
<yorickpeterse> and without monkeypatches
<yorickpeterse> from what I can tell at least
<charliesome> actually there's another feature of ruby 2.0 that means you can do that without refinements
<charliesome> RubyVM::InstructionSequence.of
<savagecroc> https://gist.github.com/freedomfreddy/2b49d1dbc66b76f64bd8 << this i use everywhere in the code
<charliesome> pass it a proc and you're golden
<bnagy> if there was a "being right" combo bonus, yorickpeterse would be pretty close to it right now
<savagecroc> it allows you to do stuff like variable = <<-SQL.unindent
<savagecroc> and still keep your indentation without all the whitespace
<yorickpeterse> charliesome: you're a terrible person
<yorickpeterse> but we still love you
<bnagy> AHHAHAH U LUV MEN
Mon_Ouie has quit [Ping timeout: 264 seconds]
<yorickpeterse> liek if u cry everytiem
<charliesome> i'd love to write a yarv bytecode -> ast thing
<bnagy> I think the Ruby equivalent of Godwin ("this is how Nazi Germany started") should be "this is how ActiveSupport started"
Mon_Ouie has joined #ruby-lang
Mon_Ouie has quit [Changing host]
Mon_Ouie has joined #ruby-lang
<yorickpeterse> patch all the things
<charliesome> half of AS should be pulled into ruby itself imo
<bnagy> charliesome: do it with llvm
<savagecroc> charliesome: i thought half of it was
<charliesome> bnagy: and hadoop
<bnagy> ... no
<charliesome> savagecroc: well now the other half
<savagecroc> there's where symbol to proc came from
<savagecroc> yeah i really think all the time functions should be in ruby
beiter has quit [Quit: beiter]
<charliesome> didn't that come from facets originally
<charliesome> facets was activesupport before rails was cool
<savagecroc> it's really annoying having to include AS
<bnagy> I'll concede that Time Date and DateTime is a clusterfuck
<charliesome> yeah. there's heaps of useful methods but i'm not depending on AS just for a helper method
<bnagy> but 3.months makes me physically ill
<savagecroc> ah there are so many useful functions in there.. like time.beginning_of_week etc
<savagecroc> not having to write all the crap yourself is really nice
PhilG has quit [Remote host closed the connection]
<bnagy> I think they're left out of ruby because they're wildly imprecise
<yorickpeterse> yo dawg, I heard you like times so I put a Time, Date and DateTime in your stdlib so you can DateTime while you Date Time
barttenbrinke has joined #ruby-lang
benanne has joined #ruby-lang
postmodern has quit [Quit: Leaving]
sush24 has quit [Quit: This computer has gone to sleep]
<charliesome> bnagy: why don't you like 3.months and friends?
<bnagy> because 3 is a fucking number
<bnagy> even 3.times makes me queasy
<charliesome> Fixnum#times is the best thing ever
<charliesome> the best part about it is how it returns an enumerator if you don't give it a block
jovy88 has quit [Read error: Connection reset by peer]
<savagecroc> yeah i like 3 months
<charliesome> n.times.map { read_something }
<savagecroc> makes code so easy to read
<bnagy> it's useful, but it's still screwing the object model
<yorickpeterse> 3.months.ago.beginning_of_time.to_time.utc # herp derp
<charliesome> bnagy: ruby's committed greater sins against object models than Fixnum#times
<charliesome> like Class < Module
<bnagy> what's wrong with that?
<savagecroc> bnagy: ok.. i find you a perfect example of how useful .months is
<yorickpeterse> http://downloads.yorickpeterse.com/images/hierarchy.png that brings us to this
<charliesome> bnagy: you can't substitute a class everywhere it expects a module
jovy88 has joined #ruby-lang
<bnagy> well no, because a Class is a special kind of Module
<charliesome> bnagy: exactly, so it shouldn't be a subclass
<charliesome> liskov would like a word with you
<bnagy> the actual implementation breaks the object model, but that's like deep in the code
<bnagy> subclasses are more specialised than superclasses
<savagecroc> bnagy: https://gist.github.com/freedomfreddy/8b00dc73645bdbee56ef << without .year .days, that would be very hard to read
<bnagy> .. that's like what they're for
<bnagy> ok... not that I accept that this is a useful priciple, but where's the violation?
<bnagy> out of interest
<charliesome> bnagy: the most obvious violation is you can't include a Class
<bnagy> ahh, yeah ok
<bnagy> is that a behavioural violation though?
<charliesome> bnagy: well sure
<charliesome> also i could've sworn that UnboundMethod < Method
<charliesome> but it doesn't appear like that's the case
<bnagy> like, isn't include on Module?
<injekt> nope I noticed that a few days ago, I thought the same
<charliesome> bnagy: sure but the principle still holds
<charliesome> if you want to put it in terms of who owns the method, let's talk about append_features instead
<bnagy> ... unconvinced
<bnagy> Module.include othermod
<injekt> 10>> Object.superclass
<eval-in> injekt => nil (http://eval.in/24395)
<bnagy> like...
<injekt> 10>> Method
<eval-in> injekt => /tmp/execpad-761faf4bc9cd/source-761faf4bc9cd:2: NameError: Uninitialized constant Method (http://eval.in/24396)
<charliesome> bnagy: now replace othermod with otherclass
<charliesome> it'll blow up
<charliesome> even though Class < Module
<bnagy> yeah but neither modules nor classes can include anything but Modules
<bnagy> it's a behaviour of the superclass
<charliesome> ok so why is Class a subclass of Module
<charliesome> classes clearly aren't modules
<bnagy> they're modules that can be instantiated :/
<bnagy> yeah OK it's weak :)
<charliesome> a cleaner way of expressing the relationship between Class and Module would be to add a third class, Namespace
<charliesome> Class < Namespace
<charliesome> Module < Namespace
jovy88 has quit [Read error: Connection timed out]
<bnagy> and hope this liskov crap isn't transitive? ;)
jovy88 has joined #ruby-lang
krohrbaugh has joined #ruby-lang
<charliesome> well if Class and Module both inherited from a common superclass, they wouldn't be in violation of LSP
kgrz has joined #ruby-lang
workmad3 has joined #ruby-lang
<bnagy> and where would you define include?
<charliesome> well interestingly include does nothing except call append_features
<charliesome> class Module; def include(other); other.append_features(self); end; end
krohrbaugh has quit [Ping timeout: 256 seconds]
kgrz has quit [Ping timeout: 268 seconds]
<charliesome> weird
<charliesome> looks like UnboundMethod is not a subclass of Method in 1.8.7, 1.9.2 or 1.9.3
<charliesome> dunno where i got that idea
GarethAdams|Work has joined #ruby-lang
vlad_starkov has joined #ruby-lang
GarethAdams has quit [Ping timeout: 276 seconds]
skade has quit [Ping timeout: 276 seconds]
fosky has quit [Remote host closed the connection]
<charliesome> i bet there's some gnarly macros there
fosky has joined #ruby-lang
vlad_starkov has quit [Ping timeout: 256 seconds]
zenspider has joined #ruby-lang
nibbo_ has quit [Ping timeout: 255 seconds]
skade has joined #ruby-lang
baba has quit [Ping timeout: 256 seconds]
mbj has joined #ruby-lang
workmad3 has quit [Ping timeout: 256 seconds]
sush24 has joined #ruby-lang
fosky has quit [Remote host closed the connection]
skade has quit [Quit: Computer has gone to sleep.]
mezamashiman has quit [Quit: leaving]
baba has joined #ruby-lang
savagecroc has quit [Remote host closed the connection]
skade has joined #ruby-lang
<whitequark> charliesome: ugh, everyone's obsessing around that library lately
<whitequark> C can't be fixed, deal with that
<charliesome> it's hilarious
<charliesome> i would never actually use that library
<yorickpeterse> lets all use Go instead
<charliesome> lol
cofin has joined #ruby-lang
<charliesome> go has some cool ideas but too many dealbreakers for me
<yorickpeterse> or Haskell. Haskell has static typing, you can't get any bugs in your code because of that
<injekt> yorickpeterse: too late i already am
voker57 has joined #ruby-lang
voker57 has quit [Changing host]
voker57 has joined #ruby-lang
<injekt> man that library is gonna pop up everywhere.. and that makes me sad
<charliesome> yorickpeterse: that's hilarious
<charliesome> injekt: why>
<injekt> charliesome: people who are writing C should know how to write C, I think that library is encouraging bad practice
<charliesome> injekt: so i doubt anyone would actually use that library
<injekt> charliesome: I wish that, but I honestly think it's gonna start popping up in peoples code
<injekt> charliesome: hopefully you're right!
<whitequark> yorickpeterse: most hilarious part of that page is .asp extension
<yorickpeterse> that extension is a joke regardless of the content
voker57 has quit [Read error: Connection reset by peer]
voker57 has joined #ruby-lang
voker57 has quit [Changing host]
voker57 has joined #ruby-lang
krohrbaugh has joined #ruby-lang
skade has quit [Quit: Textual IRC Client: www.textualapp.com]
idkazuma has joined #ruby-lang
krohrbaugh has quit [Ping timeout: 256 seconds]
krz has quit [Quit: krz]
GeissT has joined #ruby-lang
Azulinho has joined #ruby-lang
<injekt> great lambda macros bro
<yorickpeterse> dem macros
idkazuma has quit [Ping timeout: 255 seconds]
ndrst has quit [Ping timeout: 256 seconds]
vlad_starkov has joined #ruby-lang
roadt has quit [Ping timeout: 260 seconds]
roadt has joined #ruby-lang
cofin has quit [Quit: cofin]
voker57 has quit [Remote host closed the connection]
<charliesome> those macros are more amazing than MRI's
Domon has quit [Remote host closed the connection]
thebastl has joined #ruby-lang
vlad_starkov has quit [Ping timeout: 276 seconds]
benlovell has quit [Ping timeout: 276 seconds]
robbyoconnor has quit [Ping timeout: 264 seconds]
machuga|away has joined #ruby-lang
roadt has quit [Ping timeout: 245 seconds]
roadt has joined #ruby-lang
<MouseTheLuckyDog> http://pastie.org/7820795#1,13-14
<MouseTheLuckyDog> the source for the trace program is at http://pastie.org/7820304
MaddinXx_ has joined #ruby-lang
<yorickpeterse> eh?
<MouseTheLuckyDog> One more comment when I comment out the two rescues I get a Eagain exception thrown by the second read_nonblock.
<MouseTheLuckyDog> yorickpeterse, ?
nXqd has quit [Ping timeout: 256 seconds]
<yorickpeterse> as in, why did you paste two random pasties?
<MouseTheLuckyDog> Oh. In the first one, the third system command malfunctions. It doesn't take input from the tty.
Axsuul has quit [Ping timeout: 264 seconds]
<MouseTheLuckyDog> line 25
<yorickpeterse> and your question is?
<yorickpeterse> (generally it's best to start with a question instead of just pasting something)
<MouseTheLuckyDog> How do I fix the third command to run properly?
machuga|away has left #ruby-lang [#ruby-lang]
<yorickpeterse> which third command?
ndrst has joined #ruby-lang
nXqd has joined #ruby-lang
<MouseTheLuckyDog> I suspect that for some reason the Eagain error is somehow "getting stuck" in the stdin and stdin has to be clear or reset before the third command.
<MouseTheLuckyDog> yorickpeterse, line 25.
<MouseTheLuckyDog> line 19-25 are the core of the problem the first two system commands work properly the third does not.
machuga has joined #ruby-lang
benlovell has joined #ruby-lang
jds_ has joined #ruby-lang
jds has quit [Ping timeout: 268 seconds]
ndrst has quit [Ping timeout: 276 seconds]
greenarrow has quit [Ping timeout: 264 seconds]
greenarrow has joined #ruby-lang
ndrst has joined #ruby-lang
dhruvasagar has quit [Ping timeout: 256 seconds]
grobb has quit [Quit: grobb]
dhruvasagar has joined #ruby-lang
sepp2k has joined #ruby-lang
krohrbaugh has joined #ruby-lang
krohrbaugh has quit [Read error: Connection reset by peer]
krohrbaugh has joined #ruby-lang
krohrbaugh has quit [Ping timeout: 252 seconds]
jds has joined #ruby-lang
jds_ has quit [Ping timeout: 252 seconds]
adambeynon has quit [Quit: Computer has gone to sleep.]
tjcravey has quit [Ping timeout: 264 seconds]
ndrst has quit [Ping timeout: 264 seconds]
tjcravey has joined #ruby-lang
babinho has quit [Quit: leaving]
babinho has joined #ruby-lang
vlad_starkov has joined #ruby-lang
adambeynon has joined #ruby-lang
ahf has quit [Quit: Reconnecting]
ahf has joined #ruby-lang
ahf has joined #ruby-lang
ahf has quit [Changing host]
yalue has joined #ruby-lang
wallerdev has joined #ruby-lang
benlovell has quit [Ping timeout: 252 seconds]
sailias has joined #ruby-lang
mytrile has joined #ruby-lang
ndrst has joined #ruby-lang
vlad_starkov has quit [Ping timeout: 252 seconds]
Azulinho has quit [Ping timeout: 260 seconds]
sailias has quit [Ping timeout: 245 seconds]
<mbj> whitequark: Source::Range#to_source is planned to be supported for all nodes as exact reproduction?
robbyoconnor has joined #ruby-lang
dhruvasagar has quit [Ping timeout: 256 seconds]
<mbj> whitequark: have to run, will ping you later.
mbj has quit [Quit: leaving]
breakingthings has joined #ruby-lang
sailias has joined #ruby-lang
adambeynon has quit [Quit: ["Textual IRC Client: www.textualapp.com"]]
carloslopes has joined #ruby-lang
benlovell has joined #ruby-lang
robbyoconnor has quit [Ping timeout: 245 seconds]
workmad3 has joined #ruby-lang
MouseTheLuckyDog has quit [Quit: Leaving]
jxie has quit [Quit: leaving]
nXqd has quit [Ping timeout: 268 seconds]
jperry_ has quit [Quit: jperry_]
ndrst has quit [Quit: WeeChat 0.4.0]
jperry has joined #ruby-lang
nXqd has joined #ruby-lang
thebastl has quit [Remote host closed the connection]
jperry has left #ruby-lang [#ruby-lang]
jperry has joined #ruby-lang
tomzx_mac has joined #ruby-lang
ndrst has joined #ruby-lang
mistym has joined #ruby-lang
mistym has joined #ruby-lang
mistym has quit [Changing host]
krohrbaugh has joined #ruby-lang
roadt has quit [Ping timeout: 245 seconds]
andrei__ has joined #ruby-lang
havenn_ has quit [Remote host closed the connection]
mistym has quit [Remote host closed the connection]
havenwood has joined #ruby-lang
krohrbaugh has quit [Ping timeout: 252 seconds]
jvrmaia has joined #ruby-lang
havenwood has quit [Ping timeout: 245 seconds]
<jperry> Hi everyone, if I only can go to one of the ruby conferences RubyNation or RubyConf which one would you suggest?
<charliesome> jperry: rubyconf
io_syl has joined #ruby-lang
<jperry> @charliesome anything to back that up?
<charliesome> not really
<jperry> is it just a bigger event?
<charliesome> yeah its more established i think
machuga is now known as machuga|away
machuga|away is now known as machuga|work
<jperry> I live in Boston and there is a vermont one but I think I'd rather go to either RubyNation or RubyConf
<jperry> I guess I'll see what my company is willing to fun
<jperry> fund
<jperry> the session list isn't available yet for RubyConf
<charliesome> it's usually pretty decent i believe
<charliesome> yeah they had matz last yeah
<charliesome> year*
GarethAdams|Work is now known as GarethAdams
wallerdev has quit [Quit: wallerdev]
vlad_starkov has joined #ruby-lang
charliesome has quit [Quit: Textual IRC Client: www.textualapp.com]
wmoxam has joined #ruby-lang
r0bgleeson has quit [Ping timeout: 276 seconds]
vlad_starkov has quit [Ping timeout: 264 seconds]
r0bgleeson has joined #ruby-lang
mistym has joined #ruby-lang
mistym has quit [Changing host]
mistym has joined #ruby-lang
kgrz has joined #ruby-lang
sush24 has quit [Quit: This computer has gone to sleep]
dustint has joined #ruby-lang
adambeynon has joined #ruby-lang
scampbell has joined #ruby-lang
tomzx_mac has quit [Ping timeout: 252 seconds]
<jperry> charliesome: Nice, I'll see if I can go to that one, at the least the RubyNation lineup still looks pretty good
wallerdev has joined #ruby-lang
xcombelle has joined #ruby-lang
cofin has joined #ruby-lang
andrei__ has left #ruby-lang [#ruby-lang]
geson has joined #ruby-lang
<whitequark> yorickpeterse: >when it comes to method calling code I really want it to be consistent
<whitequark> ROFL.
<whitequark> pls count all of the ways to call a method in ruby.
<whitequark> then count all the syntactic constructs which invoke them.
ryez_ has joined #ruby-lang
<ericwood> 100
<ericwood> where is my prize?
<ericwood> whitequark: I will PM you my address so you can mail me my prize
_elia has joined #ruby-lang
<whitequark> disqualified
<whitequark> the correct number is... hmm, 25.
<ericwood> did you actually count?
<whitequark> yes
<yorickpeterse> whitequark: hey asshole, feel free to use what I actually wrote for the quote
<yorickpeterse> instead of coming up with something yourself
<whitequark> yorickpeterse: huh?
<yorickpeterse> "but when it comes to the method calling syntax
<yorickpeterse> I really want it to be consistent. "
<yorickpeterse> I explicitly stated "syntax", not the differences between send() and others
<ericwood> guys, guys, settle down
<ericwood> it's just ruby
<whitequark> yorickpeterse: sorry for the mistake. however my point still holds
<whitequark> it was just a typo.
<yorickpeterse> "a typo"
<whitequark> btw
jovy88 has quit [Read error: Connection reset by peer]
<whitequark> you can "actually get rid of the operator" by writing a trivial parser rewriter.
nathanstitt has joined #ruby-lang
elia has quit [Ping timeout: 252 seconds]
_elia is now known as elia
<yorickpeterse> probably, but just removing it would break existing code
<yorickpeterse> notably stdlib
nathanstitt has quit [Client Quit]
<yorickpeterse> because last time I checked it uses :: for method calls in various places
<yorickpeterse> which again is mentioned in said Email
jovy88 has joined #ruby-lang
<whitequark> yeah... stdlib is really ancient in much places
<whitequark> also matz has a point
<whitequark> * we have convention of Array class and Array(obj) conversion method, why not Foo::Bar and Foo::Bar(obj)?
<ericwood> ruby needs more syntactic sugar for me to keep up with
<yorickpeterse> syntax obesitas
<whitequark> syntax diabetes
sush24 has joined #ruby-lang
heftig has quit [Quit: Quitting]
heftig has joined #ruby-lang
<ericwood> syntax diabetus
<vbatts|work> woah
<ericwood> ain't got shit on C++ syntax :D
kgrz has quit [Ping timeout: 268 seconds]
<ericwood> "the users are rebelling! Quick, add more sugar!"
<yorickpeterse> hm, I have an idea
<whitequark> C++ isn't at least truly context-sensitive
ryez_ has quit [Ping timeout: 245 seconds]
<whitequark> whereas ruby is, from 1.9.2 onwards :/
<ericwood> my favorite feature of the old C++ was nested templates and having to put that fucking space between the closing >
<ericwood> > > instead of >>
<ericwood> because wtf Stroustrup
<yorickpeterse> >> def std; Object; end; std::String.new('C++')
<eval-in> yorickpeterse => "C++" (http://eval.in/24547)
<whitequark> ericwood: because LR(1)
<ericwood> whitequark: parser theory is my least favorite thing ever
io_syl has quit [Quit: Computer has gone to sleep.]
<ericwood> even my compilers prof was like, "I fucking hate parsers"
krohrbaugh has joined #ruby-lang
<ericwood> but he was an angry eastern european guy
sush24 has quit [Ping timeout: 256 seconds]
totallymike has joined #ruby-lang
nivanson has joined #ruby-lang
<whitequark> huh
<whitequark> I heard that there are two schools of compiler and language construction
ndrst has quit [Ping timeout: 245 seconds]
<whitequark> european prefers LL(1) (or LL(k) since 90's) parsers, american prefers LALR(1)
<whitequark> regardless... to disambiguate >> correctly you need lexer tricks just like in ruby's parse.y
<whitequark> I can totally understand why C++ guys did not want to add that to the spec
* whitequark scratches his head
<ericwood> they were too busy adding "auto"
<whitequark> template_a<template_b<1 >> 2>>
<ericwood> and stroustrup was too busy raking in cash from my university
<yorickpeterse> hahaha, here watch this
<ericwood> no
krohrbaugh has quit [Ping timeout: 252 seconds]
ndrst has joined #ruby-lang
<yorickpeterse> http://eval.in/24550
<yorickpeterse> could probably do it with less code but me
<yorickpeterse> * meh
sush24 has joined #ruby-lang
<whitequark> siiiigh
<yorickpeterse> :>
<injekt> yorickpeterse just wish ruby looked like cpp
mistym has quit [Remote host closed the connection]
<ericwood> :(
<injekt> wishes*
<yorickpeterse> I'm pretty sure you can make it look very close similar to that pastie
<injekt> yorickpeterse: probably, with all the magic ruby can do it can look like a lot of languages
<yorickpeterse> >> ?php
<eval-in> yorickpeterse => /tmp/execpad-84d51ccc1023/source-84d51ccc1023:2: syntax error, unexpected '?' ... (http://eval.in/24553)
<yorickpeterse> hmpf
<yorickpeterse> >> ??php
<eval-in> yorickpeterse => /tmp/execpad-376808ce84c5/source-376808ce84c5:2: syntax error, unexpected tIDENTIFIER, expecting keyword_end (http://eval.in/24554)
<yorickpeterse> bah
<yorickpeterse> oh, only works for single chars
<yorickpeterse> hmmmm
ndrst has quit [Ping timeout: 264 seconds]
chrishunt has joined #ruby-lang
<injekt> >> <%php %>
<eval-in> injekt => /tmp/execpad-d96c5df729f0/source-d96c5df729f0:2: syntax error, unexpected '<' ... (http://eval.in/24555)
<yorickpeterse> >> def int(name, &block); define_method(name, &block); end; int :close_enough { return "Close enough"; }; close_enough
<eval-in> yorickpeterse => /tmp/execpad-5f9ddfa70f75/source-5f9ddfa70f75:2: syntax error, unexpected '{', expecting keyword_end ... (http://eval.in/24556)
<yorickpeterse> yeah well....your face is unexpected
<ericwood> l2syntax
<injekt> ENOUGH! EXPELIUS PHPUS
mawueli has joined #ruby-lang
ndrst has joined #ruby-lang
roadt has joined #ruby-lang
vlad_starkov has joined #ruby-lang
kgrz has joined #ruby-lang
vlad_starkov has quit [Ping timeout: 245 seconds]
workmad3 has quit [Ping timeout: 276 seconds]
mistym has joined #ruby-lang
mistym has quit [Changing host]
mistym has joined #ruby-lang
ndrst has quit [Ping timeout: 256 seconds]
pskosinski has joined #ruby-lang
poga has quit [Remote host closed the connection]
_elia has joined #ruby-lang
elia has quit [Ping timeout: 252 seconds]
_elia is now known as elia
pipework has joined #ruby-lang
ndrst has joined #ruby-lang
tsan has joined #ruby-lang
thebastl has joined #ruby-lang
<zzak> good merneng
thebastl has quit [Remote host closed the connection]
aflynn has joined #ruby-lang
<yorickpeterse> what the hell yajl
<yorickpeterse> "unexpected PLT reloc type", keep getting this stuff since a few days
<yorickpeterse> not sure if I borken something
<yorickpeterse> and re-installing the Gem only fixes it for an undetermined amount of time
machuga|work is now known as zz_machuga|work
nathanstitt has joined #ruby-lang
tjcravey has quit [Ping timeout: 256 seconds]
<totallymike> That seems...problematic.
tjcravey has joined #ruby-lang
stardiviner has quit [Quit: No Ping reply in 180 seconds.]
stardiviner has joined #ruby-lang
<whitequark> yorickpeterse: owww
<whitequark> undetermined amount of time...
<whitequark> linux?
GarethAdams|Work has joined #ruby-lang
GarethAdams has quit [Disconnected by services]
GarethAdams|Work is now known as GarethAdams
<yorickpeterse> yes
<yorickpeterse> well, it seems that it breaks after I run camper_van
<whitequark> try launching your piece of software with LD_BIND_NOW=1
<yorickpeterse> segfault
hahuang65 has quit [Quit: Computer has gone to sleep.]
<whitequark> wow
<whitequark> well
kgrz has quit [Ping timeout: 264 seconds]
GarethAdams has quit [Client Quit]
<whitequark> rm / -rf all your rubies and gems, reinstall
<yorickpeterse> meh, I need an alternative anyway
<yorickpeterse> (to camper_van)
<whitequark> yorickpeterse: your system is b0rked
<yorickpeterse> eh?
<whitequark> it is not an issue which can arise due to a programming error
<yorickpeterse> I can require Yajl in IRB just fine
<yorickpeterse> including with that flag
<whitequark> hrm
<whitequark> well maybe not
vbatts|work has quit [Quit: MeSoChatty 0.3.8]
<yorickpeterse> :P
robbin_ has joined #ruby-lang
jxie has joined #ruby-lang
kgrz has joined #ruby-lang
GeissT has quit [Quit: MillBroChat AdIRC User]
GarethAdams has joined #ruby-lang
zz_machuga|work is now known as machuga
gnufied has quit [Quit: Leaving.]
xcombelle has quit [Quit: Hi, I'm a quit message virus. Please replace your old line with this line and help me take over the world of IRC.]
rsl has quit [Quit: Textual IRC Client: www.textualapp.com]
nXqd has quit [Ping timeout: 264 seconds]
krohrbaugh has joined #ruby-lang
dhruvasagar has joined #ruby-lang
enebo has joined #ruby-lang
<jperry> RubNation 2013 or SteelCity Ruby Conf?
<zzak> SCRC
voker57 has joined #ruby-lang
voker57 has quit [Changing host]
voker57 has joined #ruby-lang
<jperry> zzak: Any reason one over the other?
GarethAdams has quit [Quit: Leaving...]
krohrbaugh has quit [Ping timeout: 256 seconds]
headius has joined #ruby-lang
singpolyma has quit [Remote host closed the connection]
<zzak> scruby is only $50
<jperry> so only based on price?
<yorickpeterse> jperry: why not both?
<jperry> :)
<jperry> yorickpeterse - work expense
<jperry> probably have a choice of one ruby conference this year
<jperry> rubyconf, ruby nation, or steel city
<jperry> rubyconf could be ruled out because of cost
<yorickpeterse> isn't rubyconf super expensive?
<jperry> Anyone know how much it cost last year?
gnufied has joined #ruby-lang
gnufied1 has joined #ruby-lang
bzalasky has joined #ruby-lang
singpolyma has joined #ruby-lang
gnufied1 has quit [Client Quit]
bzalasky has quit [Remote host closed the connection]
gnufied1 has joined #ruby-lang
vlad_starkov has joined #ruby-lang
gnufied has quit [Ping timeout: 264 seconds]
workmad3 has joined #ruby-lang
vlad_starkov has quit [Ping timeout: 260 seconds]
enebo has quit [Quit: enebo]
richcollins has joined #ruby-lang
bzalasky has joined #ruby-lang
xcombelle has joined #ruby-lang
jvrmaia has quit [Read error: Connection reset by peer]
jvrmaia has joined #ruby-lang
richcollins has quit [Quit: richcollins]
Rhy0lite has joined #ruby-lang
Rhy0lite has left #ruby-lang ["Leaving"]
erpuds has joined #ruby-lang
jvrmaia has quit [Remote host closed the connection]
mytrile has quit [Remote host closed the connection]
dhruvasagar has quit [Ping timeout: 252 seconds]
vbatts|work has joined #ruby-lang
io_syl has joined #ruby-lang
idkazuma has joined #ruby-lang
dhruvasagar has joined #ruby-lang
stardiviner has quit [Read error: Connection reset by peer]
MaddinXx_ has quit [Remote host closed the connection]
GarethAdams has joined #ruby-lang
aflynn has quit [Quit: Ex-Chat]
levifig has quit [Excess Flood]
benlovell has quit [Ping timeout: 276 seconds]
<yorickpeterse> http://www.businesswire.com/news/home/20130509005108/en/Code-Fellows-Launches-Women-Only-Ruby-Rails-Bootcamp so people will probably hate me for saying this, but isn't the whole "Gender X only" thing a bit of the other end of the spectrum?
levifig has joined #ruby-lang
* yorickpeterse prefers to see people mixed instead of being in their own camps
dhruvasagar has quit [Ping timeout: 256 seconds]
<darix> yorickpeterse: this is discrimination against men
<yorickpeterse> hmmm.....not sure
bzalasky has quit [Remote host closed the connection]
<yorickpeterse> I doubt it's done for the reason "Fuck men!", but I don't believe that gender exclusivity is going to solve the problem of gender bias in IT
tjcravey has quit [Ping timeout: 264 seconds]
tjcravey has joined #ruby-lang
dustint has quit [Ping timeout: 256 seconds]
<Muz> yorickpeterse: just turn up and demand that you identify as being a woman
<Muz> Given that they can't discriminate against those with gender identity issues.
rtl_ has left #ruby-lang [#ruby-lang]
<yorickpeterse> eh, what
levifig has quit [Excess Flood]
<Muz> Certainly works well enough for me in public places when I need a piss and the men's has a queue or is a right state
<Muz> "But I'm transgender"
rtl has joined #ruby-lang
<yorickpeterse> way to miss the point
rue_XIV has left #ruby-lang [#ruby-lang]
<Muz> Way to take satire seriously.
rue has joined #ruby-lang
<rue> yorickpeterse: That’s not the point
<rue> The point is to get comfortable with programming in an environment with less pressure. And /then/ integrate
carloslopes has quit [Remote host closed the connection]
<rue> It’d be great if the ‘less pressure’ part was superfluous, but it unfortunately isn’t.
brettchalupa has joined #ruby-lang
<yorickpeterse> this is probably where my opinion differs, but I don't really believe in this "isolate first then intergrate" idea
<bryanl> I think the help Gender X learn how to program in Y is fine
levifig has joined #ruby-lang
<rue> yorickpeterse: Well, that’s too bad…
<bryanl> I need a help black guy convert ruby into idiomatic scala class as of right now
<yorickpeterse> dat English
<rue> bryanl: Enrolment starting soon!
GarethAdams|Work has joined #ruby-lang
<bryanl> yorickpeterse: also if you are a member of the majority, you might not understand how others who are not like you feel. but that's ok
<yorickpeterse> hold on there for a moment
<rue> bryanl: (Also, secret, there’s no such thing as idiomatic scala yet)
<bryanl> rue: well there's something other than what i'm doing ;)
<yorickpeterse> are you implying that because I'm male there's a chance I don't understand the issue?
<yorickpeterse> or the reason why people organize these kind of e vents?
<yorickpeterse> * events
<bryanl> yorickpeterse: yeah i'm implying that. but i'm not going to defend it anymore past the end of this sentence.
cmckni3 has quit [Quit: Textual IRC Client: www.textualapp.com]
bzalasky has joined #ruby-lang
tylersmith has joined #ruby-lang
<rue> I’m not even sure it’s ‘understand’ (=intellectually) vs. ‘feel’
<yorickpeterse> In that case you're pretty darn far from the truth. I'm well aware of it and understand why people organize these events, I just don't necessarily agree with the means
GarethAdams has quit [Ping timeout: 252 seconds]
<yorickpeterse> as in, "ONLY BOYS/GIRLS/MIX ALLOWED" to me feels like the wrong tool to fix the problem
<rue> It’s not fixing the problem
<rue> It’s helping Group N get into programming
<yorickpeterse> the same applies to attempting to, or to at least make it easier
DEac- has quit [Read error: Connection reset by peer]
<rue> /That/ will help fix the problem.
<yorickpeterse> Take Rails girls for example. They have this women's only thing too but as far as I know they have no problems with men showing up too
<yorickpeterse> nor do they, at least from what I remember, explicitly state "women only"
<rue> It varies, but is discouraged.
cmckni3 has joined #ruby-lang
<yorickpeterse> maybe it's the Dutch Rails girls then, not sure how it's like in other countries
bzalasky has quit [Remote host closed the connection]
<rue> But basically you’d just have to take it on faith that they believe it’s a good way
dankest has joined #ruby-lang
vlad_starkov has joined #ruby-lang
richcollins has joined #ruby-lang
DEac- has joined #ruby-lang
robbin_ has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
vlad_starkov has quit [Ping timeout: 260 seconds]
GarethAdams|Work has quit [Quit: Leaving...]
jovy88 has quit [Read error: Connection reset by peer]
robbyoconnor has joined #ruby-lang
hahuang65 has joined #ruby-lang
jovy88 has joined #ruby-lang
hahuang65 has quit [Client Quit]
My_Hearing has joined #ruby-lang
krohrbaugh has joined #ruby-lang
Mon_Ouie has quit [Ping timeout: 256 seconds]
workmad3 has quit [Ping timeout: 276 seconds]
krohrbaugh has quit [Client Quit]
noop has quit [Ping timeout: 256 seconds]
krohrbaugh has joined #ruby-lang
kgrz has quit [Ping timeout: 256 seconds]
carloslopes has joined #ruby-lang
krz has joined #ruby-lang
nettsundere has quit [Quit: nettsundere]
nXqd has joined #ruby-lang
havenwood has joined #ruby-lang
scuwolf has joined #ruby-lang
_carloslopes has joined #ruby-lang
carloslopes has quit [Read error: Connection reset by peer]
jtoy has joined #ruby-lang
<jtoy> how do i turn an array into a hash where the value all equal 1 and the keys are all values in the array?
<yorickpeterse> [10, 20, 30].each_with_object({}) { |number, hash| hash[number] = 1 }
robbyoconnor has quit [Read error: Connection reset by peer]
<yorickpeterse> something along those lines
<jtoy> something like: Hash.new([1,2 ,3 ,4]) => {1=> 1 2 => 1 3=>1 4=> 1}
QKRTHNU has joined #ruby-lang
<jperry> anyone know how much the tix were for rubyconf 2012?
brettchalupa has quit [Quit: brettchalupa]
cofin has quit [Quit: cofin]
<yorickpeterse> jperry: not exactly, but I recall my CTO saying they were somewhere around 1600 USD
<yorickpeterse> or EUR
<yorickpeterse> but I'm not sure if that's actually the case
<injekt> and the boob contribution: Hash[a.zip(Array.new(a.length){1})]
<yorickpeterse> the what?
<yorickpeterse> also wtf
<yorickpeterse> dat code
<injekt> aye
<jperry> yorickpeterse - thanks
<injekt> boob
<yorickpeterse> does not exist in Urban dictionary, don't make terms up you terrist
<injekt> yorickpeterse: the bad contribution
<yorickpeterse> boobs are bad? :<
<injekt> yorickpeterse: a boob is also used for an idiot, so the boob contribution (mine) was produced by the idiot (me)
machuga is now known as zz_machuga
dhruvasagar has joined #ruby-lang
<injekt> or "an embarrassing mistake or blunder"
<injekt> "I made a boob"
<yorickpeterse> right, you brits are weird with swearing
<injekt> yes us brits are silly
<yorickpeterse> boob, cunt, etc
<injekt> man I hate that word
<yorickpeterse> hey, at least you lot don't use deadly diseases for swearing
<injekt> oh we try
krohrbaugh has quit [Quit: Leaving.]
thebastl has joined #ruby-lang
<yorickpeterse> heh, all these people following me on Twitter and I have no idea who most of them are
<injekt> yorickpeterse: you're a celeb!
Squarepy has joined #ruby-lang
<yorickpeterse> basecam
<yorickpeterse> fuck
<cout> I still don't get twitter
setmeaway has quit [Ping timeout: 245 seconds]
<yorickpeterse> cout << "pfff"
scuwolf has quit [Quit: 离开]
krohrbaugh has joined #ruby-lang
elia has quit [Quit: Computer has gone to sleep.]
headius has quit [Quit: headius]
tenderlove has joined #ruby-lang
<yorickpeterse> Right, time to walk for 30 minutes to get some milk so I can have cereal tomorrow
<yorickpeterse> darn public holidays
<yorickpeterse> DARN NOT HAVING A BIKE BECAUSE IT WAS STOLEN
gnufied1 has quit [Quit: Leaving.]
zz_machuga is now known as machuga
Rhy0lite has joined #ruby-lang
setmeaway has joined #ruby-lang
Rhy0lite has left #ruby-lang ["Leaving"]
pipework is now known as pipewerk
enebo has joined #ruby-lang
krz has quit [Quit: krz]
brianpWins has joined #ruby-lang
setmeaway has quit [Read error: Connection reset by peer]
ndrst has quit [Ping timeout: 256 seconds]
chrishunt has quit [Quit: ZzZzZz...]
vlad_starkov has joined #ruby-lang
setmeaway has joined #ruby-lang
ndrst has joined #ruby-lang
brettchalupa has joined #ruby-lang
vlad_starkov has quit [Ping timeout: 264 seconds]
pkrnj has joined #ruby-lang
tylersmi_ has joined #ruby-lang
adambeynon has quit [Quit: Computer has gone to sleep.]
tylersmith has quit [Ping timeout: 276 seconds]
erpuds has quit [Quit: erpuds]
chrishunt has joined #ruby-lang
mistym is now known as mistym_lunch
vlad_starkov has joined #ruby-lang
Nautes has joined #ruby-lang
thebastl has quit [Remote host closed the connection]
Nautes has quit [Client Quit]
brettchalupa has quit [Quit: brettchalupa]
brettchalupa has joined #ruby-lang
DomKM has joined #ruby-lang
ndrst has quit [Ping timeout: 252 seconds]
ndrst has joined #ruby-lang
<erikh> injekt: you're a boob
<rue> yorickpeterse: Buy moar bike
kgrz has joined #ruby-lang
dustint has joined #ruby-lang
dhruvasagar has quit [Ping timeout: 256 seconds]
benjammin has joined #ruby-lang
<injekt> erikh: <3
<erikh> mr. fartscroll.js
<injekt> you
<erikh> nou
<injekt> butu
jds_ has joined #ruby-lang
retro|cz has quit [Ping timeout: 256 seconds]
kgrz has quit [Ping timeout: 276 seconds]
vbatts|work has quit [Ping timeout: 256 seconds]
<injekt> are there any glassholes in here?
Aloysius1 has joined #ruby-lang
jds has quit [Ping timeout: 260 seconds]
marr has quit [Ping timeout: 252 seconds]
vbatts|work has joined #ruby-lang
marr has joined #ruby-lang
hahuang65 has joined #ruby-lang
idkazuma has quit [Remote host closed the connection]
benlovell has joined #ruby-lang
robbyoconnor has joined #ruby-lang
djbender has joined #ruby-lang
vlad_starkov has quit [Remote host closed the connection]
vlad_starkov has joined #ruby-lang
solars has joined #ruby-lang
vlad_starkov has quit [Read error: Connection reset by peer]
anonymuse has joined #ruby-lang
djbender has left #ruby-lang [#ruby-lang]
djbender has joined #ruby-lang
noop has joined #ruby-lang
__butch__ has joined #ruby-lang
mbj has joined #ruby-lang
machuga is now known as zz_machuga
retro|cz has joined #ruby-lang
barttenbrinke has quit [Remote host closed the connection]
barttenbrinke has joined #ruby-lang
noop has quit [Remote host closed the connection]
djbender has quit [Quit: djbender]
blacktulip has quit [Remote host closed the connection]
vbatts|work has left #ruby-lang ["MeSoChatty 0.3.8"]
barttenbrinke has quit [Ping timeout: 264 seconds]
cofin has joined #ruby-lang
krohrbaugh1 has joined #ruby-lang
djbender has joined #ruby-lang
mbj has quit [Read error: Connection reset by peer]
krohrbaugh1 has quit [Read error: Connection reset by peer]
krohrbaugh2 has joined #ruby-lang
benlovell has quit [Ping timeout: 264 seconds]
krohrbaugh has quit [Ping timeout: 276 seconds]
erpuds has joined #ruby-lang
zz_machuga is now known as machuga
symm- has joined #ruby-lang
rickhull has joined #ruby-lang
mucker has quit [Quit: leaving]
benlovell has joined #ruby-lang
adambeynon has joined #ruby-lang
danrabinowitz has left #ruby-lang ["Linkinus - http://linkinus.com"]
llaskin has joined #ruby-lang
<yorickpeterse> rue: I already bought a new one, but I'm waiting for my tires to be done
<yorickpeterse> standard bike tires are shit and will be flat the moment you drive around in this town
llaskin has left #ruby-lang [#ruby-lang]
breakingthings has quit [Quit: breakingthings]
breakingthings has joined #ruby-lang
richcollins has quit [Quit: richcollins]
xuser has quit [Remote host closed the connection]
megha has joined #ruby-lang
<zzak> is it nap time yet? :(
baba has quit [Ping timeout: 252 seconds]
mistym_lunch is now known as mistym
<rue> zzak: Yes
nettsundere has joined #ruby-lang
saarinen has joined #ruby-lang
<zzak> rue z_z
<matti> zzak: ;]
dustint has quit [Ping timeout: 255 seconds]
richcollins has joined #ruby-lang
dustint has joined #ruby-lang
headius has joined #ruby-lang
amerine has quit [Ping timeout: 264 seconds]
vlad_starkov has joined #ruby-lang
richcollins has quit [Quit: richcollins]
kirin` has quit [Ping timeout: 245 seconds]
kstuart1 has quit [Quit: kstuart1]
QKRTHNU has quit [Quit: has digitaly disappeared.]
kirin` has joined #ruby-lang
thebastl has joined #ruby-lang
amerine has joined #ruby-lang
Nisstyre-laptop has joined #ruby-lang
athaeryn has joined #ruby-lang
<athaeryn> why is ruby telling me there's duplicated range in this regex? [^+-<>,.\[\]]
postmodern has joined #ruby-lang
vlad_starkov has quit [Ping timeout: 276 seconds]
sush24 has quit [Quit: This computer has gone to sleep]
erpuds has quit [Ping timeout: 252 seconds]
djbender has quit [Quit: djbender]
nXqd has quit [Ping timeout: 268 seconds]
geson has quit [Quit: Leaving.]
robbyoconnor has quit [Ping timeout: 256 seconds]
heftig has quit [Ping timeout: 245 seconds]
MaddinXx has joined #ruby-lang
djbender has joined #ruby-lang
<zzak> ZOMG
<apeiros> athaeryn: it does?
<apeiros> >> /[^+-<>,.\[\]]/
<eval-in> apeiros => /[^+-<>,.\[\]]/ (http://eval.in/24702)
<apeiros> doesn't here…
<yorickpeterse> 19>> /[^+-<>,.\[\]]/
<eval-in> yorickpeterse => /[^+-<>,.\[\]]/ (http://eval.in/24703)
<yorickpeterse> hm
<yorickpeterse> quite
<athaeryn> I'm getting "character class has duplicated range: /[^+-<>,.\[\]]/"
mucker has joined #ruby-lang
<athaeryn> I'm using Syntastic in vim, maybe the error is because it's using a weird syntax checker?
cofin has quit [Quit: cofin]
<yorickpeterse> Aah, eval.in doesn't run with -W2 I believe
<yorickpeterse> Syntastic does
<yorickpeterse> don't remember exactly what the error means though
ndrst has quit [Ping timeout: 245 seconds]
dustint has quit [Ping timeout: 264 seconds]
<athaeryn> hmmm..
cout has quit [Read error: Operation timed out]
ryez has quit [Ping timeout: 245 seconds]
voker57 has quit [Read error: Connection reset by peer]
cout has joined #ruby-lang
tenderlove has quit [Remote host closed the connection]
pskosinski_ has joined #ruby-lang
totallymike has quit [Quit: WeeChat 0.4.0]
timepilot has joined #ruby-lang
pskosinski has quit [Ping timeout: 245 seconds]
timepilot has quit [Client Quit]
timepilot has joined #ruby-lang
<apeiros> I think +-< does not what you want :)
<apeiros> +\<
yalue has quit [Ping timeout: 252 seconds]
<apeiros> +\-<
<apeiros> @ athaeryn & yorickpeterse
<yorickpeterse> hmm
<yorickpeterse> HMMM
<yorickpeterse> hm hm
pskosinski_ has quit [Client Quit]
<athaeryn> that got rid of the warning. things were working before despite the warning, and work with the
<athaeryn> \-
<yorickpeterse> but yeah, that might be it
<athaeryn> what's going on there?
* yorickpeterse is stalking his Twitter stalkers to see why they're stalking him
<apeiros> +-< is a range
<apeiros> like a-z
Nisstyre-laptop has quit [Quit: Leaving]
<yorickpeterse> >> 'hello + foo-'.scan /+-</
<eval-in> yorickpeterse => /tmp/execpad-ab93157c7fcb/source-ab93157c7fcb:2: target of repeat operator is not specified: /+-</ (http://eval.in/24715)
<yorickpeterse> eeehhhh wat
* yorickpeterse needs tea
<yorickpeterse> lots of it
timepilot has quit [Client Quit]
dustint has joined #ruby-lang
krohrbaugh2 has quit [Quit: Leaving.]
xcombelle has quit [Read error: Connection reset by peer]
henrikhodne has joined #ruby-lang
pkrnj has quit [Quit: Computer has gone to sleep.]
<canton7> + is the repeat operator, before you even get near the range
dingus_khan has joined #ruby-lang
<athaeryn> canton7: what does it do when there's nothing before it?
<canton7> error, apparently
<dingus_khan> can someone explain to me why or how it's possible to use #send without using a symbol name? ruby-docs doesn't mention that scenario...
<athaeryn> canton7: well it worked as i expected, it just gave me a warning..
<yorickpeterse> >> def test; "TEST"; end; send("test")
<eval-in> yorickpeterse => "TEST" (http://eval.in/24716)
<canton7> looks like it works in []
<yorickpeterse> dingus_khan: ^
<yorickpeterse> you can use strings just fine
<athaeryn> canton7: interesting..
<dingus_khan> really...? Why doesn't it say that anywhere? I mean I see that in practice, but no explanations on how just passing it arguments works, or how it even works that way...
<yorickpeterse> not sure, but you can use basically anything that responds to #to_sym I believe (lets find out!)
<yorickpeterse> >> class Derp; def to_sym; "test"; end; end; def test; "TESTING"; end; send(Derp.new)
<eval-in> yorickpeterse => /tmp/execpad-28a851e9b54d/source-28a851e9b54d:2:in `<main>': #<Derp:0x41891318> is not a symbol (TypeError) (http://eval.in/24717)
<yorickpeterse> heh
<yorickpeterse> fucking MRI
forrest has joined #ruby-lang
<yorickpeterse> so no, String and Symbol only
<canton7> the docs say Object#send takes a string or a symbol as the first arg
<rickhull> what's the "right way" to bootstrap the load path? https://gist.github.com/rickhull/5549932
cstrahan has joined #ruby-lang
<dingus_khan> hmmm...
<rickhull> i've used RUBYLIB in the past
<canton7> rickhull, strictly? use ruby -I . You see a lot of people doing something like $LOAD_PATH << File.dirname(__FILE__)
<canton7> (though I think ruby 2.0 has __dir__ now?)
<rickhull> inside every bin/foo.rb?
MaddinXx has quit [Remote host closed the connection]
<canton7> inside lib/foo.rb
<canton7> so the one that other people (or your bin) include
jonahR has joined #ruby-lang
<rickhull> so bin/foo.rb must: require '../lib/foo' ?
<canton7> or yeah, probably needs it in bin/foo.rb as well
<canton7> or call bin/foo.rb as ruby -I lib/ bin/foo.rb
<rickhull> er, sorry, bin/do_foo.rb :)
<canton7> it doesn't matter when it's packaged as a gem - rubygems sorts out the LOAD_PATH
<rickhull> yes, that is a major (undiscussed) part of my question
<rickhull> i don't have much experience with gem authorship, but that's what i'm wanting to get right. have it work for dev and deployed
Psy-X has joined #ruby-lang
<canton7> yeah rubygems adds your lib/ to LOAD_PATH (or some other equivalent, I can't remember)
mawueli has quit [Remote host closed the connection]
Psy-X has quit [Read error: Connection reset by peer]
tonni has joined #ruby-lang
<rickhull> but so then i've got this bootstrap problem only in dev?
<canton7> aye
<rickhull> or just use RUBYLIB in dev
<rickhull> is there a reference or tutorial for this? i reviewed the rubygems manual
benlovell has quit [Quit: leaving]
<canton7> about a hundred and one SO answers irrc
<canton7> *iirc
<rickhull> i mean, they give you some very local tricks
<rickhull> but not necessarily in the context of gem authorship and the difference between dev and deployed
<rickhull> and i've not seen much advocacy of RUBYLIB, e.g.
<rickhull> what about including things like bundler/setup — should that be done within a gem?
<rickhull> s/include/require/
nmeum1 has left #ruby-lang [#ruby-lang]
jonahR has quit [Quit: jonahR]
srbaker has quit [Quit: Textual IRC Client: www.textualapp.com]
mbj has joined #ruby-lang
<rickhull> it says: inside your app, load up the bundled environment: require 'rubygems'; require 'bundler/setup'
vlad_starkov has joined #ruby-lang
io_syl has quit [Ping timeout: 276 seconds]
<rickhull> but i could have sworn there was a big thing going around a few years ago: DO NOT require 'rubygems'
io_syl has joined #ruby-lang
<canton7> rickhull, you only need to require 'rubygems' in ruby 1.8
<erikh> well, since 1.9 it's less of a choice
<canton7> ..which is going out of support really rather shortly
<erikh> and in 1.8, you were supposed to do it with a loaderror rescue
<erikh> but most rails wanks ignored that
<rickhull> i'm just really fuzzy on the big picture here
<canton7> in 1.8, rubygems wasn't built into ruby, as it were
<canton7> you had to include it explicitely
<canton7> come 1.9, and it's so useful that you get it for free
<rickhull> why is the bundler front page telling me to do that?
krohrbaugh has joined #ruby-lang
<canton7> so no explicit requires requires
<rickhull> wycats__: ^^
<canton7> probably because there's no real hamr in 1.9, and just saying 'always require rubygems' covers all cases with minimal confusion
<canton7> *requires required
vlad_starkov has quit [Ping timeout: 272 seconds]
<rickhull> so the big thing a few years ago about "don't require rubygems" is now obsolete?
<rickhull> i.e. inside your open source projects
adambeynon has quit [Quit: Computer has gone to sleep.]
<erikh> you shouldn't have to require it at all in 1.9+
<rickhull> ok, that is the world i'm living in now
<rickhull> is it best pratice to then require 'bundler/setup'? why doesn't thor do that?
<rickhull> for example...
<erikh> no
<erikh> use bundle exec.
<erikh> there are a few instances where it makes sense, but usually it's a great way to get the wrong binstub loading for bundler
<rickhull> is there somewhere this is laid out in detail?
<erikh> ... sadly I doubt it.
<erikh> I've been meaning to write a blag on how gem activation works
* rickhull shakes fist
cofin has joined #ruby-lang
<erikh> maybe I'll just deal with that then
<erikh> drbrain: btw, when I write that (probably in a week or so), if you don't mind proofreading it for facts and stuff I'll give you a big smelly smoker hug next time I see you
krohrbaugh has quit [Ping timeout: 264 seconds]
krohrbaugh has joined #ruby-lang
<rickhull> erikh: can you give some more detail on why, for example, thor has no references to bundler in the source code, yet the bundler docs all show examples of require'ing various bundler things
<rickhull> wycats__: or maybe you can?
<rickhull> maybe not why, so much. more interested in how. i'm working with a new codebase and trying to debug some require/LOAD_PATH/require_relative things. and bundler is involved
<rickhull> it's clear to me the require structure is kind of fucked, but i'm unclear on what might be wrong or what is the sane way to handle it
richcollins has joined #ruby-lang
<dingus_khan> tell me why for loops are bad. go.
<rickhull> you have to manage the loop internals yourself
<rickhull> :p
<rickhull> are the questions i'm asking a sore point, or am i just being really obtuse, or?
<erikh> rickhull: not really
<canton7> dingus_khan, no advantage over #each, and you get some weird scoping
<erikh> just busy atm
<rickhull> erikh: FIX IT FOR ME NOW
<erikh> give me about an hour -- i'll give you some detailed explanation
<rickhull> you da man <3
<erikh> I need to formalize this for the blag anyhow
<dingus_khan> thanks rickhull and canton7!
<canton7> iirc for uses #each internally anyway
<dingus_khan> I'll need to investigate what is meant by weird scoping some more, but thanks for at least giving me some kind of answer on that one
priodev has quit [Ping timeout: 245 seconds]
symm- has quit [Read error: Connection reset by peer]
symm- has joined #ruby-lang
symm- has quit [Read error: Connection reset by peer]
<wycats__> The rationale document on gembundler.com isn't bad, depending on what you're trying to find out
pkrnj has joined #ruby-lang
benanne has quit [Quit: kbai]
<rickhull> wycats__: do you develop thor using bundler? why don't i see it in the source code?
symm- has joined #ruby-lang
Jinie has joined #ruby-lang
tenderlove has joined #ruby-lang
<rickhull> i mean, i have an inkling of the rationale that bundler shouldn't be embedded in the source code, but that goes against the docs i'm reading at gembundler.com
_carloslopes has quit [Remote host closed the connection]
<wycats__> You use bundler in your APP code
<wycats__> But library code shouldn't care how it got on the load path
<rickhull> ok, in my case, it's mostly library code, but the project does have some services it wants to kick off
<rickhull> and right now, we have require Pathname.new(__FILE__).realdirpath + '../../vendor/bundle/bundler/setup'
<rickhull> in the bootstrap library stuff
<rickhull> i.e. every library file pulls this in
<rickhull> qq: in my mind, there is lib code, and executables. (i.e. in the bin/ subdir) is there anything ~more~ meant by "app code"
<rickhull> outside of web apps, say
<rickhull> i'm fundamentally doing lib development, but with tons of dependencies (that I'd like to whittle down eventually)
ikrima has quit [Ping timeout: 260 seconds]
ikrima has joined #ruby-lang
tenderlo_ has joined #ruby-lang
user64 has joined #ruby-lang
<drbrain> erikh: sure, but I can skip the hug
tenderlove has quit [Ping timeout: 260 seconds]
<erikh> drbrain: heh
megha is now known as baba
<erikh> rickhull: so, the problem is subtle for binstubs
<erikh> but gem install thor -v 1.2.3, then put gem thor 1.2.4 in your gemfile
swav has quit [Remote host closed the connection]
<erikh> well, not thor. use rake, it's a little easier to show this with
<erikh> but the point is, when you run "rake foo" and your rakefile has require "bundler/setup", and you have rake in your Gemfile..
<erikh> the non-bundled gem will be activated, then it loads the rakefile, then it loads bundler, and then bundler tries to activate the *other* rake
<rickhull> i was just using thor as an example, because i went there for an example of what to do
<erikh> which creates a conflict, and everything shits itself
<erikh> if you use "bundle exec rake", this isn't an issue
chessguy has joined #ruby-lang
<erikh> because bundler gets to activate first. dig?
<rickhull> that makes sense. i asked around over here and got a better explanation of what i'm dealing with
<rickhull> and the Pathname bundler realdirpath stuff is a hacky workaround
<erikh> I'll let you know when the gem activation article is done
<rickhull> cool, i'm still quite interested
<erikh> probably in the next day or two, been meaning to write it for a while now
<erikh> rickhull: btw, we'll be meeting next thursday
<erikh> re: other things
<rickhull> yeah, it's on my calendar :)
<rickhull> also this saturday right?
<erikh> next saturday
user64 has left #ruby-lang [#ruby-lang]
<rickhull> ok right
<erikh> although, I'm going to be in SF friday night for beers I think
<erikh> interested?
<erikh> in the mission
<rickhull> sure, ping me
<erikh> will do
nXqd has joined #ruby-lang
carloslopes has joined #ruby-lang
havenwood has quit [Remote host closed the connection]
cofin has quit [Quit: cofin]
robbyoconnor has joined #ruby-lang
wallerdev has quit [Quit: wallerdev]
alessio_rocco has quit [Remote host closed the connection]
priodev has joined #ruby-lang
<rue> Hippies
tenderlo_ has quit [Ping timeout: 268 seconds]
mbull9 has joined #ruby-lang
<erikh> rue: hip*sters*, sir.
carloslopes has quit [Remote host closed the connection]
jonahR has joined #ruby-lang
TheNotary has joined #ruby-lang
saarinen has quit [Quit: saarinen]
machuga is now known as machuga|brb
machuga|brb is now known as machuga
machuga is now known as machuga|brb
athaeryn has left #ruby-lang [#ruby-lang]
machuga|brb is now known as zz_machuga|brb
saarinen has joined #ruby-lang
Mapleh has quit []
cofin has joined #ruby-lang
robbyoconnor has quit [Max SendQ exceeded]
robbyoconnor has joined #ruby-lang
TheNotary has quit [Quit: Leaving]
scampbell has quit [Remote host closed the connection]
kstuart has joined #ruby-lang
ndrst has joined #ruby-lang
dingus_khan has quit [Ping timeout: 255 seconds]
thebastl has quit [Read error: Connection reset by peer]
thebastl has joined #ruby-lang
krombr has joined #ruby-lang
thebastl has quit [Remote host closed the connection]
retro|cz has quit [Read error: Operation timed out]
nXqd has quit [Remote host closed the connection]
SiliconDon has joined #ruby-lang
djbender has quit [Quit: djbender]
dingus_khan has joined #ruby-lang
zz_machuga|brb is now known as machuga
retro|cz has joined #ruby-lang
cstrahan_ has joined #ruby-lang
cstrahan has quit [Ping timeout: 264 seconds]
totallymike has joined #ruby-lang
wmoxam has quit [Ping timeout: 256 seconds]
pipewerk has quit [Remote host closed the connection]
tenderlove has joined #ruby-lang
robbyoconnor has quit [Ping timeout: 272 seconds]
thebastl has joined #ruby-lang
dustint has quit [Read error: Operation timed out]
singpolyma has quit [Ping timeout: 245 seconds]
brettchalupa has quit [Quit: brettchalupa]
Jinie has quit [Quit: Computer has gone to sleep.]
chessguy has quit [Remote host closed the connection]
tsan has left #ruby-lang [#ruby-lang]
swav has joined #ruby-lang
jovy88 has quit [Read error: Connection reset by peer]
pskosinski has joined #ruby-lang
dankest has quit [Read error: Connection reset by peer]
jovy88 has joined #ruby-lang
swav has quit [Ping timeout: 264 seconds]
saarinen has quit [Quit: saarinen]
symm- has quit [Ping timeout: 272 seconds]
saarinen has joined #ruby-lang
<dingus_khan> fart
Jinie has joined #ruby-lang
Jinie has quit [Client Quit]
saarinen has quit [Client Quit]
swav has joined #ruby-lang
chessguy has joined #ruby-lang
machuga is now known as machuga|away
mbull9 has quit [Remote host closed the connection]
rdg has joined #ruby-lang
DomKM has quit [Quit: Leaving.]
mrfelix has joined #ruby-lang
SiliconDon has quit [Quit: SiliconDon]
thone_ has joined #ruby-lang
mistym has quit [Remote host closed the connection]
wallerdev has joined #ruby-lang
kstuart has quit [Quit: kstuart]
thone has quit [Ping timeout: 264 seconds]
cstrahan_ has quit [Ping timeout: 255 seconds]
Squarepy has quit [Quit: Leaving]
breakingthings has quit [Quit: breakingthings]
anonymuse has quit [Quit: Linkinus - http://linkinus.com]
mbj has quit [Ping timeout: 252 seconds]
xxaM has quit [Read error: Connection reset by peer]
vlad_starkov has joined #ruby-lang
xxaM has joined #ruby-lang
solars has quit [Read error: Operation timed out]
rdg has quit [Quit: [quit]]
xxaM has quit [Read error: Connection reset by peer]
elia has joined #ruby-lang
vlad_starkov has quit [Ping timeout: 252 seconds]
snafoo has quit []
intellitech has quit [Quit: intellitech]
forrest has quit [Quit: Leaving]
richcollins has quit [Quit: richcollins]
xxaM has joined #ruby-lang
saarinen has joined #ruby-lang
richcollins has joined #ruby-lang
sailias has quit [Ping timeout: 245 seconds]
nathanstitt has quit [Quit: I growing sleepy]
mistym has joined #ruby-lang
mistym has quit [Changing host]
mistym has joined #ruby-lang
enebo has quit [Quit: enebo]
setmeaway has quit [Ping timeout: 245 seconds]
chessguy has quit [Remote host closed the connection]
slash_nick has joined #ruby-lang
DomKM has joined #ruby-lang
danrabinowitz has joined #ruby-lang
<dingus_khan> nothing?
idkazuma has joined #ruby-lang
<erikh> fart
<dingus_khan> mmm, quite so
thebastl has quit [Remote host closed the connection]
<erikh> gistit is the magical sexy new gist tool right?
<dingus_khan> read that as "jizz-tit", not gonna lie
<erikh> eh
<erikh> you might want to curb the dirty jokes in here
<dingus_khan> I don't come up with these names, it's not my fault!
<erikh> gist is a word
<dingus_khan> and now so is gistit apparently
<erikh> hmm
<dingus_khan> see what I'm sayin'
<erikh> irc is turning me into the hulk today, apparently
<erikh> bbl
<dingus_khan> hulk smash
davpoind has joined #ruby-lang
davpoind has left #ruby-lang [#ruby-lang]
mbull9 has joined #ruby-lang
pipewerk has joined #ruby-lang
mrfelix has quit [Quit: Computer has gone to sleep.]
wmoxam has joined #ruby-lang
slash_nick has quit [Quit: leaving]
agarie has joined #ruby-lang
Criztian has joined #ruby-lang
<apeiros> erikh angry?
cofin has quit [Quit: cofin]
Criztian has quit [Remote host closed the connection]
<dingus_khan> wasn
<dingus_khan> 't me I swear
<dingus_khan> stupid enter
kith has quit [Read error: Connection reset by peer]
kith has joined #ruby-lang
brettchalupa has joined #ruby-lang
ndrst has quit [Ping timeout: 260 seconds]
chessguy has joined #ruby-lang
pkrnj has quit [Quit: Computer has gone to sleep.]
ndrst has joined #ruby-lang
benanne has joined #ruby-lang
mrfelix has joined #ruby-lang
brianpWins has quit [Quit: brianpWins]
wmoxam has quit [Ping timeout: 252 seconds]
yfeldblum has quit [Ping timeout: 252 seconds]
__butch__ has quit [Quit: Leaving.]
mrfelix has quit [Quit: Computer has gone to sleep.]
tomzx_mac has joined #ruby-lang
saarinen has quit [Quit: saarinen]
idkazuma has quit [Remote host closed the connection]
krohrbaugh has quit [Quit: Leaving.]
jonahR has quit [Quit: jonahR]
yfeldblum has joined #ruby-lang
elia has quit [Quit: Computer has gone to sleep.]
vlad_starkov has joined #ruby-lang
pkrnj has joined #ruby-lang
totallymike has quit [Ping timeout: 268 seconds]
Nisstyre-laptop has joined #ruby-lang
tenderlove has quit [Remote host closed the connection]
io_syl has quit [Ping timeout: 268 seconds]
chessguy has quit [Remote host closed the connection]
vlad_starkov has quit [Ping timeout: 272 seconds]
hahuang65 has quit [Quit: Computer has gone to sleep.]
sepp2k1 has joined #ruby-lang
sepp2k has quit [Ping timeout: 245 seconds]
Lennier has joined #ruby-lang
goldfax has joined #ruby-lang
jonahR has joined #ruby-lang
wmoxam has joined #ruby-lang
jonahR has quit [Client Quit]
chessguy has joined #ruby-lang
singpolyma has joined #ruby-lang
hahuang65 has joined #ruby-lang
hahuang65 has quit [Client Quit]
krohrbaugh has joined #ruby-lang
brettchalupa has quit [Quit: brettchalupa]
nathanstitt has joined #ruby-lang
ergo has joined #ruby-lang
dingus_khan has quit [Ping timeout: 272 seconds]
Lennier has quit [Quit: Lennier]
dankest has joined #ruby-lang
krohrbaugh has quit [Ping timeout: 264 seconds]
sailias has joined #ruby-lang
wmoxam has quit [Ping timeout: 248 seconds]