<Solnse>
it's not 'populating' the hash... but merely leaving the last value pair... params: {"input"=>"Sign In (Secure)"}
<RubyPanther>
documentation is for the weak
Hanmac1 has joined #ruby
instantaphex has joined #ruby
red234324 has quit [Quit: Leaving]
<crucify_me>
yeah pontiki thank you makes sense.
momigi has quit [Remote host closed the connection]
atraylen has joined #ruby
blueOxigen has quit [Ping timeout: 276 seconds]
Hanmac has quit [Ping timeout: 240 seconds]
omosoj has quit [Ping timeout: 240 seconds]
<pontiki>
hum... solnse, Hash doesn't have a push method AFAIK...
pskosinski has quit [Ping timeout: 272 seconds]
<crucify_me>
'metaclass = class << matz' yeah for a second I thought metaclass was a keyword not a pointer, adding confusion
havenwood has joined #ruby
oddie has quit [Ping timeout: 240 seconds]
dayepa has joined #ruby
<Solnse>
pontiki, thanks I figured it out, I need to use input['name'] instead of input.name
klaut has quit [Remote host closed the connection]
supermarin has joined #ruby
aspires has quit []
oddie has joined #ruby
ezrios has quit [Disconnected by services]
aspires has joined #ruby
supermarin has quit [Ping timeout: 240 seconds]
everett has joined #ruby
bogeyd6 has joined #ruby
<pontiki>
oh, rigthy! soz
senayar has joined #ruby
nfk has quit [Quit: yawn]
aspires has quit [Client Quit]
pwh has quit []
funburn has quit [Ping timeout: 252 seconds]
michaeldeol has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
funburn has joined #ruby
atraylen has quit [Read error: Connection reset by peer]
fgo has joined #ruby
jtdowney has quit []
SilkFox has joined #ruby
blueOxigen has joined #ruby
yfeldblum has quit [Read error: Connection reset by peer]
yfeldblum has joined #ruby
anaeem1_ has quit [Read error: Connection reset by peer]
KanKava has quit [Ping timeout: 276 seconds]
anaeem1 has joined #ruby
robbyoconnor has joined #ruby
bluOxigen has quit [Ping timeout: 240 seconds]
benzrf is now known as benzrf|offline
<crucify_me>
hi on the same program, I commented out line 10, and got an error. Won't 'class << matz' be sufficient to indicate self? (since matz = Object.new creates the 'hidden' metaclass) http://pastie.org/9140845
<crucify_me>
havenwood: put differently, line 10 'self' is returning matz's metaclass or singleton status, which includes all Class methods along with #speak.
dayepa has quit [Ping timeout: 240 seconds]
chrisseaton has joined #ruby
eflynn has quit [Ping timeout: 250 seconds]
dr0ff has joined #ruby
supermarin has quit [Ping timeout: 245 seconds]
endash has quit [Quit: endash]
zz_karupa is now known as karupa
<havenwood>
crucify_me: terminology isn't right, but i think your understanding is
amclain has quit [Quit: Leaving]
centipedefarmer has joined #ruby
supermarin has joined #ruby
robustus has quit [Ping timeout: 252 seconds]
bluOxigen has quit [Ping timeout: 252 seconds]
RaptorJesus_ has quit [Quit: Leaving]
<crucify_me>
havenwood: thank you . more possible drama soon.
s2013 has quit [Ping timeout: 240 seconds]
<crucify_me>
many thanks ^
RaptorJesus has joined #ruby
momigi has joined #ruby
robustus has joined #ruby
vivmbbs has joined #ruby
vivmbbs has quit [Client Quit]
penzur has joined #ruby
jtdowney has joined #ruby
RaptorJesus has quit [Remote host closed the connection]
supermarin has quit [Ping timeout: 252 seconds]
crzrcn has quit [Quit: Leaving.]
decoponio has joined #ruby
danshultz has quit [Remote host closed the connection]
RaptorJesus has joined #ruby
eflynn has joined #ruby
centipedefarmer has quit [Ping timeout: 265 seconds]
x1337807x has joined #ruby
danshultz has joined #ruby
mr_snowf1ake has quit [Ping timeout: 258 seconds]
momigi has quit [Ping timeout: 245 seconds]
Es0teric has quit [Quit: Computer has gone to sleep.]
kotk has quit [Remote host closed the connection]
freerobby has joined #ruby
kotk has joined #ruby
danshultz has quit [Ping timeout: 264 seconds]
phoo1234567 has quit [Remote host closed the connection]
failshell has quit []
fayesal has joined #ruby
Milly_Bays has joined #ruby
arrubin has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
<fayesal>
There seems to be a bug in ruby's stdlib zlib GZipWriter class. You cannot give an mtime of 0 - it is replaced with the current time. Can there be a better default like nil which has that effect, leaving 0 to be usable as 0?
IceDragon has quit [Ping timeout: 276 seconds]
ddv has quit [Ping timeout: 245 seconds]
MatthewsFace has quit [Quit: This computer has gone to sleep]
<fayesal>
I need to create gzip files with 0'd out mtime.
omosoj has joined #ruby
<centrx>
How about 1?
Hanmac has joined #ruby
Virtualize has joined #ruby
proxie has joined #ruby
ddv has joined #ruby
Hanmac1 has quit [Ping timeout: 264 seconds]
crucify_me has quit []
caleb_io has joined #ruby
centrx has quit [Quit: All this computer hacking is making me thirsty]
trhodes_ has quit [Ping timeout: 264 seconds]
jonno11 has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
bthesorceror has joined #ruby
crucify_me has joined #ruby
absolutezeroff has joined #ruby
trhodes_ has joined #ruby
caleb_io has quit [Client Quit]
supermarin has joined #ruby
ari-_-e has joined #ruby
<fayesal>
centrx: 1 creates 1. not 0.
<ari-_-e>
if I reference instance data in a Rakefile, what exactly is the "instance" in that case?
seaned has quit [Quit: Zzzzzz....]
bthesorceror has quit [Remote host closed the connection]
apeiros_ has quit [Remote host closed the connection]
<crucify_me>
havenwood: well, my confusion is simple. Why isn't metaclass = 'class << matz' sufficient, why does it have to be in the form of a block when the matz singleton class is given assignment?
<jblack>
that with a couple keywords always works for me. ;)
ericmathison has quit [Ping timeout: 252 seconds]
flapenguin has quit [Remote host closed the connection]
<popl>
The problem with that, jblack, is that any idiot who can get ranked higher on Google will draw the novice's attention.
<popl>
Isn't that antithetical to the goal of helping people learn good Ruby practices?
<jblack>
Hey, if you want make a nice curated list, go for it. That would be awesome. Most people gave up on that a decade ago.
michaeldeol has joined #ruby
<popl>
Why?
<popl>
Is there an old copy of a tutorial list then?
matcouto has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<popl>
I'd be interested in seeing it.
<jblack>
In general? Because, like panther said, it's too hard to maintain and keep up to date.
<popl>
It's not too hard.
<popl>
The Perl people do it.
matcouto has joined #ruby
<popl>
The Bash people do it.
heftig has joined #ruby
<Solnse>
sound like you found your project.
<Senjai>
Come now, do perl and bash ever REALLLLYY change?
<popl>
Yeah, I'm not going to get into a Perl discussion. The point is that it's not difficult.
<jblack>
they could invent a way to use ... hmmm, they did run out of characters in perl... didn't they
<Solnse>
lol
sdouglas has joined #ruby
mikey__ has quit [Ping timeout: 240 seconds]
<Senjai>
popl: Do you know what else isn't difficult? Using the googlez
<popl>
Your language prejudice is your issue. :P
<Senjai>
popl: I love perl and bash
<popl>
Whatever.
s2013 has joined #ruby
<popl>
That's like saying "I'm not racist, but…".
<RubyPanther>
Perl tried to change, but they refused to use their own changes.
<popl>
Nothing following that phrase is ever good.
<Solnse>
and you're failing at taking the high road.
<jblack>
Hey, if you like perl, more power to ya. =) There's a great many useful things to use with it.
supermarin has joined #ruby
mikepack has quit [Remote host closed the connection]
<RubyPanther>
"If you want to do everything using object-oriented programming then Ruby is a better language than Perl" -- Saint Wall
agjacome has quit [Ping timeout: 255 seconds]
popl has left #ruby [#ruby]
<jblack>
yay. language wars.
mikepack has joined #ruby
matcouto has quit [Ping timeout: 250 seconds]
<RubyPanther>
I think Larry Wall's point was that different languages aren't at war, they just have a different focus. He followed that statement with a defense of procedural programming.
Alina-malina has quit [Ping timeout: 240 seconds]
<RubyPanther>
If you decide which language you want to use before you decide which style of structure you want, the cart might be in front of the horse
sski has joined #ruby
<jblack>
Larry's always been deeply pragmatic.
havenwood has joined #ruby
<jblack>
His whole mantra is that there's more than one way to do it.
zcreative has quit [Quit: Computer has gone to sleep.]
<RubyPanther>
I'm not convinced, I think his position is based on a deeply-held principle rather than any pragmatism.
Hanmac has quit [Read error: Connection reset by peer]
<RubyPanther>
More than one way is based on natural language principles, not pragmatism
pu22l3r has joined #ruby
supermarin has quit [Ping timeout: 240 seconds]
<havenwood>
In other news, Perl6 seems quite nice. You can see Ruby's influence.
mjsmith2 has quit [Remote host closed the connection]
<jblack>
I don't pragmatisim isn't quite an anti-principle.
<jblack>
pardon I don't think it's quite an anti-principle.
Hanmac has joined #ruby
<RubyPanther>
havenwood: Yeah, I'd been waiting for Perl 6 for 5 years when I switched to Ruby...
mikepack has quit [Ping timeout: 245 seconds]
<RubyPanther>
That was 10 years ago. I think it is safe to say by now that Perl hackers refuse to use 6. ;)
<jblack>
It takes a great deal of effort to concurrently grok multiple possiblities.
<havenwood>
RubyPanther: It's not like Python 3 where it's a stable release though and folks still refuse to switch. *Soon!* :P
<RubyPanther>
Yeah, I'd argue that taking Ideological Orthogonality to the next level is what makes Perl 6 _unusable_
<havenwood>
RubyPanther: Personally I'd have called it by a new name rather than a major version bump.
TripTastic has joined #ruby
<RubyPanther>
havenwood: I don't know about Python 3 at all, but the only reason Perl 6 couldn't get to a stable release is that they couldn't get it to a point anybody was willing to use
<jblack>
you're so biased against unreadable languages. :P
NukePuppy has joined #ruby
jtz has joined #ruby
jtz has joined #ruby
jtz has quit [Changing host]
<Senjai>
jblack: what languages are unreadable?
TripTastic has left #ruby [#ruby]
<havenwood>
RubyPanther: I guess we'll see if things change now that a few of the VMs are almost feature complete?: http://perl6.org/compilers/features
nanoyak has joined #ruby
<havenwood>
RubyPanther: Can hardly fault people for not switching to a lang until at least one VM implements it.
<RubyPanther>
Perl 6 was destined to fail, because it was "the community's rewrite" of the language, and the language was based on deep linguistics theory, on the principles of natural language. That sort of advanced, theory-based system is going to be totally destroyed by a committee, even a committee of experts. It needs AN expert.
JasmeetQA has joined #ruby
<jblack>
Senjai: It's not the languages themselves. Most any language can be written in cleanly.....
<RubyPanther>
havenwood: In 2004 there was already a VM that had implemented most of it and had been in use for _years_
<havenwood>
RubyPanther: doesn't Larry Wall maintain the Perl6 reference grammar and work on it primarily?
<jblack>
but how likely is it that one will write code that they can't themselves read? That's an important, though hard to read metric.
<RubyPanther>
havenwood: Yeah, but his role was only to fix the community's contributions
<havenwood>
RubyPanther: hem, i thought it was more involved
funburn has joined #ruby
<RubyPanther>
No, he was really clear about that "back in the day." He said that Perl 5 was his rewrite of Perl 4, and Perl 6 was the community's rewrite. He was involved as a filter, but it was 100% community-driven
jtdowney has quit []
Burgestrand has quit [Quit: Burgestrand]
Es0teric has quit [Remote host closed the connection]
davispuh has quit [Remote host closed the connection]
Burgestrand has joined #ruby
<RubyPanther>
It started with the RFC's which had Larry totally staying hidden, the community had to come up with what they wanted to be different, he didn't explain what we should want or why we should want it. then... "The Bad part was that I was supposed to take these RFCs and produce a coherent design in two weeks. ... It is now five months later, and I've been mulling over coherence the whole time, for some definition of mulling." --- Larry W
<RubyPanther>
all 2001
pu22l3r has quit [Remote host closed the connection]
NukePuppy has quit [Ping timeout: 265 seconds]
trhodes_ has quit [Ping timeout: 264 seconds]
crystal77 has quit [Quit: Computer has gone to sleep.]
mgv has joined #ruby
nanoyak has quit [Quit: Computer has gone to sleep.]
<havenwood>
RubyPanther: Well, I look forward to checking it out when they have it finished one of these Christmases.
<pontiki>
we shall all see a rebirth and the 6th coming of the practical extraction and reporting program
freerobby has quit [Read error: Connection reset by peer]
<havenwood>
maybe we'll have language detecting polyglot vms soon enough?
pu22l3r has joined #ruby
<havenwood>
or not? :P
supermarin has joined #ruby
<pontiki>
i am sure there are some folk grinding on that
ahumane is now known as ahuman
hermanmunster has quit [Remote host closed the connection]
freerobby1 has quit [Ping timeout: 252 seconds]
Solnse has quit [Quit: Leaving.]
supermarin has quit [Ping timeout: 250 seconds]
<RubyPanther>
I enjoyed coding in Perl more than I do in Ruby. But my own code gave me NIH and so had to be re-written every year. And if I had a "good" day where I was really seeing clearly, then that day's code would be unreadable.
<jblack>
huh. I love ruby far more than I ever did perl.
<RubyPanther>
In Ruby, good or bad, my code is a bit simple and boring.
momigi has quit [Remote host closed the connection]
Morkel has joined #ruby
<pontiki>
i like writing perl, but i never really wrote very many apps with it. i used it for all sorts of one-liners and one-offs, and lots of tiny utilities
<RubyPanther>
The part I enjoy more with Ruby is the C extensions. I don't want an extra glue language to glue my glue to my glue.
<pontiki>
but getting into ruby, i also started to think a lot differently, a lot more like i did when Lisp was my main language, back in Uni
hermanmunster has joined #ruby
momigi has joined #ruby
<RubyPanther>
Procedural is more expressive than OO, that's why I enjoy it more. But that is also why my code was crap. If you're disciplined enough to write Perl without being creative, then it is probably better than it was for me.
mjsmith2 has joined #ruby
ce_afk is now known as cescalante
<RubyPanther>
In Perl the best techniques are "expert-friendly." In Ruby, "expert-friendly" would be a slap in the face, a blatant insult.
momigi has quit [Remote host closed the connection]
nateberkopec has joined #ruby
mjsmith2 has quit [Ping timeout: 240 seconds]
fgo has joined #ruby
dseitz has joined #ruby
jamto11 has quit [Remote host closed the connection]
nateberkopec has quit [Ping timeout: 240 seconds]
Macaveli has joined #ruby
mr_snowf1ake has quit [Ping timeout: 245 seconds]
pu22l3r has quit [Remote host closed the connection]
thomasxie has left #ruby [#ruby]
etqqkoiflwhb has joined #ruby
cescalante is now known as ce_afk
nanoyak_ has joined #ruby
baweaver has joined #ruby
centipedefarmer has joined #ruby
hermanmunster has quit [Remote host closed the connection]
fgo has quit [Remote host closed the connection]
baweaver has quit [Ping timeout: 240 seconds]
hermanmunster has joined #ruby
lethjakman has joined #ruby
jackneill has joined #ruby
jackneill has quit [Changing host]
jackneill has joined #ruby
supermarin has joined #ruby
nanoyak_ has quit [Quit: Computer has gone to sleep.]
centipedefarmer has quit [Ping timeout: 240 seconds]
try has joined #ruby
hermanmunster has quit [Ping timeout: 240 seconds]
Alina-malina has joined #ruby
anaeem1 has joined #ruby
supermarin has quit [Ping timeout: 258 seconds]
lethjakman has quit [Ping timeout: 245 seconds]
hermanmunster has joined #ruby
JensOfSweden has joined #ruby
pika_pika has quit [Ping timeout: 258 seconds]
michael_lee has quit [Quit: Ex-Chat]
omosoj has quit [Ping timeout: 240 seconds]
benlieb has joined #ruby
yacks has joined #ruby
yacks has quit [Max SendQ exceeded]
momomomomo has quit [Quit: momomomomo]
jblack has quit [Quit: Lost terminal]
baroquebobcat has joined #ruby
absolutezeroff has quit [Remote host closed the connection]
mikepack has joined #ruby
jamto11 has joined #ruby
mjsmith2 has joined #ruby
sdouglas has quit [Remote host closed the connection]
HashNuke has quit [Quit: Connection closed for inactivity]
michaeldeol has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
Sawbones has joined #ruby
jamto11 has quit [Ping timeout: 276 seconds]
mjsmith2 has quit [Ping timeout: 240 seconds]
baroquebobcat has quit [Quit: baroquebobcat]
sdouglas has joined #ruby
_justin has joined #ruby
supermarin has joined #ruby
heftig has quit [Quit: Quitting]
MatthewsFace has joined #ruby
mikepack has quit [Remote host closed the connection]
mikepack has joined #ruby
anarang has joined #ruby
centipedefarmer has joined #ruby
fgo has joined #ruby
yakko has quit [Ping timeout: 240 seconds]
yakko has joined #ruby
supermarin has quit [Ping timeout: 240 seconds]
ce_afk is now known as cescalante
sdouglas has quit [Remote host closed the connection]
freerobby has joined #ruby
Cache_Money has quit [Quit: Cache_Money]
sdouglas has joined #ruby
HashNuke has joined #ruby
mikepack has quit [Ping timeout: 240 seconds]
Mon_Ouie has quit [Ping timeout: 245 seconds]
michaeldeol has joined #ruby
roadie has quit [Ping timeout: 276 seconds]
freerobby has quit [Ping timeout: 240 seconds]
pwh has quit []
razrunelord has joined #ruby
Jon30 has quit [Ping timeout: 252 seconds]
_tpavel has joined #ruby
webgen has joined #ruby
roadie has joined #ruby
cescalante is now known as ce_afk
mjsmith2 has joined #ruby
aross has joined #ruby
nateberkopec has joined #ruby
razrunelord has quit [Ping timeout: 258 seconds]
bthesorceror has joined #ruby
cmoneylulz has joined #ruby
MatthewsFace has quit [Quit: This computer has gone to sleep]
mjsmith2 has quit [Ping timeout: 240 seconds]
cmoneylulz has quit [Client Quit]
nateberkopec has quit [Ping timeout: 240 seconds]
kiri has joined #ruby
bthesorceror has quit [Ping timeout: 258 seconds]
bal has joined #ruby
bonZi has quit [Remote host closed the connection]
momigi has joined #ruby
centipedefarmer has quit [Remote host closed the connection]
tobago has joined #ruby
supermarin has joined #ruby
JoeGaudet has joined #ruby
combusean has quit [Ping timeout: 264 seconds]
decoponio has joined #ruby
lethan has joined #ruby
lethan has quit [Client Quit]
lethan has joined #ruby
momigi has quit [Ping timeout: 276 seconds]
supermarin has quit [Ping timeout: 252 seconds]
b00stfr3ak has joined #ruby
x1337807x has joined #ruby
noop has joined #ruby
Hanmac1 has joined #ruby
ktun has joined #ruby
srji has joined #ruby
Hanmac has quit [Ping timeout: 240 seconds]
Sawbones has quit [Remote host closed the connection]
Sawbones has joined #ruby
jprovazn has joined #ruby
m00nlight has quit [Remote host closed the connection]
m00nlight has joined #ruby
fantazo has quit [Ping timeout: 240 seconds]
tonini__ is now known as tonini
ktun_ has joined #ruby
Sawbones has quit [Ping timeout: 258 seconds]
baweaver has joined #ruby
ktun has quit [Ping timeout: 240 seconds]
n0n3 has quit []
baweaver has quit [Ping timeout: 252 seconds]
ikaros has joined #ruby
claymore has joined #ruby
ktun_ has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
alpha123 has quit [Ping timeout: 252 seconds]
jamto11 has joined #ruby
yakko has quit []
ceej is now known as balrui
Photism has quit [Read error: Connection reset by peer]
balrui is now known as ceej
Photism has joined #ruby
ddv has joined #ruby
ddv has quit [Changing host]
alpha123 has joined #ruby
lolmaus has quit [Ping timeout: 240 seconds]
supermarin has joined #ruby
amundj has joined #ruby
Synthead has joined #ruby
ixti has joined #ruby
lkba has joined #ruby
jamto11 has quit [Ping timeout: 255 seconds]
claymore has quit [Ping timeout: 258 seconds]
hgl has joined #ruby
havenwood has quit [Remote host closed the connection]
claymore has joined #ruby
seaned has joined #ruby
jack_rabbit has quit [Ping timeout: 240 seconds]
amundj has quit [Ping timeout: 240 seconds]
dumdedum has joined #ruby
supermarin has quit [Ping timeout: 252 seconds]
fayesal has quit [Quit: fayesal]
Hanmac has joined #ruby
<hgl>
hash value can't be an expression? I got syntax with this { path: File.expand_path '.' }
michaeldeol has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
sdouglas_ has quit [Remote host closed the connection]
m00nlight has quit [Ping timeout: 240 seconds]
cescalante is now known as ce_afk
nateberkopec has quit [Read error: No route to host]
coderhs has joined #ruby
nateberkopec has joined #ruby
hermanmunster has joined #ruby
grayWolf has quit [Remote host closed the connection]
coderhs has quit [Read error: Connection reset by peer]
Boohbah has joined #ruby
mjsmith2 has quit [Ping timeout: 240 seconds]
xorgnak has joined #ruby
bthesorceror has joined #ruby
sdouglas has joined #ruby
mjsmith2_ has quit [Ping timeout: 240 seconds]
nateberkopec has quit [Ping timeout: 240 seconds]
matcouto has joined #ruby
cmoneylulz has joined #ruby
Synthead has quit [Ping timeout: 246 seconds]
bthesorceror has quit [Ping timeout: 258 seconds]
cherry_lin has joined #ruby
timonv has joined #ruby
cmoneylulz has quit [Client Quit]
webgen has quit [Remote host closed the connection]
centipedefarmer has joined #ruby
minver has joined #ruby
jbomo has quit [Ping timeout: 245 seconds]
timonv has quit [Read error: Connection reset by peer]
<minver>
How do I get all products with the lowest price? min = products.min_by { |x| x.price }; products.select { |x| x.price == min }, is there a better way?
andrewlio has joined #ruby
timonv has joined #ruby
pgmcgee has quit [Ping timeout: 252 seconds]
drizz has joined #ruby
kate_r has joined #ruby
einarj has joined #ruby
alem0lars has joined #ruby
pgmcgee has joined #ruby
centipedefarmer has quit [Ping timeout: 240 seconds]
apeiros has quit [Remote host closed the connection]
apeiros has joined #ruby
<LadyRainicorn>
products.min_by(&:price)
Martxel_ has joined #ruby
zombiebit has joined #ruby
erf has joined #ruby
<minver>
LadyRainicorn: That only returns 1 records. I want to return multiple if that exists
webgen has joined #ruby
frobrob has joined #ruby
supermarin has joined #ruby
<Hanmac>
minver: i think yours is the only way
<LadyRainicorn>
Well, you can do it in one loop more efficiently, but it looks less nice.
webgen has quit [Remote host closed the connection]
<Hanmac>
ps you forgot to call .price after min_by but remember min_by can return nil if array is empty
Martxel_ has quit [Ping timeout: 240 seconds]
<Hanmac>
minver: so you need to check first if products is empty
supermarin has quit [Ping timeout: 255 seconds]
roolo has joined #ruby
bluOxigen has joined #ruby
<minver>
Hanmac: Yeah I replaced it with: min = products.minimum(:price);
<Burgestrand>
minver: give it a try before you thank me, I’m not sure it’ll work :P
banister has joined #ruby
banister has quit [Max SendQ exceeded]
banister has joined #ruby
banister has quit [Max SendQ exceeded]
banister has joined #ruby
jtz has joined #ruby
jtz has quit [Changing host]
jtz has joined #ruby
tvw has joined #ruby
crzrcn has quit [Quit: Leaving.]
timonv has quit [Remote host closed the connection]
freerobby has joined #ruby
supermarin has joined #ruby
jtz has quit [Client Quit]
etqqkoiflwhb_ has quit [Quit: Computer has gone to sleep.]
zegerjan has quit [Ping timeout: 264 seconds]
etqqkoiflwhb_ has joined #ruby
mlapp30m has quit [Read error: Connection reset by peer]
kukyakya_ has quit [Remote host closed the connection]
supermarin has quit [Ping timeout: 252 seconds]
freerobby has quit [Ping timeout: 264 seconds]
jtz has joined #ruby
jtz has quit [Changing host]
jtz has joined #ruby
ce_afk is now known as cescalante
etqqkoiflwhb_ has quit [Ping timeout: 264 seconds]
monkegjinni has quit [Remote host closed the connection]
funburn has joined #ruby
etqqkoiflwhb_ has joined #ruby
mjsmith2 has joined #ruby
charliesome has joined #ruby
Arkaniad has quit [Ping timeout: 245 seconds]
monkegjinni has joined #ruby
nateberkopec has joined #ruby
marr has quit [Ping timeout: 240 seconds]
greenDragon has joined #ruby
cescalante is now known as ce_afk
mjsmith2 has quit [Ping timeout: 240 seconds]
SteveBenner09 has joined #ruby
SteveBenner09 has quit [Client Quit]
madd has left #ruby [#ruby]
nateberkopec has quit [Ping timeout: 240 seconds]
charliesome has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
jhass|off is now known as jhass
JensOfSweden has quit [Remote host closed the connection]
funburn has quit [Quit: funburn]
psyko666 has quit [Quit: Leaving]
tjsousa has joined #ruby
tjsousa has quit [Remote host closed the connection]
etqqkoiflwhb_ has quit [Quit: Computer has gone to sleep.]
tjsousa has joined #ruby
popl has joined #ruby
popl has quit [Changing host]
popl has joined #ruby
popl has quit [Client Quit]
srji has quit [Ping timeout: 252 seconds]
mikepack has joined #ruby
benlieb has quit [Quit: benlieb]
popl has joined #ruby
popl has quit [Changing host]
popl has joined #ruby
Arkaniad has joined #ruby
funburn has joined #ruby
fgo has quit [Remote host closed the connection]
supermarin has joined #ruby
Arkaniad has quit [Max SendQ exceeded]
jfelchner has quit [Quit: Connection closed for inactivity]
mikepack has quit [Ping timeout: 258 seconds]
greenDragon has quit []
etqqkoiflwhb_ has joined #ruby
supermarin has quit [Ping timeout: 240 seconds]
helpD has joined #ruby
timonv has joined #ruby
yfeldblum has quit [Remote host closed the connection]
gsvolt_ has quit [Ping timeout: 250 seconds]
monkegjinni has quit [Remote host closed the connection]
tjsousa_ has joined #ruby
railsbro has quit [Remote host closed the connection]
toretore has joined #ruby
tjsousa has quit [Ping timeout: 250 seconds]
etqqkoiflwhb_ has quit [Quit: Computer has gone to sleep.]
matcouto has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
klaut has quit [Remote host closed the connection]
Xeago has quit [Remote host closed the connection]
elaptics`away is now known as elaptics
Milly_Bays has joined #ruby
Xeago has joined #ruby
Milly_Bays has quit [Read error: Connection reset by peer]
alem0lars has quit [Quit: Going AFK...]
alem0lars has joined #ruby
nerium has quit [Quit: nerium]
fella5s has joined #ruby
postmodern has quit [Quit: Leaving]
banister has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
JoeGaudet has quit [Quit: Computer has gone to sleep.]
Xeago has quit [Ping timeout: 240 seconds]
Arkaniad has joined #ruby
nerium has joined #ruby
Rahul_Roy has joined #ruby
etqqkoiflwhb_ has joined #ruby
popl has quit [Quit: Touch the frog.]
tjsousa_ has quit [Remote host closed the connection]
popl has joined #ruby
popl has quit [Changing host]
popl has joined #ruby
tjsousa_ has joined #ruby
alem0lars has quit [Quit: Going AFK...]
pen has quit []
charliesome has joined #ruby
Arkaniad has quit [Max SendQ exceeded]
alem0lars has joined #ruby
jamto11 has joined #ruby
kilk_ has quit [Ping timeout: 265 seconds]
spider-mario has joined #ruby
etqqkoiflwhb_ has quit [Client Quit]
supermarin has joined #ruby
ctp has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
jamto11 has quit [Ping timeout: 255 seconds]
xorgnak has left #ruby [#ruby]
sdouglas_ has quit [Remote host closed the connection]
sdouglas has joined #ruby
fgo has joined #ruby
kinacamen has quit [Ping timeout: 240 seconds]
kinacamen has joined #ruby
supermarin has quit [Ping timeout: 240 seconds]
mikecmpbll has joined #ruby
etqqkoiflwhb_ has joined #ruby
ping_pong has quit [Ping timeout: 252 seconds]
freerobby has joined #ruby
crzrcn has joined #ruby
funburn has quit [Quit: funburn]
supermarin has joined #ruby
sdouglas has quit [Ping timeout: 240 seconds]
joaoh82 has quit [Remote host closed the connection]
supermar_ has joined #ruby
Virtualize has joined #ruby
proxie has quit [Read error: Connection reset by peer]
fgo has quit [Ping timeout: 276 seconds]
intuxicated has joined #ruby
etqqkoiflwhb_ has quit [Client Quit]
freerobby has quit [Ping timeout: 240 seconds]
lethan has quit []
crzrcn has quit [Ping timeout: 252 seconds]
kevinykchan has joined #ruby
elaptics is now known as elaptics`away
Arkaniad has joined #ruby
elaptics`away is now known as elaptics
supermarin has quit [Ping timeout: 276 seconds]
jonno11 has joined #ruby
ce_afk is now known as cescalante
nerium has quit [Quit: nerium]
supermar_ has quit [Ping timeout: 276 seconds]
Arkaniad has quit [Max SendQ exceeded]
Arkaniad has joined #ruby
JensOfSweden has joined #ruby
lxsameer has joined #ruby
lxsameer has quit [Changing host]
lxsameer has joined #ruby
marr has joined #ruby
sski has quit [Remote host closed the connection]
funburn has joined #ruby
sski has joined #ruby
fieldfirst has joined #ruby
Xeago has joined #ruby
Martxel has joined #ruby
Beoran__ has quit [Ping timeout: 258 seconds]
Arkaniad has quit [Max SendQ exceeded]
Xeago has quit [Read error: Connection reset by peer]
ping_pong has joined #ruby
Xeago has joined #ruby
JensOfSweden has quit [Ping timeout: 252 seconds]
nateberkopec has joined #ruby
alem0lars has quit [Quit: alem0lars]
mikecmpbll has quit [Quit: ciao.]
popl has quit [Quit: Touch the frog.]
srji has joined #ruby
sski has quit [Ping timeout: 276 seconds]
kyb3r_ has quit [Read error: Connection reset by peer]
cescalante is now known as ce_afk
supermarin has joined #ruby
etqqkoiflwhb_ has joined #ruby
nateberkopec has quit [Ping timeout: 240 seconds]
helpD has quit [Remote host closed the connection]
pen has joined #ruby
sfr^ has joined #ruby
bthesorceror has joined #ruby
mikecmpbll has joined #ruby
popl has joined #ruby
popl has quit [Changing host]
popl has joined #ruby
supermar_ has joined #ruby
supermarin has quit [Read error: Connection reset by peer]
karupa is now known as zz_karupa
kate_r has joined #ruby
fabrice31 has quit [Remote host closed the connection]
maximski has joined #ruby
maximski has quit [Max SendQ exceeded]
maximski has joined #ruby
bthesorceror has quit [Ping timeout: 245 seconds]
Beoran__ has joined #ruby
centipedefarmer has joined #ruby
monkegjinni has joined #ruby
Xeago has quit [Remote host closed the connection]
Xeago has joined #ruby
Arkaniad has joined #ruby
aryko has joined #ruby
DouweM has joined #ruby
ctp has joined #ruby
Spitfire has quit [Remote host closed the connection]
centipedefarmer has quit [Ping timeout: 258 seconds]
Arkaniad has quit [Max SendQ exceeded]
LekeFly has joined #ruby
fabrice31 has joined #ruby
LekeFly_ has joined #ruby
nerium has joined #ruby
joaoh82 has joined #ruby
pskosinski has joined #ruby
yfeldblum has joined #ruby
etqqkoiflwhb_ has quit [Quit: Computer has gone to sleep.]
jprovazn has quit [Quit: Leaving]
etqqkoiflwhb_ has joined #ruby
supermar_ has quit [Remote host closed the connection]
JoeQuery has joined #ruby
etqqkoiflwhb_ has quit [Read error: Connection reset by peer]
supermarin has joined #ruby
etqqkoiflwhb_ has joined #ruby
LekeFly has quit [Ping timeout: 276 seconds]
JoeQuery has quit [Client Quit]
spinx is now known as spinx^
timgauthier has joined #ruby
joaoh82 has quit [Ping timeout: 258 seconds]
bal has quit [Quit: bal]
yfeldblum has quit [Ping timeout: 264 seconds]
supermarin has quit [Ping timeout: 240 seconds]
<timgauthier>
HAI KIDZ!
nvrch has quit [Quit: nvrch]
bal has joined #ruby
crzrcn has joined #ruby
blackmesa has joined #ruby
crzrcn has quit [Ping timeout: 252 seconds]
RaptorJesus_ has joined #ruby
dANOKELOFF has quit [Remote host closed the connection]
popl has quit [Quit: Touch the frog.]
RaptorJesus has quit [Ping timeout: 272 seconds]
St_Marx has joined #ruby
popl has joined #ruby
popl has quit [Changing host]
popl has joined #ruby
zegerjan has joined #ruby
m00nlight_ has quit [Quit: Konversation terminated!]
<timgauthier>
chirp chirp
<timgauthier>
i guess i have to actually write now
fgo has joined #ruby
srji has quit [Ping timeout: 252 seconds]
freerobby has joined #ruby
momigi has joined #ruby
pskosinski has quit [Quit: Til rivido Idisti!]
fgo has quit [Ping timeout: 258 seconds]
subraminion has joined #ruby
kirun has joined #ruby
freerobby has quit [Ping timeout: 264 seconds]
roolo has quit [Quit: Leaving...]
momigi has quit [Ping timeout: 240 seconds]
Arkaniad has joined #ruby
ce_afk is now known as cescalante
apeiros has quit [Remote host closed the connection]
banister has joined #ruby
apeiros has joined #ruby
St_Marx has quit [Remote host closed the connection]
Arkaniad has quit [Max SendQ exceeded]
JensOfSweden has joined #ruby
St_Marx has joined #ruby
shevy has joined #ruby
banister has quit [Client Quit]
phoo1234567 has joined #ruby
banister has joined #ruby
dANOKELOFF has joined #ruby
AlSquire has joined #ruby
apeiros has quit [Ping timeout: 240 seconds]
Aaaal has joined #ruby
mikepack has joined #ruby
nateberkopec has joined #ruby
olivier_bK has joined #ruby
JensOfSweden has quit [Ping timeout: 264 seconds]
zegerjan has quit [Ping timeout: 250 seconds]
Aaaal has quit [Client Quit]
cescalante is now known as ce_afk
nateberkopec has quit [Ping timeout: 240 seconds]
mikepack has quit [Ping timeout: 265 seconds]
bluOxigen has quit [Ping timeout: 240 seconds]
nerium has quit [Quit: nerium]
garethrees has quit [Ping timeout: 252 seconds]
jprovazn has joined #ruby
Devanon has joined #ruby
HashNuke has quit [Quit: Connection closed for inactivity]
srji has joined #ruby
funburn has quit [Quit: funburn]
jprovazn is now known as jprovazn_afk
<shevy>
I am back!
<shevy>
stupid internet
Thanatermesis has joined #ruby
Thanatermesis has joined #ruby
Thanatermesis has quit [Changing host]
roolo has joined #ruby
JensOfSweden has joined #ruby
Arkaniad has joined #ruby
Shidash has quit [Ping timeout: 252 seconds]
Arkaniad has quit [Max SendQ exceeded]
sski has joined #ruby
Virtualize|away has joined #ruby
sdouglas has joined #ruby
kinacamen has quit [Ping timeout: 264 seconds]
kevinykchan has quit [Read error: Connection reset by peer]
kevinykchan has joined #ruby
nerium has joined #ruby
joaoh82 has joined #ruby
j416 has joined #ruby
kevinykchan has quit [Client Quit]
KanKava has joined #ruby
yfeldblum has joined #ruby
zcreative has joined #ruby
sdouglas has quit [Ping timeout: 265 seconds]
banister has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
<Hanmac>
shevy: YEAH! did you know i made 26 commits yesterday for rwx ... and the rdoc-commented ratio > 60%
<shevy>
cool
Burgestrand has quit [Quit: Burgestrand]
<shevy>
Hanmac don't forget working examples! they are more important than pure rdoc
joaoh82 has quit [Ping timeout: 250 seconds]
<Hanmac>
yeah,yeah ... i will made samples later, currently i am adding more classes ... the last days i did try to comment functions & constants without adding new stuff (i didnt managed it always)
emergion has joined #ruby
yfeldblum has quit [Ping timeout: 240 seconds]
Burgestrand has joined #ruby
browndawg has joined #ruby
crzrcn has joined #ruby
eka has joined #ruby
danshultz has joined #ruby
schaary|afk is now known as schaary
<shevy>
hehe
supermarin has joined #ruby
Nahra has joined #ruby
zcreative has quit [Quit: Computer has gone to sleep.]
fusiosio has joined #ruby
agjacome has joined #ruby
Arkaniad has joined #ruby
flughafen has joined #ruby
crzrcn has quit [Ping timeout: 258 seconds]
<fusiosio>
In a class I found online, there's a getter method 'tags'. It's definition looks like `def tags=(tags)`. What does this mean? Is the = part of the method name? What do the parens mean in this example?
kate_r has quit [Quit: My MacBook Air has gone to sleep. ZZZzzz…]
Arkaniad has quit [Max SendQ exceeded]
<shevy>
fusiosio by definition, a method with = can never be a getter
RaptorJesus_ has quit [Ping timeout: 272 seconds]
jamto11 has joined #ruby
<shevy>
fusiosio = is part of the method name, yes; that is why it is included before the ()
subraminion has quit [Quit: Computer has gone to sleep.]
thomasxie has joined #ruby
<shevy>
definitions in ruby usually have a (), although the ruby parser allows you to omit parens
Arkaniad has joined #ruby
<shevy>
I like my parens in method definitions
<shevy>
def foo a,b,c,d
<shevy>
def foo(a,b,c,d)
Arkaniad has quit [Max SendQ exceeded]
kate_r has joined #ruby
jamto11 has quit [Ping timeout: 240 seconds]
subraminion has joined #ruby
subraminion has quit [Remote host closed the connection]
subraminion has joined #ruby
fayesal has joined #ruby
moritzs has quit [Ping timeout: 252 seconds]
b00stfr3ak has quit [Ping timeout: 264 seconds]
matcouto has joined #ruby
yalue has joined #ruby
bogeyd6 has quit [Read error: Connection reset by peer]
akemrir has joined #ruby
Chamkila has joined #ruby
Chamkila has joined #ruby
fgo has joined #ruby
<etqqkoiflwhb_>
fusiosio: def tags=(tags), is the setter
aryko has quit [Quit: aryko]
<fusiosio>
etqqkoiflwhb_: of course yeah
<etqqkoiflwhb_>
so you can say, post.tags = [ ..list of tags.. ]
<fusiosio>
shevy: I get it! Thanks for clearing my mind up
JasmeetQA has quit [Read error: Connection reset by peer]
<fusiosio>
etqqkoiflwhb_: and that line will run the method with the array as argument? Not try to set the property tags of object post? I mean: it's gonna be treaded as a method call, not variable assignment?
<timgauthier>
i should have had a name like ddjsfh
fabrice31 has quit [Remote host closed the connection]
<jhass>
fusiosio: yes, obj.something = else is a method call, something = else is an assignment
<jhass>
always
jonno11 has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<etqqkoiflwhb_>
fusiosio: yep, its equivalent to post.set_tags(tags)
<etqqkoiflwhb_>
the list of tags is passed as the tags argument
<fusiosio>
jhass: etqqkoiflwhb_: omfg. Thanks for clearing that up for me!
s2013 has joined #ruby
fgo has quit [Ping timeout: 252 seconds]
Burgestrand has quit [Quit: Burgestrand]
freerobby has quit [Ping timeout: 240 seconds]
charliesome has quit [Ping timeout: 240 seconds]
yalue has quit [Ping timeout: 240 seconds]
freerobby has joined #ruby
funburn has joined #ruby
ce_afk is now known as cescalante
Arkaniad has joined #ruby
kevinykchan has joined #ruby
charliesome has joined #ruby
himsin has quit [Quit: himsin]
p8952 has quit [Remote host closed the connection]
supermarin has quit [Remote host closed the connection]
bthesorceror has joined #ruby
supermarin has joined #ruby
vt102 has joined #ruby
sdouglas has joined #ruby
srji has quit [Ping timeout: 252 seconds]
Arkaniad has quit [Max SendQ exceeded]
freerobby has quit [Ping timeout: 265 seconds]
Hanmac1 has joined #ruby
_justin has quit [Read error: Connection reset by peer]
nateberkopec has joined #ruby
momomomomo has joined #ruby
Hanmac has quit [Ping timeout: 252 seconds]
s2013 has quit [Ping timeout: 255 seconds]
fabrice31 has joined #ruby
_justin has joined #ruby
fusiosio has quit [Remote host closed the connection]
sdouglas has quit [Ping timeout: 252 seconds]
BBBThunda has quit [Quit: Leaving]
momigi has joined #ruby
<shevy>
timgauthier are you still using php
<timgauthier>
currently at this exact moment no
<timgauthier>
are you?
<timgauthier>
I'm writing my website in java right now
nateberkopec has quit [Ping timeout: 240 seconds]
cescalante is now known as ce_afk
hermanmunster has quit [Remote host closed the connection]
apeiros has joined #ruby
browndawg has quit [Ping timeout: 276 seconds]
hermanmunster has joined #ruby
<shevy>
timgauthier I abandoned php years ago in favour of ruby, all my web needs are covered by ruby currently
charliesome has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<timgauthier>
yeah i'm using middleman for my current gig but i'll likely use perch or craft on whatever i do next
<LadyRainicorn>
shevy: But how will you calculate the date of Easter?!!?
<shevy>
LadyRainicorn with Time.new!
momigi has quit [Ping timeout: 240 seconds]
ixti has joined #ruby
<timgauthier>
blasphamy
<timgauthier>
you must build a bespoke method
hermanmunster has quit [Ping timeout: 245 seconds]
etqqkoiflwhb_ has quit [Quit: Computer has gone to sleep.]
_justin has quit [Quit: _justin]
supermarin has quit [Remote host closed the connection]
<LadyRainicorn>
But it's not a builtin!
etqqkoiflwhb_ has joined #ruby
<LadyRainicorn>
And if you write your own method it might be ... accurate! :0
supermarin has joined #ruby
<timgauthier>
if you get a bespoke watch made it might not tell time! :P
Thanatermesis has quit [Remote host closed the connection]
<timgauthier>
yeah but seriously, i wouldn't trust shevy to code me a clock
aryko has joined #ruby
paulfm has joined #ruby
_justin has joined #ruby
<timgauthier>
we all know he writes his date wrong
<shevy>
LadyRainicorn I am a big fan of making ruby FAT
<shevy>
FAT BATTERIES INCLUDED
<timgauthier>
FAT?
<shevy>
anything that may be useful gets in
<LadyRainicorn>
timgauthier: The joke is that shevy's method would be accuratem
centipedefarmer has joined #ruby
<timgauthier>
ah ok
<shevy>
AND people can also vote on what is included (but not what gets excluded hahahaha)
<LadyRainicorn>
The PHP builtin calculates easter inaccurately.
<LadyRainicorn>
(but is retained for backwards compatibility)
<timgauthier>
backwards compatibility but being wrong?
<LadyRainicorn>
Yes.
<timgauthier>
i'd rather them break it so people have to fix it :P
<timgauthier>
ohhh, they won't fix it because it will break all the things people did to work around it
maximski_ has joined #ruby
<timgauthier>
so what, fix that shit, when people update they have to fix their broken work arounds
nvrch has joined #ruby
<timgauthier>
you should see some of the brutal colours i'm trying out for the header of the new section of my site :O!@
maximski_ has quit [Read error: Connection reset by peer]
<LadyRainicorn>
That's not how PHP works.
subraminion has quit [Quit: Computer has gone to sleep.]
maximski has quit [Ping timeout: 252 seconds]
<shevy>
hehe
maximski has joined #ruby
<timgauthier>
php works?
<shevy>
php is designed to make people go crazy
<LadyRainicorn>
"It's not a bug-it's a feature!" is the motto.
Arkaniad has joined #ruby
<LadyRainicorn>
PHP works (for Cthulhu)
etqqkoiflwhb_ has quit [Ping timeout: 252 seconds]
subraminion has joined #ruby
subraminion has quit [Remote host closed the connection]
kitak_ has joined #ruby
Thanatermesis has joined #ruby
Thanatermesis has joined #ruby
Thanatermesis has quit [Changing host]
supermarin has quit [Ping timeout: 258 seconds]
subraminion has joined #ruby
paulfm has quit [Ping timeout: 240 seconds]
subraminion has quit [Remote host closed the connection]
subraminion has joined #ruby
centipedefarmer has quit [Ping timeout: 240 seconds]
Burgestrand has joined #ruby
Arkaniad has quit [Max SendQ exceeded]
sumark has quit [Remote host closed the connection]
bthesorceror has quit [Remote host closed the connection]
sumark has joined #ruby
himsin has joined #ruby
fgo has joined #ruby
brian___ has joined #ruby
bsutt has joined #ruby
brian___ has quit [Client Quit]
supermarin has joined #ruby
kitak_ has quit [Ping timeout: 240 seconds]
benzrf|offline is now known as benzrf
kevinykchan has quit [Read error: Connection reset by peer]
joaoh82 has joined #ruby
kevinykchan has joined #ruby
sunya7a has joined #ruby
fgo has quit [Ping timeout: 240 seconds]
<timgauthier>
brutal thread to read
<timgauthier>
glad i only ever used php as a template language
yalue has joined #ruby
<benzrf>
LadyRainicorn: do u know any haskell
agjacome_ has joined #ruby
sunya7a_ has joined #ruby
<LadyRainicorn>
I started learning it a while ago but then never did, so not really.
mark_locklear has joined #ruby
<apeiros>
LadyRainicorn: you know, there are a couple of such gotchas in ruby too. but the sheer number of those in php is simply jaw dropping
srji has joined #ruby
<timgauthier>
yeah the or and || precedence thing is one of them.
<benzrf>
LadyRainicorn: do u monads
<LadyRainicorn>
Why is that a gotcha?
<timgauthier>
because i wouldn't have known about something weird like that.
<timgauthier>
since everything i read about ruby is all about the use plain language
timonv has quit [Remote host closed the connection]
agjacome has quit [Ping timeout: 252 seconds]
<LadyRainicorn>
It's not that weird and somewhat useful.
<timgauthier>
so when its like "use the non english syntax or it doesn't do what you actually think it does"
<LadyRainicorn>
Not really.
<timgauthier>
its my opinion
joaoh82 has quit [Ping timeout: 264 seconds]
<apeiros>
I'm still not sure precedence tables with >5 levels are ever a good idea
* apeiros
intends to play with explicit precedence in his language
joaoh82 has joined #ruby
<apeiros>
(except for symbolic methods in the sugared form, like 5 + 2 * 3 == 11)
<LadyRainicorn>
I think it begaves pretty reasonably.
<LadyRainicorn>
or usually does what I would expect it to.
<apeiros>
I think it wouldn't be damaging to only have one or/and and use parens when you want "the other behavior"
agjacome_ has quit [Client Quit]
<LadyRainicorn>
What case have you run into where it was confusing?
<benzrf>
LadyRainicorn: anyway
<timgauthier>
since i mostly use it for templates, so far none
<apeiros>
LadyRainicorn: without cheating, which has higher precedence: `and` or `or`?
<apeiros>
same question for `&&` and `||`
<benzrf>
LadyRainicorn: it occurred to me that finn should totally shout 'MONADIC!' at some piont
<timgauthier>
but someone showed me an example last week of something whre it was like This == that or these or those
<benzrf>
*point
<timgauthier>
for a non programmer, i wouldn't have known that it doesn't do what i expect
<apeiros>
timgauthier: well, non-programmers are admittedly not a target audience ;-)
<shevy>
timgauthier yeah, it's annoying
crzrcn has joined #ruby
himsin has quit [Quit: himsin]
<timgauthier>
i expect this is that, or these, or those
<shevy>
timgauthier matz likes "and" though
<apeiros>
timgauthier: IMO a language should not cater to the uneducated.
<timgauthier>
true, but ruby is advertised as a language for the designers
<LadyRainicorn>
Almost all languages work like that.
<aross>
apeiros: `and` and `or` has the same precedence.
<timgauthier>
because of the plain english syntax
<apeiros>
aross: ssssh, don't spoil it
<LadyRainicorn>
Ruby is not advertised as such.
<shevy>
aross why not '&&' and 'and'
<timgauthier>
well its how i ended up here
<apeiros>
aross: the fun point is about `and` and `or` having the same precedence, while `&&` and `||` do not
<LadyRainicorn>
Maybe Cucumber, but that shit's cray.
chipotle_ has quit [Quit: cya]
alem0lars has joined #ruby
<aross>
`&&` has higher then `and`
<timgauthier>
naw, ruby and then rails where advertised as a way for designers to write code to make apps without having a programmer
Hanmac has joined #ruby
<timgauthier>
that statement is woefully inaccurate
<shevy>
timgauthier well mostly rails, ruby did not do much advertisement before rails really
<apeiros>
`&&` also has higher precedence than `||`
<LadyRainicorn>
Huh, && and || having different precedence is odd.
<timgauthier>
but i still do see articles recommending ruby for designers because of the plain english
<shevy>
:)
<wuest>
timgauthier: they were? Ick.
<apeiros>
LadyRainicorn: not really. in many logic systems, and/or have different precedences.
<LadyRainicorn>
Though I still see why.
jgoss has quit [Ping timeout: 240 seconds]
<timgauthier>
and for the most part, ruby is GREAT for that, the plain english syntax is awesome, but when you know that you need to use || isntead of or in that situation, then awesome!
<apeiros>
but the two different and/or's having different relative precedence is odd indeed IMO, and inconsistent
<LadyRainicorn>
x&&y || z
<shevy>
ack
<apeiros>
if `&&` > `||`, then IMO `and` > `or`, but that's not the case.
<shevy>
why did you not even put spaces around &&
<shevy>
you evil ponicorn you
<timgauthier>
i get confused even in mathmatics by things like that, so i use the () a lot
<LadyRainicorn>
:3
<shevy>
timgauthier yeah, I do sometimes in ruby too
_whitelogger has joined #ruby
<LadyRainicorn>
To signal precedence ;p
<shevy>
if foo and ! foo.include?('bla')
<shevy>
LadyRainicorn but it's harder to read!
kinacamen has joined #ruby
<shevy>
hmm
Arkaniad has joined #ruby
<timgauthier>
if i just use just = (this or that or those) then i suspect its a bit easier for me to understand and i suspect it is more likely to do what i want
<shevy>
x&&y||z
<aross>
apeiros: I think its great. IMO `and` and `or` works perfect in flow control while `||` and `&&` is more fore comparison. And most of the time deep nested `and`, `or`, `||` and `&&` makes code hard to read.
supermarin has quit [Remote host closed the connection]
<shevy>
timgauthier all programming languages have warts
<LadyRainicorn>
I am not sure exactly what behaviour you want from that.
crystal77 has joined #ruby
supermarin has joined #ruby
crzrcn has quit [Ping timeout: 265 seconds]
<shevy>
LadyRainicorn I want everything! all the time! GIMME MORE
cina has joined #ruby
<shevy>
I want random interpretation of lines at runtime
<shevy>
surprise me with the outcome!
<LadyRainicorn>
I like this idea.
cina has quit [Client Quit]
klaut has joined #ruby
<timgauthier>
i'm game
jamto11 has joined #ruby
timonv has joined #ruby
Arkaniad has quit [Max SendQ exceeded]
LekeFly_ has quit [Ping timeout: 250 seconds]
eflynn has joined #ruby
supermarin has quit [Ping timeout: 252 seconds]
<apeiros>
aross: you're missing my point
<apeiros>
aross: 14:36 apeiros: if `&&` > `||`, then IMO `and` > `or`, but that's not the case.
jamto11 has quit [Ping timeout: 240 seconds]
<apeiros>
but besides that point, I still maintain that it IMO wouldn't be damaging to just throw out and/or and require parens for their current use-cases.
funburn has quit [Quit: funburn]
zigomir has quit []
zigomir has joined #ruby
jamto11 has joined #ruby
roolo has quit [Quit: Leaving...]
pika_pika has joined #ruby
cina has joined #ruby
pu22l3r has joined #ruby
fgo has joined #ruby
NukePuppy has joined #ruby
fgo has quit [Read error: No route to host]
mr_snowf1ake has joined #ruby
freerobby has joined #ruby
fgo has joined #ruby
roolo has joined #ruby
pavelz has quit [Ping timeout: 252 seconds]
mikepack has joined #ruby
momomomomo has quit [Quit: momomomomo]
joaoh82 has quit []
dblessing has joined #ruby
ce_afk is now known as cescalante
fgo has quit [Ping timeout: 240 seconds]
freerobby has quit [Ping timeout: 252 seconds]
cpruitt has joined #ruby
mikepack has quit [Ping timeout: 264 seconds]
etqqkoiflwhb_ has joined #ruby
Arkaniad has joined #ruby
jamto11 has quit [Remote host closed the connection]
frobrob has quit [Quit: leafing]
rmorello has joined #ruby
_m_g_ has quit [Quit: Peace & Protection 4.22.2]
jonno11 has joined #ruby
chipotle has joined #ruby
rdark has joined #ruby
Arkaniad has quit [Max SendQ exceeded]
emergion has quit [Ping timeout: 240 seconds]
nateberkopec has joined #ruby
Arkaniad has joined #ruby
cescalante is now known as ce_afk
charliesome has joined #ruby
kate_r has quit [Quit: My MacBook Air has gone to sleep. ZZZzzz…]
qwyeth has joined #ruby
Arkaniad has quit [Max SendQ exceeded]
fijimunkii has joined #ruby
bthesorceror has joined #ruby
nateberkopec has quit [Ping timeout: 240 seconds]
_m_g_ has joined #ruby
crystal77 has quit [Quit: Computer has gone to sleep.]
matcouto has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
mary5030 has joined #ruby
kitak has quit [Remote host closed the connection]
nfk has joined #ruby
kitak has joined #ruby
<timgauthier>
apeiros i'd prefer to keep both and or else etc but make them equal to || && ==
<timgauthier>
but why would you rather use || instaed of "or" ?
sski has quit [Remote host closed the connection]
browndawg has joined #ruby
<timgauthier>
so why not both
<apeiros>
except for semantic reasons. (e.g. Object defines ==, eql?, equal? and they all have a different semantic, but for a given class, their implementation might be identical, and then an alias is acceptable)
kate_r has joined #ruby
<apeiros>
timgauthier: I wouldn't really care which one of them to keep
<timgauthier>
i don't see why its bad to have more then one way to do it.
<apeiros>
in ruby, I'd go with && and || because they're more widely used
bthesorceror has quit [Ping timeout: 240 seconds]
<apeiros>
but in a fresh language, I'd probably go with and/or
northfurr has joined #ruby
<apeiros>
timgauthier: because it *is not* more than one way to do it
<timgauthier>
i don't know, you hit rails and then ruby is using "and", "or"
Megtastique has joined #ruby
<apeiros>
it's "lets put a different label on *the same* way to do it"
roadie has quit [Ping timeout: 252 seconds]
<timgauthier>
and whats bad with that?
<apeiros>
assuming we're talking about aliasing
krz has quit [Quit: WeeChat 0.4.3]
<apeiros>
timgauthier: quick, tell me the difference between map/collect, inject/reduce, reject/delete_if
<timgauthier>
i'm a newb so i can't tell you the difference between much
<apeiros>
timgauthier: good, then you should see that part of the argument already: instead of learning 3 methods, you now learn 6
<timgauthier>
i'm for aliases that turn things to plain text vs whatever you call "||"
<apeiros>
timgauthier: if your intention is to use text instead of symbols, then drop the symbols. don't just alias.
<apeiros>
aliases are bad. they add overhead for no gain.
<Burgestrand>
reject!/delete_if
<Burgestrand>
no?
<Burgestrand>
;_
davedev24 has joined #ruby
<apeiros>
Burgestrand: 1 of 2 possible points earned :)
etqqkoiflwhb_ has quit [Quit: Computer has gone to sleep.]
<Burgestrand>
\o/
<Burgestrand>
I'll use them to get lunch
<apeiros>
Burgestrand: but not both point because reject!/delete_if are not equivalent
<apeiros>
map/collect -> alias
<apeiros>
inject/reduce -> alias
<apeiros>
reject/reject!/delete_if -> different methods, doing different things, just similar
Devanon has quit [Quit: WeeChat 0.4.3]
<apeiros>
and having tons of aliases forces you to remember a) which ones are actually aliases and b) which ones aren't. and it *will* cause you to miss it once in a while.
<Burgestrand>
I don't like aliases
subraminion has quit [Quit: Computer has gone to sleep.]
* apeiros
neither
browndawg1 has joined #ruby
<Burgestrand>
reject/reject! is okay, delete_if is… too similar to reject! to be okay
<apeiros>
it's a fucked up try to appease everbody, making it worse for all
<Burgestrand>
I mean, they only differ in return value
supermarin has joined #ruby
nerium has quit [Quit: nerium]
Sawbones has joined #ruby
<Burgestrand>
Anyway… food!
AlexRussia has quit [Remote host closed the connection]
<Burgestrand>
fusiosio: every thing is an object, and every object has a hidden class called the `singleton class`, that is responsible for *that* particular object
Zesty has joined #ruby
<fusiosio>
Burgestrand: mind == blown. That's really cool!
<Burgestrand>
fusiosio: when you do `def self.some_method`, you really add the method to the singleton class of that object
nerium has joined #ruby
<fusiosio>
Burgestrand: wow
<Burgestrand>
(actually, not all objects have a singleton class either… we could go on forever)
subraminion has joined #ruby
<Burgestrand>
fusiosio: so the important thing to remember when you see `def whatever.some_method`, think of what object `whatever` is… is it a string? a class? a module?
subraminion has quit [Remote host closed the connection]
subraminion has joined #ruby
mansi has joined #ruby
apeiros has quit [Ping timeout: 255 seconds]
beef-wellington has joined #ruby
crystal77 has joined #ruby
mary5030 has quit [Remote host closed the connection]
havenwood has quit [Remote host closed the connection]
obscured has joined #ruby
havenwood has joined #ruby
jprovazn_afk is now known as jprovazn
crelix has joined #ruby
zcreative has quit [Quit: Computer has gone to sleep.]
Macaveli has quit [Ping timeout: 252 seconds]
jonno11 has joined #ruby
beef-wellington has quit [Ping timeout: 240 seconds]
kevinykchan has quit [Quit: Computer has gone to sleep.]
<Bilge>
I can define equality between Card and Symbol by overriding == and eql? but this creates a barmy state where Card can be equal to Symbol but Symbol is not equal to card and therefore Hash.include? returns false still
<Cope>
so you have a card class, with an attr_accessor for the id?
<Bilge>
Yes
<Bilge>
attr_reader
<Cope>
so can't you just do hash[my_card.id] = my_card ?
rostam has joined #ruby
<Bilge>
Well no because I'm actually using a Set rather than a hash directly
<Cope>
why are you using a set?
<Bilge>
It seemed like the right thing to do
<pontiki>
famous last words...
Hanmac1 has joined #ruby
fusiosio has quit [Remote host closed the connection]
<Cope>
why? :) what problem does it solve for you? I'm not saying it's wrong... just trying to get you to think about it
tjsousa_ has quit [Ping timeout: 252 seconds]
<Bilge>
So I can do things like subtract to remove ranges of cards or whatever
tjsousa_ has joined #ruby
<Cope>
do you need that now?
tjsousa_ has quit [Remote host closed the connection]
<Cope>
or is it a 'handy just in case i might need it' kinda trhing
<Bilge>
It's probably wrong, actually, since I don't really have a use case for that. I'd probably be removing ranges rather than matching cards
tjsousa_ has joined #ruby
<Cope>
because if it's the latter, I'd tend to do the simplest thing first
Hanmac has quit [Ping timeout: 255 seconds]
<Cope>
and only complicate it if you actually need that feature
davidcollom_zzz has joined #ruby
speakingcode has joined #ruby
yfeldblum has joined #ruby
<Bilge>
Array might be more correct, but it will still have the same issue that I can't look up a card by its Symbol
thomasxie has quit [Remote host closed the connection]
<Cope>
Bilge: so you're representing a deck of cards? Each card is an instance of a class card, and the deck is currently a set? And you want to be able to select a card from the set by id? you could do that with an array an a select statement... but I guess it'd be slower than using the id as a key in a hash
<aross>
Anyone knows how to specify locale in rails `render` method for I18n?
paulfm has joined #ruby
phutchins has joined #ruby
<Cope>
aross: someone in the rails channel? #justsayin
MatthewsFace has quit [Quit: This computer has gone to sleep]
thomasxie has joined #ruby
Sthebig has quit [Ping timeout: 246 seconds]
<Bilge>
Yes, since Array.include? is O(n) and Hash is faster
Fire-Dragon-DoL has joined #ruby
<Cope>
you wouldn't do array.include... you'd use select from enumerable, and select on card.id
Fire-Dragon-DoL has quit [Max SendQ exceeded]
failshell has joined #ruby
CorpusCallosum has quit [Quit: Computer has gone to sleep.]
<Cope>
but it'd still be slower, but at the scale of 52ish cards I doubt performance is your biggest problem
sbnnrd has quit [Ping timeout: 240 seconds]
aross has quit []
Fire-Dragon-DoL has joined #ruby
crzrcn has joined #ruby
SCommette has joined #ruby
aross has joined #ruby
momomomomo has quit [Quit: momomomomo]
<Cope>
it do whatever is the easiest and simplest implementation for your first feature... and refactor as you need to
<Bilge>
Whether I use a Hash or Set, the problem remains the same
pu22l3r has quit [Ping timeout: 250 seconds]
subraminion_ has quit [Remote host closed the connection]
Macaveli has joined #ruby
<Bilge>
I cannot look up a Card in my Hash using the Symbol
<Cope>
why not?
<Bilge>
Because Cards are stored as the keys of the Hash
anaeem1 has quit [Remote host closed the connection]
<Cope>
the key of the hash can be a symbol... sorry, maybe it'd help if you showed some code with your problem
<Cope>
I might just be misunderstanding you
Hanmac1 has quit [Ping timeout: 240 seconds]
<Bilge>
I want the flexibility to be able to look up a Card by Card OR Symbol
<Bilge>
They should be interchangable
Arkaniad has joined #ruby
mikepack has joined #ruby
<Cope>
ok... and that's a requirement now? what feature does it give you?
Macaveli has quit [Client Quit]
<Cope>
sorry not trying to be a jerk here, but unless you actually need that, you might want to do something simpler that works first.
crzrcn has quit [Ping timeout: 276 seconds]
kevinykchan has joined #ruby
eka has joined #ruby
BigTexasButters has joined #ruby
<Bilge>
I think maybe you're right, this is a stupid idea
<Bilge>
Since it is possible to have two cards with the same ID
<Bilge>
It would be weird if someone had two of the same card, played one and the other one disappeared from their hand
Arkaniad has quit [Max SendQ exceeded]
Karunamon|2 is now known as Karunamon
Rahul_Roy has quit [Quit: Connection closed for inactivity]
<Cope>
are you modellinga specific game?
<Bilge>
Uno
<Cope>
cool!
robert_ has joined #ruby
robert_ has joined #ruby
<Cope>
I love this sort of thing.
<Bilge>
It's a pretty fun pet project to learn Ruby :^)
bubbajones has quit [Ping timeout: 240 seconds]
thomasxie has quit [Quit: Leaving.]
fijimunkii has joined #ruby
mikepack has quit [Ping timeout: 240 seconds]
freezey has joined #ruby
<Cope>
i did a bunch of stuff like this in an embedded mud language - backgammon, bridge, monopoly etc
<Cope>
ruby is much easier ;)
<Bilge>
I still think my idea is good, actually, since the hash should respond to both Card and Symbol
<Bilge>
If it is imperative to select a particular card then I would not look up by Symbol
freezey has quit [Read error: No route to host]
<Burgestrand>
What kind of API do you want?
iamvery has joined #ruby
treehug88 has joined #ruby
<Burgestrand>
An important rule to remember here: don't inherit from things you have no control over.
Chamkila has quit [Remote host closed the connection]
<Cope>
+!
<Cope>
erm 1!
pasties has joined #ruby
<Bilge>
Deck[:id] or Deck[Card.new(:id)]
<Burgestrand>
Bilge: and you dont want to define #hash and #==?
<Burgestrand>
Sorry, #eql?, not #==
<Bilge>
I defined both of those things but include? still fails
top4o has joined #ruby
<Burgestrand>
Bilge: #hash and #eql?, not #==
<Bilge>
Because you cannot override #hash and #== for Symbol
<Burgestrand>
Bilge: don't inherit from symbol first of all :)
<Bilge>
I overrode all 3
<Bilge>
I haven't
datafirm has joined #ruby
<Bilge>
I've encapsulated Symbol in @id
<Bilge>
Then I overrode all of those methods
<Bilge>
Then I was in a state where Card == Symbol but Symbol != Card
flughafen has joined #ruby
danman_ has joined #ruby
<Bilge>
Because depending on the order of operands depends on which equality method is called and I cannot change how Symbol behaves
<Bilge>
Therefore Deck[:id] will always be false because it looks it up as Symbol.eql(Card) which is still always false
<Bilge>
I mean Deck.include?(:id) will always be false
minver has quit [Ping timeout: 240 seconds]
freezey has joined #ruby
kevinykchan has quit [Quit: Computer has gone to sleep.]
<benzrf>
i should try writing a hash map impl in C
<benzrf>
to Cement My Understanding™
iamvery has left #ruby [#ruby]
<benzrf>
basic idea is that you have an array of pointers to linked lists, then for insertion you hash the key, find that index, then append a k/v pair to the ll
<benzrf>
and lookup you hash the key, find the index, than traverse comparing equality
<benzrf>
right?
phutchin1 has joined #ruby
<benzrf>
hence the use of eql? in hashes
<Cope>
benzrf: there's a chapter on how ruby implements hash functions in 'Ruby Under a Microscope' (excellent book)
<benzrf>
mehlah:
<benzrf>
*meh
<benzrf>
ruby is ugly enough without training a microscope at it
<benzrf>
fun fact i almost typed microsoft instead of microscope
<benzrf>
i caught myself typing 'so' instead of 'sc'
phutchins has quit [Ping timeout: 240 seconds]
chrisseaton has joined #ruby
aross has quit [Remote host closed the connection]
bal has quit [Quit: bal]
aross has joined #ruby
datafirm has quit [Quit: datafirm]
terrellt has quit [Read error: Connection reset by peer]
terrellt has joined #ruby
apeiros has quit [Remote host closed the connection]
<Sawbones>
Ruby isn't that ugly at all
<Sawbones>
I think compared to other modern day languages it looks really nice
apeiros has joined #ruby
jack_rabbit has joined #ruby
<crome>
it depends on how much you use advanced ruby features and shorthands
<Cope>
I suspect benzrf is referring to the C implemention of MRI
kitak has quit [Remote host closed the connection]
kitak has joined #ruby
<Burgestrand>
Bilge: make your own hash
<Cope>
at least that's how I read it.
crystal77 has quit [Quit: Computer has gone to sleep.]
MatthewsFace has joined #ruby
Arkaniad has joined #ruby
<Sawbones>
Oh ok
aross has quit [Ping timeout: 264 seconds]
sambao21 has quit [Quit: Computer has gone to sleep.]
<Cope>
I might be tempted to use Structs - they're quite handy for this kind of thing.
eflynn has quit [Quit: eflynn]
ffranz has joined #ruby
MatthewsFace has quit [Client Quit]
fgo has quit [Remote host closed the connection]
<benzrf>
ruby is not so much ugly as messy
datafirm has joined #ruby
<Sawbones>
I don't really think so, not compared to something like C or Golang
jonno11 has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
razrunelord has joined #ruby
phutchins has joined #ruby
BWStearns has joined #ruby
Hanmac1 has joined #ruby
<atmosx>
hello
yak_ouza has joined #ruby
<webgen>
rvm use 1.9.3@rottenpotatoes --default ------- I use this command, when I close terminal, go back to the project dir and say rvm gemset list it tells me it uses default but not the rottenpotatoes :S I am confused
ffranz has quit [Ping timeout: 255 seconds]
datafirm has quit [Quit: datafirm]
Hanmac has quit [Ping timeout: 240 seconds]
<Cope>
in shock news, rvm confuses someone
ayaz has quit [Read error: Connection reset by peer]
* Cope
isn't a fan of rvm :(
<Cope>
webgen: sorry, not constructive... but I gave up on rvm a long time ago, and mysteriously my problems and confusions went away!
<atmosx>
Cope: I use it the last 3 years without problems
dik_dak has quit [Quit: Leaving]
razrunelord has quit [Ping timeout: 265 seconds]
jonno11 has joined #ruby
* Cope
nods; I'm sure thousands of people do - otherwise it wouldn't stay so popular
vlad_starkov has joined #ruby
axl_ has quit [Quit: axl_]
datafirm has joined #ruby
pu22l3r has joined #ruby
kinacamen has quit []
<Cope>
I'm a fan of simple things; probably because I'm a rather simple person :)
sdouglas has joined #ruby
<webgen>
Cope, it seems fine its just i am a beginner, atmosx could you help me with my question in that case ? :D
<atmosx>
webgen: use .ruby-gemset and .ruby-version
<webgen>
atmosx, kk sek thx
monkegjinni has quit [Remote host closed the connection]
<atmosx>
webgen: it's way better for projects
combusean has joined #ruby
yak_ouza is now known as octalmind
banister has joined #ruby
<webgen>
atmosx, you mean with rvm or? I dont understand how to use those commands in what context
mr_snowf1ake has joined #ruby
instantaphex has joined #ruby
<Cope>
webgen: I think you can create a file called .ruby-version
ffranz has joined #ruby
<Cope>
rvm will read it and set your version and gemset accordingly
fabrice31 has quit [Remote host closed the connection]
<havenwood>
the .ruby-version convention is supported by rvm, chruby and rbenv
browndawg1 has left #ruby [#ruby]
kevinykchan has quit [Read error: Connection reset by peer]
<havenwood>
i think rbenv's doesn't support globbing though?
<atmosx>
cool, changelog seems very similar the podcast I'd lke to do in Greek language, but if I wanna have any traction mine should be less technical... Mix topics with more mainstream things.
Arkaniad has joined #ruby
<havenwood>
atmosx: now i just need to learn Greek... and i have another podcast to listen to!
noop has quit [Ping timeout: 240 seconds]
<havenwood>
atmosx: what's the podcast called?
apeiros has joined #ruby
sdouglas has quit [Remote host closed the connection]
bthesorceror has joined #ruby
<atmosx>
havenwood: it's nto ready yet :-) I've done two podcasts in the past with 2 friends.
<havenwood>
atmosx: nice
endash has quit [Read error: Connection reset by peer]
Megtastique has quit []
vpretzel has quit [Remote host closed the connection]
Arkaniad has quit [Max SendQ exceeded]
endash has joined #ruby
<atmosx>
havenwood: I might do it on Sept, if I find the time... and at least 1 other guy to do some of the heavyload editing.
maestrojed has joined #ruby
Iniesta8 has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
Macaveli has joined #ruby
<atmosx>
havenwood: which podcasts you listen regularly? I listen 'tools of the trade' by Spienlis (IEEE Spectrum) and Ruby5.
<atmosx>
Spinelis etc.
vpretzel has joined #ruby
BrianJ has joined #ruby
Arkaniad has joined #ruby
<havenwood>
atmosx: Ruby5, Ruby Rogues, the Changelog and FLOSS Weekly
<Cope>
what's ruby5 ?
<havenwood>
atmosx: hmm, tools of the trade, i'll have to check that out
sambao21 has quit [Read error: Connection reset by peer]
djbkd has quit [Remote host closed the connection]
<Hanmac>
shevy ... hm i need a tech that uses motion captureing so you can play music while playing air-guitar ... (but for some reason i think it already exist ;P )
sambao21 has joined #ruby
s2013 has quit [Ping timeout: 255 seconds]
<Hanmac>
havenwood: so looked more from Doctor Who?
aross_ has quit [Ping timeout: 265 seconds]
funktor has joined #ruby
alem0lars has joined #ruby
<havenwood>
s4e5
djbkd has joined #ruby
tvw has joined #ruby
<shevy>
Cope perhaps they are just wrapped in some kind of green wrapper
<havenwood>
Hanmac: got distracted by nlp
<shevy>
like onions and their layers
<Hanmac>
havenwood: wasnt s4e3 a little bit oood? ;P
LadyRainicorn has quit [Read error: Connection reset by peer]
Morkel has quit [Ping timeout: 255 seconds]
Morkel_ has joined #ruby
vpretzel|nursing is now known as vpretzel|1414
mrj has quit [Remote host closed the connection]
fijimunkii has quit [Ping timeout: 240 seconds]
robbyoconnor has joined #ruby
fumduq has quit [Ping timeout: 252 seconds]
SegFaultAX has quit [Excess Flood]
SegFaultAX has joined #ruby
danijoo has quit [Ping timeout: 252 seconds]
Rainicorn has quit [Read error: Connection reset by peer]
supermarin has joined #ruby
LadyRainicorn has joined #ruby
crystal77 has joined #ruby
sepp2k has joined #ruby
<franzip>
can someone help me with a problem?
<jhass>
no, nobody knows your problem. how should they?
<franzip>
these are the specs: Define a method starts_with_consonant?(s) that takes a string and returns true if it starts with a consonant and false otherwise. (For our purposes, a consonant is any letter other than A, E, I, O, U.) NOTE: be sure it works for both upper and lower case and for nonletters!
nanoyak has quit [Quit: Computer has gone to sleep.]
<franzip>
oh sorry i've pasted the wrong one, this is the correct one: Define a method binary_multiple_of_4?(s) that takes a string and returns true if the string represents a binary number that is a multiple of 4. NOTE: be sure it returns false if the string is not a valid binary number!
<franzip>
damn, forgot the end too, but it's in the right place in my code
heftig has joined #ruby
tacos1de has quit [Ping timeout: 272 seconds]
FreshDumbledore has joined #ruby
<LadyRainicorn>
Anyway why are you testing that with a regexp?
<LadyRainicorn>
Use %
anaeem1 has quit [Remote host closed the connection]
<franzip>
the testing is made by an automatic grader, my output for "0" is false
<Cope>
franzip: can you show the tests?
tacos1de has joined #ruby
FreshDumbledore has left #ruby ["@NSA: terrorist, bomb, government, djihad"]
<LadyRainicorn>
franzip: Convert the string to an integer, and test it with %.
<jhass>
franzip: what do you think /^[10]/ does?
michaeldeol has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
FenixFyreX has joined #ruby
pwh has quit [Ping timeout: 240 seconds]
<jhass>
ah, nvm
karmatr0n has quit [Remote host closed the connection]
<franzip>
LadyRainicorn: i'll try that, i just wanted to use regexp for practice
matchaw has quit [Ping timeout: 240 seconds]
<shevy>
:\
sambao21 has quit [Quit: Computer has gone to sleep.]
mrmargolis has quit [Remote host closed the connection]
Solnse has quit [Ping timeout: 255 seconds]
<LadyRainicorn>
Basically your code is failing because it doesn't account for numbers under 4
srji has quit [Ping timeout: 252 seconds]
<franzip>
but it says "multiple of 4"
ascarter has joined #ruby
kitak_ has quit [Remote host closed the connection]
kitak_ has joined #ruby
Es0teric has quit [Remote host closed the connection]
robbyoconnor has quit [Max SendQ exceeded]
mrmargol_ has joined #ruby
djbkd has quit [Remote host closed the connection]
ascarter has quit [Client Quit]
cescalante is now known as ce_afk
robbyoconnor has joined #ruby
<Cope>
franzip: what are the characteristics of a binary number that's divisble by 4?
<franzip>
ends with two 0
Milly_Bays has joined #ruby
<Cope>
ok... so what's your plan to test for that?
<Boohbah>
franzip: can you paste on a non-pastebin.com site?
<Cope>
yeah that too
<LadyRainicorn>
I'm assuming the actual program contains the missing end, right?
<LadyRainicorn>
If so, their program probably considers 0 a multiple of 4.
<franzip>
the testing is provided by the edX platform so i have no idea
acrussell has joined #ruby
treehug88 has quit [Ping timeout: 258 seconds]
<franzip>
yeah it's pretty specific, it fails on "output 0"
<Cope>
franzip: sorry i mean what's your algorithm
* Boohbah
would like to see the code but cannot because pastebin
benzrf is now known as benzrf|offline
<Cope>
how are you going to establish if your string ends in 00 ?
_Andres has joined #ruby
Troy^ has joined #ruby
kevinfag- has quit [Quit: EliteBNC - http://elitebnc.org (Auto-Removal: idle account/not being used)]
Troy^ has left #ruby [#ruby]
Soda has joined #ruby
<franzip>
"/^[10]*100$/
tobago has quit [Remote host closed the connection]
kitak_ has quit [Ping timeout: 240 seconds]
lectrick__ is now known as lectrick
<Cope>
and how does that work?
Solnse has joined #ruby
lectrick has quit [Changing host]
lectrick has joined #ruby
Ardenzi has quit [Read error: Connection reset by peer]
endash has quit [Read error: Connection reset by peer]
JoeGaudet has quit [Quit: Computer has gone to sleep.]
endash has joined #ruby
zcreative has joined #ruby
<Cope>
-- this is obviously homework, and I'm cool with that if IRC helps you understand what you're doing; I'm not ok with it if you want people on IRC to do your homework for you.
<LadyRainicorn>
franzip seems to think 0 shouldn't be considered a multiple of 4.
<LadyRainicorn>
I have a suspicion his professor disagrees.
<Solnse>
is it considered good or bad practice to reuse variables that are no longer needed later in code to save memory?
<LadyRainicorn>
Bad.
ctp has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<Solnse>
and your reasoning?
closer has joined #ruby
dml_ has joined #ruby
<csmrfx>
I like to do that sometimes
Kricir has quit [Ping timeout: 240 seconds]
<shevy>
we make ruby scripts superfast that way
<csmrfx>
lol
sooik has quit [Ping timeout: 250 seconds]
<shevy>
I keep on reusing _
<csmrfx>
ree cylce
<LadyRainicorn>
It's confusing, and honestly if you're worried about that fine grained level of memory usage, Ruby isn't the best choice.
<shevy>
lol
krazh has quit [Remote host closed the connection]
<csmrfx>
yeah wel
Sthebig has quit [Remote host closed the connection]
<shevy>
Solnse likes perfection
<shevy>
every character must be optimized
krazh has joined #ruby
benzrf|offline is now known as benzrf
<Solnse>
I just so no reason to hold a complete html document i'm parsing in a variable after I'm done with it and could use the same page = variable on the next request....
<csmrfx>
its one of those meh things, not on my optimization list
<Solnse>
but i'd like to stick with conventions, if there is one in the ruby communicty
<shevy>
I sometimes removed @ivars when they store too much data
<Boohbah>
Solnse: if you are worried about saving memory then maybe ruby is the wrong choice :)
<shevy>
and when I do pp object, it's overflowing my screen
<Solnse>
Boohbah: i'm not worried about it.
Sthebig has joined #ruby
<shevy>
excellent!
<LadyRainicorn>
Yeah, ivars are different.
<Solnse>
pp!
<LadyRainicorn>
But like local variables no
<csmrfx>
or
<LadyRainicorn>
Assign to nil if you really must get rid of the memory.
<shevy>
how about global variables
<csmrfx>
could you actually use ruby to write programs that do not use much of ram?
<Boohbah>
man, irb does not like my arrow keys anymore :(
<Solnse>
page = agent.get @signin_page then after inputting credentials, it seems a waste to store result_page = agent.post(blahblabh) in a new variable...
<shevy>
the dead ants between the arrow keys interfere
<LadyRainicorn>
If 0.0**0.0 was 0.0 I would of had to make a /r/lolruby.
wallerdev has quit [Quit: wallerdev]
<shevy>
the redditers hate ruby
danshultz has joined #ruby
<shevy>
it's a python snake storm there
maximski has joined #ruby
<LadyRainicorn>
haha I don't hear much about Ruby on Reddit.
<Boohbah>
0 is a multiple of everything
krz has quit [Quit: WeeChat 0.4.3]
<LadyRainicorn>
I'm subscribed to /r/ruby, but it never makes it to my frontpage.
benzrf is now known as benzrf|offline
razrunelord has quit [Remote host closed the connection]
<shevy>
:(
<shevy>
we need another hype
<shevy>
something like rails
<shevy>
but new
<shevy>
and BIGGER
<LadyRainicorn>
superrails
bthesorceror has quit [Remote host closed the connection]
datafirm has quit [Quit: datafirm]
SegFaultAX has joined #ruby
maximski has quit []
jumblemuddle has quit [Quit: Death]
gf3 has quit [Ping timeout: 258 seconds]
GeorgesLeYeti has joined #ruby
<GeorgesLeYeti>
HI
jumblemuddle has joined #ruby
<Hanmac>
shevy lets make an "all" gem ... one gem that depends on all other gems ;P
<shevy>
Hanmac hehe
<mordof>
..... Hanmac wha... lol
<mordof>
why!?
* mordof
just walked in
<shevy>
I need something that pulls in all dependencies, then packages stuff up in a standalone gem
<mordof>
shevy: ah
gf3 has joined #ruby
<wmoxam>
shevy: make a Rails rival
<havenwood>
shevy: it could just have a `spec.runtime_dependency` in `all.gemspec` for each gem
<wmoxam>
so we can go back to the good ol' days of Merb vs Rails flamewars
ldnunes has joined #ruby
<shevy>
wmoxam hmm... I could probably make a rival for some components, but rails is kinda huge, I don't think I have the motivation to want to replace or challenge all of it :(
<atmosx>
Merb... what's the flamewar about? lines o fcode
<atmosx>
?
ascarter has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<eval-in_>
mordof => 1 applesString can't be coerced into Fixnum (TypeError) ... (https://eval.in/146862)
<mordof>
toretore: makes more sense this way
<toretore>
why?
Kricir has quit [Remote host closed the connection]
<mordof>
toretore: because you have to tell it to be a string first
<aedorn>
implicit vs explicit
<mordof>
then it's clear
<toretore>
`1 . " apples"` is clear
<toretore>
it can't mean anything other than "concatenate 1 and " apples" as a string"
<mordof>
well
<toretore>
because . is only used for string concatenation
<mordof>
that depends on which item PHP decides to coerce, lol
<aedorn>
Only if you aren't new to it, though. But I suppose the same could be said for everything.
<toretore>
no, there is no ambiguity
sski has joined #ruby
<toretore>
it will cast the number
<toretore>
because . is *string* concatenation
<toretore>
it's not the same as +
<mordof>
no i know
saarinen has joined #ruby
jackneill has quit [Quit: WeeChat 0.4.3]
<mordof>
i'm just going based off of some other *very* strange coercion that PHP does in different scenarios. i know this particular one is relatively straightforward
benzrf|offline is now known as benzrf
alem0lars has joined #ruby
claymore has quit [Quit: Leaving]
tjsousa_ has joined #ruby
IceDragon has joined #ruby
davispuh has quit [Read error: Connection reset by peer]
ascarter has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
crucify_me has joined #ruby
geggam has joined #ruby
pothibo has joined #ruby
combusean has joined #ruby
centipedefarmer has quit [Ping timeout: 258 seconds]
xorgnak_ is now known as xorgnak
terrell_t has joined #ruby
<snkcld>
are there any gems out there that allow one to inspect database tables etc? eg iterate over a tables fks, pks, and just get information regarding a schema and data?
ascarter has joined #ruby
michaeldeol has joined #ruby
pothibo has quit [Client Quit]
kevind_ has joined #ruby
LadyRainicorn has quit [Ping timeout: 265 seconds]
crystal77 has quit [Quit: Computer has gone to sleep.]
datafirm has joined #ruby
<atmosx>
snkcld: sequel and irb/pry
terrellt has quit [Ping timeout: 252 seconds]
LadyRainicorn has joined #ruby
<atmosx>
snkcld: install sequel, then the driver (e.g. mysql) and then require 'sequel' and 'mysql' on an 'irb' session.
<atmosx>
or write small scripts which query the db.. whatever works for you
<snkcld>
atmosx: awesome!
sambao21 has joined #ruby
<atmosx>
you can build a custom DSL if you want
<snkcld>
yea, im writing custom sql to find foreign keys atm
krazh has quit [Remote host closed the connection]
gigetoo has quit [Remote host closed the connection]
franzip has quit [Quit: ...]
kevind has quit [Ping timeout: 240 seconds]
kevind_ is now known as kevind
krazh has joined #ruby
terrell_t is now known as terrellt
<atmosx>
snkcld: you are using activerecord
aross_ has quit [Remote host closed the connection]
aross_ has joined #ruby
alem0lars has quit [Quit: Going AFK...]
<shevy>
guys
<shevy>
I need to combine ruby with one of these languages:
<shevy>
java/c/c++
<shevy>
which one to pick?
<Hanmac>
c or c++
<benzrf>
c
gigetoo has joined #ruby
<benzrf>
maybe java
<benzrf>
wait yeah java
CaptainKnots has quit [Ping timeout: 246 seconds]
<shevy>
Hanmac only one is possible, so an "or" is not helpful hehehe
<shevy>
with java I could use jruby
<benzrf>
c & c++ have low-level semantics that dont always play well with hi level stuff
<atmosx>
why do you need to do that?
<benzrf>
java is already gc'd and oo
<atmosx>
gc'd?
<benzrf>
2 big points
<benzrf>
garbage collected
<shevy>
atmosx well competitive advantage, like 30% of the job listings in bioinformatics want java
<shevy>
the only drawback is that I can't stand java
<baweaver>
Scala or Clojure then
<atmosx>
shevy: language is not important
Sirupsen has quit [Ping timeout: 250 seconds]
<atmosx>
atmosx: You'll pick up java really quickly
<baweaver>
All the hip new companies are using them, and they're a heck of a lot better.
<atmosx>
if you have to
<atmosx>
it's OO the concepts are the same
maximski has joined #ruby
<baweaver>
java is painful
supermarin has joined #ruby
<shevy>
well
<shevy>
java kinda seems boring :(
<baweaver>
too much boilerplate
<baweaver>
Scala and Clojure both run on the JVM
<baweaver>
both are functional
<atmosx>
shevy: it's just a tool like ruby :-P
<baweaver>
Scala is more of the syntax you'd be useful
<baweaver>
Clojure is a Lisp
crucify_me has quit [Remote host closed the connection]
aross_ has quit [Ping timeout: 240 seconds]
mattmcclure has joined #ruby
<baweaver>
Yes, it's a tool, but lord help you if you try and use hedge clippers to cut down a redwood
<baweaver>
there's such a thing as a wrong tool
<shevy>
atmosx I don't believe in "just a tool"
<shevy>
or "use the right tool for the job"
alem0lars has joined #ruby
<toretore>
but you don't know what the job is yet..
<baweaver>
as opposed to....
<shevy>
toretore no restrictions
<atmosx>
shevy: that's what a programmer is all about though, you shouldn't be stuck to one language
<toretore>
could be a hedge
<RubyPanther>
shevy: I agree, but mostly because of the word "the"
<atmosx>
s/stuck/glued
<shevy>
atmosx I am not a "programmer" though
enilsen161 has joined #ruby
<atmosx>
shevy: maybe you should become one then :-P
<shevy>
nope, I actually hate computers
<atmosx>
oh
<atmosx>
I seee
<toretore>
lots of "advice" about an unknowm problem
<RubyPanther>
There are lots of "right" tools
<shevy>
php
<atmosx>
toretore: easiest way to look smart lol
<shevy>
shell scripts
axl_ has quit [Quit: axl_]
enilsen161 has quit [Client Quit]
ce_afk is now known as cescalante
<baweaver>
If a large portion of jobs are wanting java / jvm, then it makes sense to learn that area
noop has quit [Ping timeout: 250 seconds]
<baweaver>
and the up and coming tasks in biomed are big data driven
enilsen16 has joined #ruby
<RubyPanther>
PHP is a great tool. How do I know? People use it to build stuff. Some of it is even good stuff.
<toretore>
atmosx: quite the opposite in my view
<baweaver>
which are inherently functional problems
<baweaver>
which is why I mention those.
<RubyPanther>
There is no such thing as an "inherently functional problem" outside of academics.
zachallett has quit [Remote host closed the connection]
enilsen16 has quit [Client Quit]
jtdowney has joined #ruby
<atmosx>
toretore: anyway the issue in question is that ruby needs to use a new language because it suits the area of his future job (if he doesn't become a pharmacist in the meantime)
<RubyPanther>
functions are an entirely arbitrary human construct
<shevy>
I guess I'll hang out on #jruby to see if they appear clever or not
supermarin has quit [Ping timeout: 258 seconds]
<atmosx>
shevy: I'd just get a book and learn java
<RubyPanther>
if you think you see "functions" in the Problem Domain, you've probably got some reflection issues
razrunelord has joined #ruby
<atmosx>
shevy: ton's of libraries for JV and pays well
<shevy>
atmosx ewww buuut...
<shevy>
it's so verbose! :(
<toretore>
RubyPanther: yeah, you should obviously be seeing objects
afex has joined #ruby
<toretore>
/he/
jtdowney has quit [Client Quit]
<atmosx>
shevy: + learning a new language might help you become a better rubyist too
<RubyPanther>
toretore: Sure, I get reflection too, and mine shows me objects. ;)
<benzrf>
learn haskell!
<benzrf>
haskell is great
<baweaver>
+1 haskell
horsecowdog has quit [Remote host closed the connection]
<toretore>
but the curly haired man says objects are evil!
<baweaver>
scala if you're going for immediately practical
<RubyPanther>
The Problem Domain should rightly only consist of inputs, outputs, and transformations. These same things can be expressed as behaviors.
<baweaver>
more jobs out there, much of the same concepts apply. Haskell is just far more rigid about being functional.
<atmosx>
hm
mark_locklear has quit [Ping timeout: 265 seconds]
n0n3 has joined #ruby
<atmosx>
I need to restart tor shit.
<shevy>
I haven't seen a job listing even mentioning haskell yet
<atmosx>
shevy: about bio-informatics?
<shevy>
yeah
<atmosx>
shevy: all I see is python
<RubyPanther>
Functions, objects, methods, structured programming generally, it is entirely arbitrary constructs that reflect the intersection of the needs of the machine and the programmer; not the problem domain.
<shevy>
yeah :(
<atmosx>
shevy: then stick with python
<shevy>
atmosx though it is more generic here usually "a scripting language like python/perl" and when they mention that, ruby covers that
<shevy>
what for would I need python
<shevy>
I have ruby :P
<atmosx>
shevy: yeah, true
xorgnak has quit [Remote host closed the connection]
toastynerd has joined #ruby
<shevy>
another requirement often mentioned is R
<RubyPanther>
shevy: Like Larry Wall said when they asked him what languages you should know about; you should know about Haskell because it is for geniuses, and that is important to know in case you want to hire people to use it
<baweaver>
statistics
<shevy>
yeah baweaver :(
<baweaver>
R was kinda annoying when I learned it.
<RubyPanther>
Presumably if you have to hire those sorts of people you just go straight to a recruiter and don't bother listing it
<RubyPanther>
R sucks, too bad it is such a great tool
elaptics`away is now known as elaptics
<shevy>
baweaver well I'll bullet, I am learning R since like two months... at least it can generate pretty graphics
n0n3 has quit [Client Quit]
<baweaver>
I was using it for aggregate statistics on data from ~1000 wireless subscriber units
<baweaver>
so I had immediate practical use in learning int
<baweaver>
it
<benzrf>
RubyPanther: i mostly grok haskell and im not even a college student
codabrink has joined #ruby
<benzrf>
i guess i must be a super double genius!!!!
<benzrf>
(or maybe it is not that bad??)
<RubyPanther>
benzrf: or a kid
<baweaver>
still annoying though, not very interfaceable.
<baweaver>
benzrf: first language or what did you start with?
<RubyPanther>
like any language, including natural languages, kids can learn them easy. Even dumb kids.
<shevy>
benzrf is dumb?
<benzrf>
baweaver: first lang = true basic
obscured has quit [Quit: leaving]
<baweaver>
or rather what's your proficiency with math
<benzrf>
p decent
<benzrf>
but most of the math higher than simple algebra i know is from random wikipediaing
<benzrf>
so p incomplete
danijoo_ has quit [Ping timeout: 252 seconds]
<baweaver>
most people that start with an algol-like language have a harder time adapting as they keep trying to put haskell in java terms
terrellt has quit [Remote host closed the connection]
<baweaver>
which will screw your head all types of bad.
<benzrf>
precisely
dunckr has quit []
<baweaver>
if you try and analog it, you'll fail
<benzrf>
:^)
<RubyPanther>
I didn't mean he's dumb, I meant young people learning languages doesn't tell you anything about if the language is easy, or if it takes a "genius" to do something useful with it
<benzrf>
*analogue?
<benzrf>
RubyPanther: pfft nice try dude
terrellt has joined #ruby
<baweaver>
Monday actually
mary5030 has quit [Remote host closed the connection]
<RubyPanther>
I'd certainly trust Larry Wall, a talented linguist, to be able to measure and compare complexity more accurately.
<RubyPanther>
For example people say Perl is hard, and he points out Japanese is much more complicated than Perl.
<shevy>
actually
<shevy>
japanese often makes more sense than perl
<baweaver>
much of anything makes more sense than perl
<shevy>
larry wall is a child of the 1980s
<RubyPanther>
I don't want to learn Japanese to speak to my computer. I want to keep it more on the level of, "ugga ugga, input output"
<shevy>
you don't write "ugga ugga, input output" in perl
metamaterial has quit [Remote host closed the connection]
<RubyPanther>
No, Larry Wall was already a secret government linguist in the 80s.
<shevy>
it's more like &/§"/&)"&/! N&/!)? !&
<baweaver>
(that being said Perl was one of my first few languages)
<RubyPanther>
shevy: That's why I switched to Ruby!
<shevy>
baweaver did you ditch it :(
<RubyPanther>
my Perl was too expressive.
<baweaver>
Ruby won
<shevy>
hehe
<shevy>
ruby vs. perl
<RubyPanther>
Ruby is so simple, my future me and past me can both understand it.
<shevy>
is like a pretty girl vs. an old man
<baweaver>
I can still use Perl fine, almost to level with Ruby, but I vastly prefer Ruby
<yxhuvud>
RubyPanther: parsing perl is np hard though, so claiming japanese is harder seems like a silly claim.
<shevy>
just not fair
<shevy>
RubyPanther pfft future you, what if you will have alzheimer
<RubyPanther>
yxhuvud: Interesting that you broke out the parsing, which should be the least difficult part of a language
aross_ has joined #ruby
<RubyPanther>
shevy: Then I probably won't even know I wrote code, or be re-reading it
<shevy>
well you could do it like in the movie memento
<shevy>
for programmers
<shevy>
make tattoos of code onto your body
<RubyPanther>
Anyways, I am an active chess player, that is known to be protective against Alzheimer's.
<shevy>
then when you wake up, you can remember the code!
<RubyPanther>
I'd be more worried about developing dementia and reverting to COBOL in the middle of a method...
<benzrf>
haskell is great, youre just dumb
<benzrf>
-smug-
<mordof>
oh dear.. lol
LadyRainicorn has quit [Quit: Bye]
<RubyPanther>
benzrf: In another 10 years you'll understand that being a language for geniuses is not a compliment, it is a major insult.
michaeldeol has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
imkmf has joined #ruby
Morkel_ has quit [Quit: Morkel_]
michaeldeol has joined #ruby
jsutch has quit [Read error: Connection reset by peer]
Hanmac1 has joined #ruby
x1337807x has joined #ruby
<RubyPanther>
Maybe sooner than that. My CS-1 class I had a professor who spent the whole first day ranting about "genius-level programming" and how it was the worst code you could possibly write, much worse than broken buggy code.
razrunelord has quit [Remote host closed the connection]
<toretore>
that depends on the definition of "genius"
metamaterial has joined #ruby
<toretore>
the way you use it sounds like it's sarcastic and not actually genius
Kricir has quit [Ping timeout: 252 seconds]
<RubyPanther>
toretore: by the time you twist it around to be positive, it won't match a dictionary
combusean has quit [Ping timeout: 258 seconds]
<benzrf>
RubyPanther: i never said it was a compliment
<benzrf>
o=
<toretore>
the way ruby metaprogramming is "genius"
Hanmac has quit [Ping timeout: 245 seconds]
<RubyPanther>
No. It is deeper than that. Your genius code probably even works. What happens when somebody else tries to add a feature? They have to THROW IT ALL AWAY
<benzrf>
anyway haskell is cool & not genius so there
<SegFaultAX>
The problem with Haskell isn't that it's a "genius" language, it's that it requires re-learning how to think about programming.
<benzrf>
RubyPanther: yes i understand your point
<benzrf>
/ROLLS EYES
<RubyPanther>
That is why it is worse than bad code
<apeiros>
if it wasn't RubyPanther, I'd actually bite.
<SegFaultAX>
So especially if you've been in industry for a while, that becomes increasingly difficult to do.
<benzrf>
hey SegFaultAX i feel like ive seen you in another channel
<RubyPanther>
apeiros: if it wasn't true, so would I
<toretore>
RubyPanther: why would they have to throw it all away?
<benzrf>
man RubyPanther is so full of shit
atmosx has quit [Quit: WeeChat 0.4.4-dev]
<SegFaultAX>
benzrf: Probably, I'm in lots of channels. ;)
<benzrf>
so full of shit man
paulfm has quit []
<RubyPanther>
toretore: Because 100% of programmers are not geniuses!
<benzrf>
SegFaultAX: do u hang out (or used to) in #python
Milly_Bays has quit [Quit: Leaving]
<SegFaultAX>
benzrf: For the last 10 years, yes. :D
<benzrf>
o-o
<toretore>
RubyPanther: i assume some level of expertise, and more importantly, a willingness to learn
<benzrf>
used to frequent there back when i used python regularly
imkmf has quit [Client Quit]
<toretore>
depending on the level of "geniusness" i think that's appropriate
<RubyPanther>
And if you systemically will accept genius-level-programming, then even if you only hire geniuses, some are genius in different ways, and they still can't use each other's code
mjsmith2 has quit []
sunya7a__ has joined #ruby
sunya7a_1 has joined #ruby
mjsmith2 has joined #ruby
<SegFaultAX>
The term "genius" is not meaningful in this context. The issue is you're arguing with flawed or ill-defined terminology.
axl_ has joined #ruby
<toretore>
yes
<RubyPanther>
Note that geniuses are not bad. But genius code is bad. A genius human should be writing simple code; they should see the problem domain well enough not to even want genius code. Except when they're young and trying to prove themselves, then it is just human nature to write that crap.
crucify_me has joined #ruby
sambao21 has quit [Quit: Computer has gone to sleep.]
<toretore>
RubyPanther: again, it depends on what you mean by genius
<apeiros>
"genius. noun. people who write code others don't understand."
<apeiros>
apparently
<RubyPanther>
toretore: Right, but the normal process in that case is to converge on the meaning that makes sense, the meaning in which the statement is true. ;)
djbkd has quit [Remote host closed the connection]
<toretore>
the geniusest is the programmer who is able to express a complex program in such simple terms that it's easily understandable by most people
<SegFaultAX>
apeiros: Doesn't require a genius to do that. ;)
bthesorceror has quit [Remote host closed the connection]
<RubyPanther>
If you run straight to the meaning where it isn't true, you're probably misunderstanding a person rather than even attempting to refute them
<toretore>
i don't assume anything about your definition of the term
<Solnse>
how do I use regex to search a nokogiri document? I keep getting undefined method `match' for #<Nokogiri::HTML::Document:
<RubyPanther>
benzrf: According to you. According to Larry Wall, you'll have to hire more expensive programmers to do the same thing as in another language.
atmosx has joined #ruby
<SegFaultAX>
RubyPanther: I can't argue something that hasn't been well-defined. And you keep moving the goal post.
<toretore>
Solnse: you don't?
mary5030 has joined #ruby
sunya7a_ has quit [Ping timeout: 264 seconds]
sunya7a has quit [Ping timeout: 264 seconds]
<RubyPanther>
SegFaultAX: I propose it is already well defined by dictionaries, and that I am using words withing the bounds of their English meanings.
<Solnse>
toretore: there must be a way, i've done it before.
kyb3r_ has joined #ruby
freezey has joined #ruby
zcreative has quit [Quit: Computer has gone to sleep.]
<SegFaultAX>
RubyPanther: "genius (noun) - exceptional intellectual or creative power or other natural ability"
<toretore>
Solnse: perhaps you could enlighten us on exactly what problem you're trying to solve?
Macaveli has quit [Ping timeout: 252 seconds]
<shevy>
so a creative person is a genius
crystal77 has joined #ruby
mary5030 has quit [Remote host closed the connection]
<SegFaultAX>
RubyPanther: There are so many ways that could apply to programming it's almost meaningless without further clarification.
djbkd has joined #ruby
<RubyPanther>
SegFaultAX: Right. So genius-level-code is code that requires "exceptional intellectual or creative power or other natural ability"
sambao21 has joined #ruby
<SegFaultAX>
RubyPanther: That's one way to interpret it.
mary5030 has joined #ruby
<Solnse>
I'm searching through an html document for a specific value I need, however it doesn't have any uniquely identifying id or class, so I need to use regex to include nearby text in the match.
<RubyPanther>
So see it turns out there was no barrier to understanding; the most straightforward meanings lead directly and precisely to the intended point.
sunya7a__ has quit [Ping timeout: 252 seconds]
<benzrf>
SegFaultAX: ive had this argument with him before
<benzrf>
he's completely nuts
<toretore>
Solnse: is the value text or an element?
sunya7a_1 has quit [Ping timeout: 265 seconds]
<Solnse>
yes, text
<benzrf>
he claims FP is unintuitive and inherently less useful than OOP
the_f0ster has quit [Ping timeout: 258 seconds]
<RubyPanther>
Nonsense
<SegFaultAX>
RubyPanther: There are other interpretations of genius level code. It's my opinion that there are other useful interpretations.
<toretore>
Solnse: you could just convert it to a string
<toretore>
probably not super efficient
speakingcode has quit [Ping timeout: 240 seconds]
soulashell has joined #ruby
<SegFaultAX>
Such as: "genius-level code" is code that has been simplified to such an extent that all reasonable accidental complexity has been eliminated.
NukePuppy has quit [Ping timeout: 245 seconds]
x1337807x has quit [Ping timeout: 252 seconds]
<RubyPanther>
I only claimed that FP is disgusting and awful. I did not claim that is less useful. That is an abstract claim that could only be rightly made in a specific case.
<SegFaultAX>
If you've been writing code for a while, you might know that such a feat is indeed enormously challenging.
<toretore>
SegFaultAX, RubyPanther: i think genius level code is quite subjective, and to me it does not mean incomprehensible to a non-genius
<toretore>
"disgusting and awful" are very precise terms
<SegFaultAX>
RubyPanther: Interesting, why do you feel that way?
<SegFaultAX>
(About FP in particular, that is)
<RubyPanther>
SegFaultAX: No, that is code written by a genius; it doesn't require genius, and so it clearly not "genius-level code." If any idiot programmer can understand it, nobody is going to confuse it with "genius-level-code" unless they are being intentionally obtuse.
<toretore>
RubyPanther: that is your own definition of the term
<RubyPanther>
toretore: I agree it is subjective, but not that it can mean anything. It still means generally what I claimed it to mean; and obviously so.
<Sawbones>
it's when I call `require data_mapper` and I create a mysql setup
<toretore>
RubyPanther: i disagree
<benzrf>
Sawbones: do you have the gem installed
<RubyPanther>
SegFaultAX: Like I said, I'm using dictionary definitions.
<Solnse>
I'm trying to grab that 400
<SegFaultAX>
RubyPanther: Why do you find FP disgusting, out of curiosity.
<benzrf>
SegFaultAX: because he is a nutbar
<benzrf>
no reasoning with him
<benzrf>
absolutely bonkers
imkmf has joined #ruby
<SegFaultAX>
RubyPanther: Your definition does not follow from the definition I gave you above.
<SegFaultAX>
benzrf: That's not helpful.
<RubyPanther>
If there is a mismatch in definitions even AFTER I explain which definition I am using, that is getting into "intentionally refusing to understand" territory.
<SegFaultAX>
No reason to resort to ad hominem.
Synthead has quit [Ping timeout: 246 seconds]
<toretore>
Solnse: i think using xpath would result in a more robust solution to the problem
<benzrf>
SegFaultAX: sounds like SOMEBODY misunderstands 'ad hominem'
<RubyPanther>
SegFaultAX: Don't worry, it is just a schtick he does; "don't listen to the old guy, he doesn't know anything!" It is his duty as a kid to oppose old people.
<combusean>
hey benzrf, havenwood =)
ascarter has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
momomomomo has quit [Quit: momomomomo]
phutchins has quit [Ping timeout: 252 seconds]
<SegFaultAX>
benzrf: And I quote "he is a nutbar"
<shevy>
well you could focus on a nutbar or on the arguments, I am sure he must have given arguments as to why FP is idiotic
aross_ has quit [Remote host closed the connection]
<SegFaultAX>
benzrf: That is precisely the example given for ad hominem.
<SegFaultAX>
benzrf: s/nutbar/asshole/
<havenwood>
combusean: hi
<RubyPanther>
I'm not even convinced "nutbar" is an insult.
<benzrf>
uh what
<benzrf>
where is the example
<shevy>
s/asshole/rapist-murderer/
<combusean>
shevy, :)
<toretore>
baby serial killer
<SegFaultAX>
benzrf: Cmd+F "asshole"
<shevy>
RubyPanther you stupid nutbar!
aross_ has joined #ruby
<shevy>
toretore omg that is even worse
<benzrf>
SegFaultAX: that's not an ad hominem example
<benzrf>
u actually reading the article?
<shevy>
come on guys
andrewlio has joined #ruby
<shevy>
let's argue about FP
<havenwood>
anyone TL;DR this conversation for me? :P
<toretore>
shevy: but is it a baby who is a serial killer or a serial killer who kills babies? and which is worse?
troulouliou_dev has joined #ruby
<RubyPanther>
The nutbar was simple, stupid, and tasty. If I find one that is smart, I'm gonna throw it right out the window.
<benzrf>
insulting somebody is not ad hominem
<shevy>
havenwood they have an argument; RubyPanther said that FP kills babies, benzrf thinks that the whole world should be built on haskell
<toretore>
tl;dr: people have differing opinions
matcouto has joined #ruby
<benzrf>
saying somebody is wrong for reasons having to do with them that are irrelevant
<benzrf>
IS ad hominem
<shevy>
I think benzrf is not really wanting to argue :(
<benzrf>
i never said RubyPanther is wrong because he is a nutbar
tvw has quit []
<toretore>
fp is unnatural
<benzrf>
i said it is not worth arguing with him because he is
ldnunes has quit [Quit: Leaving]
<benzrf>
:^)
<havenwood>
it isn't unnatural!
<toretore>
it's just not the was computers work
unyo has joined #ruby
<benzrf>
toretore: neither is objects
<toretore>
it shouls be outlawed
<shevy>
ok benzrf gave up early
<RubyPanther>
It was an ad hominem, because he said "no reasoning with him," attacking generally anything I say based on who I am. The part about the nutbar was not one, though.
<shevy>
RubyPanther won, I now agree with him FP is <RubyPanther> I only claimed that FP is disgusting and awful.
<shevy>
DISGUSTING and AWFUL!
<shevy>
hear me benzrf
<shevy>
I am unsure about the arguments but hey
s2013 has joined #ruby
<crucify_me>
hi I see how line 10 returns matz's singleton object, so if you access the singleton object in the snippet below on line 1, why is metaclass just a string when "abc" is returned? sorry to havenwood I still don't quite get this: http://pastie.org/9143818
<SegFaultAX>
RubyPanther: Still waiting to hear your arguments for/against fp.
<RubyPanther>
Please note that I only mean "awful" in the subjective sense as being unpleasant, not in an objective sense as being broken.
relix has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
aross_ has quit [Ping timeout: 240 seconds]
<RubyPanther>
SegFaultAX: I'll tell you 99% of it; Ruby is wonderful, I choose Ruby. Ruby is not FP. This is #ruby. Therefore, FP is the wrong tool, and tastes like [bleep].
<RubyPanther>
SegFaultAX: I once wrote this awful Perl code to generate some FP for me, to avoid writing the (much simpler) scheme code directly. I also took the time to insult by calling it lisp in my code. https://gist.github.com/rubypanther/56688a2a70a882bafd16
<RubyPanther>
I would rather write bad Perl than good FP. And I'm an emacs user!
<havenwood>
crucify_me: the `class` keyword is returning the `"abc"` in from its definition block
imkmf has joined #ruby
<benzrf>
that doesnt mean fp is bad
<benzrf>
it means you suck
<RubyPanther>
The one good use of FP: configuring emacs from ~/.emacs
<benzrf>
:^)
kirun has quit [Quit: Client exiting]
<crucify_me>
so the return value overrides the assignment of matz's singleton object to metaclass... but that is only momentary? havenwood apeiros
<apeiros>
crucify_me: …
<toretore>
RubyPanther: do you have any arguments other than "i don't like it"? i'm curious
<apeiros>
crucify_me: no
sambao21 has quit [Quit: Computer has gone to sleep.]
failshell has quit [Ping timeout: 250 seconds]
<apeiros>
crucify_me: you could just as well write: metaclass = "foo" # no, you don't assign a metaclass
<RubyPanther>
toretore: Not really, no. Like I said, I didn't claim it is not a useful tool; I only claimed it is an unpleasant tool. I do think objectively that so few people like the tool that that makes it a poor business choice to select the tool, outside of personal projects.
<SegFaultAX>
RubyPanther: I am now entirely convinced that we have very different notions of functional programming.
<havenwood>
crucify_me: you continue to expect that a class keyword definition block will return self instead of the return value from its definition block, when that just isn't how it works
<SegFaultAX>
RubyPanther: Thank you for your perspective.
<apeiros>
>> obj = Object.new; class <<self; 123; end
<apeiros>
it does NOT MATTER that you wrap class << self; …; end around your expression. it will return the expressions value.
<RubyPanther>
SegFaultAX: I try not to go deeper in than 5 or 10 parens, so I'll never really have an authentic notion of FP
sdouglas has joined #ruby
<toretore>
RubyPanther: well. "poor business choice" doesn't really count for me
<apeiros>
crucify_me: the point is that *self* is the metaclass, *within* that class << self; …; end expression
<havenwood>
crucify_me: metaclass = puts 'not a metaclass, just what puts returns'; metaclass #=> nil
<SegFaultAX>
RubyPanther: What do that have to do with FP?
<apeiros>
crucify_me: hence you want the value of self to be returned
<SegFaultAX>
RubyPanther: Or have you moved on to full-on trolling?
<apeiros>
crucify_me: and you do that by simply having it be the last statement
SCommette has joined #ruby
<toretore>
RubyPanther: i'm more interested in fp's "purity" and the abstractions it provides over other paradigms
<RubyPanther>
SegFaultAX: No, trolling is saying something to get a response. What I did was take a pot-shot to make myself laugh.
<SegFaultAX>
RubyPanther: Understood. Thank you.
<havenwood>
crucify_me: metaclass = class AnEmptyBlockIsNil; end; metaclass #=> nil
<toretore>
RubyPanther: and i know lots of people who do think it's pleasant and a good business choice
<RubyPanther>
toretore: I'm not convinced that pure FP can do anything useful, unless you winnow down "pure" a fair bit. My understanding is that there is a good amount of debate in FP over what the basic principles are, and if they have to be violated for pragmatic reasons, or if they are less strict than the violators claim
<RubyPanther>
toretore: I certainly didn't mean to imply it has no good business case
<toretore>
RubyPanther: what kinds of violations are you referring to?
<toretore>
side effects?
<RubyPanther>
Just that as a general purpose language, it is a poor business choice.
<havenwood>
crucify_me: TL;DR: Do not assign a variable to the output of a `class` keyword definition block. You can get around the `class` behavior by not using it like apeiros showed.
<RubyPanther>
yeah, side effects and state
<crucify_me>
so the operator class << matz is setting singleton object to metaclass, but this just returns 'abc' since it is the last expression. But we are not manipulating the singleton object by accessing it with << havenwood apeiros
<apeiros>
crucify_me: "so the operator class << matz is setting singleton object to metaclass" <-- eh? no
<crucify_me>
though metaclass is not a keyword apeiros havenwood
<apeiros>
same thing
<RubyPanther>
I was on Team Metaclass, but we lost.
s3ri0us has joined #ruby
<apeiros>
crucify_me: and who said it was?
<toretore>
RubyPanther: obviously, a system without side effects isn't of much use. but i think that sticking to those principles where it is possible can have benefits
<RubyPanther>
toretore: that sounds more pragmatic than pure
<toretore>
sure
<havenwood>
RubyPanther: in dabbling i've found functional langs like clojure and haskell to be remarkably elegant and expressive
michaeldeol has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<toretore>
like "pure" oop
sambao21 has joined #ruby
metamaterial has joined #ruby
<crucify_me>
no one at first I assumed it was then I assumed it was a variable
razrunelord has joined #ruby
<RubyPanther>
as long as you're willing to ignore the parts that suck, using FP won't hurt. ;)
supermarin has joined #ruby
<apeiros>
crucify_me: and no, it's not about the '<<' in 'class << some_obj'. it belongs together with class. 'class <<' is a thing. '<<' on its own is not (well, it is, but that's got nothing to do with metaclasses)
<toretore>
i'm not sure i understand which parts suck
razrunelord has quit [Client Quit]
<apeiros>
crucify_me: the metaclass is a class
<apeiros>
crucify_me: and just like non-metaclass classes, if you want to add instance methods to it, you need to open it
<havenwood>
crazedpsyc: `class` followed by whatever will still return the return value of its definition block, so don't assign to it!
krazh has quit [Remote host closed the connection]
<apeiros>
crucify_me: and so just like there's syntax to open a class and add instance methods to it, namely: `class Foo; def i_am_an_instance_method; …; end; end`
<RubyPanther>
havenwood: When you say "expressive" I think Perl, and then I think, egads, no, I do not want to look at expressive code my past-self found aesthetically pleasing. I'd rather look at finger paintings from my childhood.
anaeem1 has quit [Remote host closed the connection]
krazh has joined #ruby
<apeiros>
crucify_me: there's also syntax to open the metaclass, namely: `class << Foo; def i_am_an_instance_method_too!; end; end`
s2013_ has joined #ruby
<havenwood>
RubyPanther: expressive as in expressing something clearly and openly
<RubyPanther>
Give me an expressive enough language, I won't even know if I wrote a year later without checking the filename
beef-wellington has quit [Ping timeout: 264 seconds]
<toretore>
havenwood, RubyPanther: with time, i value "expressiveness" less and less
sdouglas has quit [Remote host closed the connection]
<apeiros>
crucify_me: and just like *classes* are objects (x = Array; x.new # => []), metaclasses (being classes) are objects too
<apeiros>
crucify_me: and because obj.singleton_class was only added in ruby 1.9, people needed a way to get at that metaclass object
<toretore>
what matters is what's on the inside
<RubyPanther>
I enjoy actually writing expressive code. It is the most fun way to write code. But I do not enjoy finding said code in my repo later.
testcore has joined #ruby
<apeiros>
crucify_me: and because `self` within a class body is the class itself, and because class bodies return their last evaluated expression, people did just that: open the metaclass, and return self (which at that point *is* the metaclass)
<toretore>
i find that "expressiveness" often comes at a cost of quality
<apeiros>
so: obj.singleton_class --> def singleton_class; class << self; self; end; end
<havenwood>
RubyPanther: I think that the promises of OO being the One True Way are overblown, and FP is an entirely workable paradigm.
<apeiros>
hth
end_guy has joined #ruby
<toretore>
example: fuken "dsl"s
<apeiros>
that's about as exhaustive an explanation as I can give
<crucify_me>
apeiros: holy smokes
s2013 has quit [Ping timeout: 240 seconds]
<toretore>
havenwood: but then you have those who think fp is the one true way and wouldn't touch a mutable data structure with a 10 foot pole
supermarin has quit [Ping timeout: 245 seconds]
<apeiros>
oh, one thing I omitted, proof of "self within class is the class":
<crucify_me>
apeiros: thank you I will pour over this .. thanks havenwood
<RubyPanther>
havenwood: I don't want to do everything using OOP because it is the One True Way, only because I'm not disciplined, and my tendency is towards complex expression and not towards simplification.
<havenwood>
toretore: Can't we just have two nice ways? :O
cescalante is now known as ce_afk
<toretore>
no. there can only be one winner!
* havenwood
queues the Highlander music.
<apeiros>
toretore: but you know that hodor always wins?
<toretore>
ssh, i'm just about to watch the latest episode
jack_rabbit has quit [Ping timeout: 252 seconds]
<RubyPanther>
People who are "mathematically-minded" probably can get similar benefits from FP that I get from OOP
<apeiros>
oh, sorry, I thought you already knew he was the secret dragon lord
<apeiros>
html is for people who can't be arsed to write valid markup
rezzack has quit [Quit: Leaving.]
<toretore>
closing tags is SO MUCH WOOOORK
michaeldeol has joined #ruby
<RubyPanther>
yay! new computer! byeeeeee
RubyPanther has quit [Quit: self.exit(:stage=>:left)]
<apeiros>
toretore: also user input!!! what do we do about invalid user input!!! oh noes! we can't have fora in xhtml because there will be invalid userinput!!!!
s2013_ is now known as s2013
instantaphex has quit [Ping timeout: 250 seconds]
<apeiros>
I almost shat bricks when I read that argument
<toretore>
goddamnit now you made me think of all the stupid people in the world
<toretore>
time for a beer
<apeiros>
oh, good idea
<apeiros>
s/beer/grappa/
jonno11 has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<metamaterial>
i did rvm implode, then brew install rbenv ruby-build rbenv-gem-rehash & rbenv install 2.1.1 & i get make: *** [build-ext] Error 2. help?
<shevy>
popl man there is too much sex in that scene
<popl>
shevy: There's no sex at all in that scene.
<shevy>
wat
<shevy>
look at it!
<popl>
shevy: That's a depiction of Mayan ritual enema.
<shevy>
a sexy ritual
cpruitt has joined #ruby
<apeiros>
popl: aaahaha, that reminds me of a silly story of a man whose doctor prohibited him to drink alcohol.
<benzrf>
did u kno
<benzrf>
ballmer peak is at 0.1334
<benzrf>
* 0.1337
<shevy>
the only creepy things are those flying snakes
beef-wellington has quit [Ping timeout: 255 seconds]
<apeiros>
popl: of course he died because he thought the important part about it was "drink" :)
sambao21 has quit [Quit: Computer has gone to sleep.]
monkegji_ has joined #ruby
razrunelord has joined #ruby
soheil has quit [Remote host closed the connection]
soheil has joined #ruby
monkegj__ has joined #ruby
sailias has quit [Quit: Leaving.]
<popl>
apeiros: I think I heard the joke before. :)
monkegjinni has quit [Ping timeout: 240 seconds]
pwh has quit [Ping timeout: 264 seconds]
Sawbones has quit [Remote host closed the connection]
Kricir has joined #ruby
sambao21 has joined #ruby
kyb3r_ has quit [Read error: Connection reset by peer]
supermarin has joined #ruby
Synthead has joined #ruby
monkegji_ has quit [Ping timeout: 252 seconds]
fijimunkii has quit [Ping timeout: 240 seconds]
mrmargol_ has quit [Remote host closed the connection]
mjsmith2 has quit [Remote host closed the connection]
mary5030 has quit [Remote host closed the connection]
mr_snowf1ake has joined #ruby
mjsmith2 has joined #ruby
jobewan has quit [Quit: Leaving]
danman__ has quit [Quit: danman__]
atmosx has quit [Remote host closed the connection]
tacos1de has quit [Write error: Broken pipe]
tacos1de has joined #ruby
atmosx has joined #ruby
tris has joined #ruby
endash has quit [Quit: endash]
supermarin has quit [Ping timeout: 240 seconds]
razrunelord has quit [Remote host closed the connection]
<apeiros>
asking an instance won't let @bar show up, because it's not there.
<Bilge>
Do you think this is good design?
<kilk_>
belongs to class variables that start with @@
<apeiros>
Bilge: "this"?
<Bilge>
Having two separate sets of variables depending on whether the class is created with #new or not
<apeiros>
Bilge: um, you don't understand
<Bilge>
You're right, I don't
<apeiros>
Bilge: it's one unified model. objects have instance variables. classes are objects. therefore classes have instance variables.
<apeiros>
good design? hell no, it's excellent design.
<Bilge>
I'm starting to hate Ruby
<apeiros>
then use another language.
krazh has quit [Remote host closed the connection]
<apeiros>
alternatively try to understand its idioms.
<Bilge>
Admittedly I should be using Node but I want to create at least one project in Ruby before dismissing it
srji has quit [Ping timeout: 252 seconds]
andrewjanssen has quit [Quit: Leaving...]
SCommette has quit [Quit: SCommette]
krazh has joined #ruby
<apeiros>
that sounds like you're desperately looking for things you can dislike.
<apeiros>
excellent start
KanKava has quit [Quit: leaving]
<Bilge>
Why does it?
crucify_me is now known as varreli
<apeiros>
seriously, if that's your attitude, just dismiss it already.
roadie has joined #ruby
<Bilge>
I was drawn to all its surface benefits, it's idiomatic expressiveness which is touted by extravagant manuals like _why's guide
freezey has quit [Remote host closed the connection]
<Bilge>
But then I am repelled by all the deep quirks that lie beneath its shiny exterior
SCommette has joined #ruby
fantazo has quit [Ping timeout: 252 seconds]
s2013_ is now known as s2013
<apeiros>
if you'd pay attention, you'd notice that it has actually very little quirks.
<Bilge>
Oh, everything is an object, isn't that great? But don't try to extend any of the core objects that will never work!
<apeiros>
most of how it works can be reduced to a small number of rules.
<apeiros>
Bilge: "try to extend any of the core objects that will never work!" says who?
<Bilge>
It's littered throughout all the literature I've read
<Bilge>
Blog posts, manuals and even comments in this chat
varreli has quit []
<apeiros>
i haven't seen anything saying it wouldn't work
<apeiros>
I see plenty saying you shouldn't, and with good reason.
Kricir has joined #ruby
rodri_gore has joined #ruby
saarinen has joined #ruby
<apeiros>
because you shouldn't change basics unless you understand the consequences.
danman_ has joined #ruby
<Bilge>
I'm not talking about monkey patching
<Bilge>
I'm just talking about inheritance
<Bilge>
Of basic objects like Array and Hash or whatever
bearlulz has joined #ruby
kilk_ has quit [Quit: Leaving]
dr0ff has joined #ruby
<apeiros>
you mean inheriting Array, Hash etc?
<Bilge>
Set is a standard library class that basically proxies every method of Hash just because extending Hash isn't a good idea
<apeiros>
again, understand the reasons. and nobody says "that will never work"
<Bilge>
It's fundamentally fucked up if you can't reuse the basic building blocks of software
<apeiros>
but you seem to prefer to just go all hysterical about it instead of learning and understanding.
<Bilge>
You seem to prefer to have a baseless argument about it instead of teaching something that would aid in understanding why I might be wrong
pwh has joined #ruby
<apeiros>
you see, the reasons for it have nothing to do with ruby. they're the same in other languages which have inheritance principles.
<apeiros>
Bilge: I'm not interested in teaching somebody who thinks being hysterical and negative was a good way.
<apeiros>
come again when you're willing to learn.
gigetoo has quit [Ping timeout: 240 seconds]
Kricir has quit [Ping timeout: 276 seconds]
gigetoo has joined #ruby
saarinen has quit [Quit: saarinen]
rodri_gore has quit [Quit: WeeChat 0.4.3]
rodri_gore has joined #ruby
p8952 has quit [Ping timeout: 240 seconds]
soheil has quit [Remote host closed the connection]
soheil has joined #ruby
pwh has quit [Ping timeout: 258 seconds]
zigomir has quit [Remote host closed the connection]
zigomir has joined #ruby
saarinen has joined #ruby
dik_dak has quit [Quit: Leaving]
m00nlight has quit [Quit: Konversation terminated!]
<shevy>
Bilge it's not entirely "everything is an object"; For instance, this here won't work: x = 5; def x.hi; puts "hi"; end
pen has joined #ruby
eka has quit [Ping timeout: 265 seconds]
kpshek has quit []
linojon has quit [Quit: linojon]
<Bilge>
Just another quirk
matcouto has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
fantazo has joined #ruby
<shevy>
more like you must have read it from someone who claimed it to be so
bearlulz has quit [Ping timeout: 276 seconds]
zigomir has quit [Ping timeout: 240 seconds]
<Bilge>
The docs, as I recall
AlSquire has joined #ruby
<shevy>
can you link
srji has joined #ruby
srji has quit [Client Quit]
lele has quit [Ping timeout: 246 seconds]
<Bilge>
If I come across it again I may
zachallett has quit [Remote host closed the connection]
<shevy>
so you can't
toretore has quit [Quit: This computer has gone to sleep]
<shevy>
well educated man
<apeiros>
of course he can't
gigetoo has quit [Ping timeout: 240 seconds]
enebo has quit [Quit: enebo]
<shevy>
he could at least try to
<shevy>
it's difficult to learn a programming language from random blog posts Bilge
<apeiros>
that'd require his statement to be true
michaeldeol has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<shevy>
there is the programmers
<shevy>
the brogrammers
<shevy>
and the blogammers
<apeiros>
it's just as hysterical as his claims about all blogs and all the literature saying "it won't work!"
b00stfr3ak has quit [Ping timeout: 252 seconds]
<shevy>
he'll master the knowledge of all blogs
<shevy>
even if they note down wrongful information
lele has joined #ruby
jhass is now known as jhass|off
andrewjanssen has joined #ruby
b00stfr3ak has joined #ruby
pwh has joined #ruby
rodri_gore has quit [Quit: WeeChat 0.4.3]
rodri_gore has joined #ruby
troulouliou_dev has quit [Quit: Leaving]
SCommette has quit [Quit: SCommette]
dangerousdave has joined #ruby
p8952 has joined #ruby
p8952 has quit [Changing host]
p8952 has joined #ruby
rodri_gore has quit [Client Quit]
eka has joined #ruby
Es0teric has quit [Quit: Computer has gone to sleep.]
rodri_gore has joined #ruby
<Bilge>
Totally
larsam has joined #ruby
<shevy>
a true javascript cowboy
<jenrzzz>
Bilge: shevy: word of god says “Fixnum and Symbol objects are actually ‘immediate values’ rather than references. Neither of these classes have mutator methods, so Fixnum and Symbol objects are immutable, which means that there is really no way to tell that they are manipulated by value rather than reference.”
rodri_gore has quit [Client Quit]
etqqkoiflwhb_ has joined #ruby
klaut has quit [Remote host closed the connection]
rodri_gore has joined #ruby
Virtualize|away has quit [Quit: Leaving...]
jcs222 has quit [Read error: Connection reset by peer]
<benzrf>
less than a page of code for a fully-working lisp parser :-)
<wallerdev>
yeah some of us dont have time to write our own parsers anytime we need to scrape some html haha
<benzrf>
that creates the data structure toordog
<benzrf>
*too
<benzrf>
not just a parse tree
<benzrf>
(although that's a similar thing in lisp...)
<jenrzzz>
one of my programming assignments back in the day was writing an OCaml interpreter in OCaml
<jenrzzz>
it was enlightening
<mordof>
wallerdev: i'm not writing one to scrape HTML per say - not for any particular task though
shedd has quit [Client Quit]
<mordof>
wallerdev: i'm waiting for a job to start up, and learning ruby in the meantime.
<wallerdev>
i wrote a css3 parser awhile back in c#
shedd has joined #ruby
<wallerdev>
well not sure if i ever finished that
<benzrf>
jenrzzz: thats my lisp in haskell
<benzrf>
close enough :-)
shedd has quit [Client Quit]
frem_ has joined #ruby
<mordof>
benzrf: it's too bad i don't know haskell enough to read that
<mordof>
i stopped really early on with it
<mordof>
Haskell is one of the few languages that, without having thoroughly learned it before, i couldn't understand
<jenrzzz>
yeah some parts of the syntax are really unintuitive for me
* mordof
nods
matchaw has joined #ruby
<benzrf>
they're not unintuitive
<benzrf>
they're just different
fijimunkii has joined #ruby
BrianJ has quit [Ping timeout: 250 seconds]
<benzrf>
you're used to algol-likes
<benzrf>
and haskell is radically different
<benzrf>
it's not that much harder from a base level
<benzrf>
it's just harder when you're used to other languages being close
<benzrf>
:-)
<mordof>
indeed
<benzrf>
basically it's like learning to code over again
<jenrzzz>
they’re unintuitive because my intuition doesn’t work on them. not necessarily a bad thing, just means it takes a little more work to grok it
SilkFox has joined #ruby
<benzrf>
your intuition doesnt work on them because intuition grows with practice
<benzrf>
i bet your intuition didnt work on the first language you learned very well at firt