jhass[m] changed the topic of #ruby to: Rules: https://ruby-community.com | Ruby 3.1.2, 3.0.4, 2.7.6: https://www.ruby-lang.org | Paste 4+ lines to: https://gist.github.com | Books: https://goo.gl/wpGhoQ
desnudopenguino has quit [*.net *.split]
ur5us has quit [*.net *.split]
perrierjouet has quit [*.net *.split]
swaggboi has quit [*.net *.split]
Na_Klar has quit [*.net *.split]
willow has quit [*.net *.split]
Furai has quit [*.net *.split]
sympt has quit [*.net *.split]
sagax has quit [*.net *.split]
artyn has quit [*.net *.split]
entropie has quit [*.net *.split]
georgemp has quit [*.net *.split]
Milos has quit [*.net *.split]
duds- has quit [*.net *.split]
<ixti> But I guess it's pretty good for majority of use cases :D
perrierjouet has joined #ruby
entropie has joined #ruby
georgemp has joined #ruby
Milos has joined #ruby
swaggboi has joined #ruby
duds- has joined #ruby
Furai has joined #ruby
willow has joined #ruby
desnudopenguino has joined #ruby
artyn has joined #ruby
jpn has quit [Ping timeout: 246 seconds]
<ox1eef_> ixti: looks like magic to me, but i guess that is subjective. it's surprising behavior, and it's best not to have surprising APIs.
<ox1eef_> a good API works just like you expect without ever reading the docs.
jl- has joined #ruby
<ixti> ox1eef_: on one hand I agree, on the other it's pretty biased approach based on experience with other languages..
<ixti> I mean the "expectation" is based on something...
<ox1eef_> that doesn't mean it is not just inherting surprising behavior from other languages, though.
<ox1eef_> and for newbies, who probably have no experience with perl, or awk, it's even worse.
<ixti> Well, I learned myself to always read documentation and source code... So I'm rarely surprised. Only when documentation says one thing and code does the other :D
<ox1eef_> it reminds me of C APIs that nowadays are recommened to never be used, because unless you read their docs you shoot yourself in the foot.
<ixti> LOL :D
<ixti> Could String#split had better signature, sure it could. Especially now with keyword arguments... But changing API of a function that was since the beginning is bad idea too :D
<ox1eef_> i agree, but then, it should have an obvious replacement for this particular case. it's not particularly performant to create a regexp just for this special case.
jl- has quit [Ping timeout: 272 seconds]
jpn has joined #ruby
jpn has quit [Ping timeout: 272 seconds]
<ixti> ox1eef_: Performance hit in this case I believe is negligible.
<ox1eef_> indeed, i would guess so, but probably depends on the case - if you find yourself in a loop, it would be better to have one frozen string than multiple regexps created over and over again. my main issue is that it is just a surprising API that would do the last thing youd expect unless you have knowledge of its inner workings, and 'read the docs' is not a great defense of such APIs imo.
<ixti> You don't need to create regexp over and over again. Create it outside of the loop :D
<ox1eef_> that's just gymnastics for a surprising API
<ixti> ox1eef_: I totally understand what you're saying. API might be surprising. But only if you have background of another language.
markong has quit [Ping timeout: 256 seconds]
<ixti> And I believe each language has its quirks ;D
swaggboi has quit [Read error: Connection timed out]
<ixti> After all languages are tools designed to help solving problems. They are designed by humans with different background and history...
<ox1eef_> certainly, no language is absolute perfection but i think we have to be honest when given an example which is clearly surprising, rather than defend it with emotion because we love so and so language.
swaggboi has joined #ruby
<ixti> ox1eef_: Oh, I'm not defending. It's just I certainly remember having lots of questions about Kotlin APIs when I tried to use them the way I get accustomed in Ruby :D
<ox1eef_> roger that
<ixti> :D
<ixti> After all, surprising or not - that's what we have right now :D
<ixti> We can rant, or we can enjoy ;D
<ixti> I definitely prefer the second one :D
<ox1eef_> well, probably the example was introduced with frustration and a bit of anger, which is best avoided but i think its a valid case all the same.
<ox1eef_> same here, as much as possible
<ixti> :D
jpn has joined #ruby
jpn has quit [Ping timeout: 260 seconds]
swaggboi has quit [Ping timeout: 264 seconds]
perrierjouet has quit [Quit: WeeChat 3.5]
perrierjouet has joined #ruby
swaggboi has joined #ruby
<weaksauce> hah
<weaksauce> At least some of your points are rational. Those behaviors are inherited from Perl.
<weaksauce> I don't think we can change the behavior. We are not going to break existing code for the sake of consistency.
<weaksauce> Matz.
bastienleonard has quit [Ping timeout: 268 seconds]
cocalero has joined #ruby
<ox1eef_> that doesn't change much, nor does it once address the exact scenario we're discussing. JS has the same problem where it has to support clear mistakes for the sake of compatibility. it doesn't mean that if it were decided today, it would remain the best choice. it clearly isn't.
swaggboi has quit [Ping timeout: 264 seconds]
jpn has joined #ruby
jpn has quit [Ping timeout: 256 seconds]
jl- has joined #ruby
jl- has quit [Ping timeout: 248 seconds]
Al2O3 has quit [Quit: I'm quitting, thanks for all the sharks.]
Al2O3 has joined #ruby
cocalero_ has joined #ruby
cocalero has quit [Ping timeout: 256 seconds]
cocalero_ is now known as cocalero
artyn has left #ruby [#ruby]
cocalero has quit [Client Quit]
Vonter has joined #ruby
davidw_ has quit [Ping timeout: 264 seconds]
swaggboi has joined #ruby
jpn has joined #ruby
jpn has quit [Ping timeout: 248 seconds]
teclator has joined #ruby
jl- has joined #ruby
jl- has quit [Ping timeout: 260 seconds]
teclator has quit [Quit: http://quassel-irc.org - Chat comfortably. Anywhere.]
Ziyan has joined #ruby
swaggboi has quit [Read error: Connection timed out]
swaggboi has joined #ruby
wand has quit [Ping timeout: 268 seconds]
wand has joined #ruby
Ziyan has quit [Quit: My iMac has gone to sleep. ZZZzzz…]
wand has quit [Read error: Connection reset by peer]
wand has joined #ruby
jpn has joined #ruby
jpn has quit [Ping timeout: 256 seconds]
Ziyan has joined #ruby
rvalue has quit [Read error: Connection reset by peer]
rvalue has joined #ruby
jl- has joined #ruby
jl- has quit [Ping timeout: 272 seconds]
gr33n7007h has quit [Quit: WeeChat 3.5]
protektwar has joined #ruby
protektwar has joined #ruby
protektwar has quit [Changing host]
_ht has joined #ruby
jpn has joined #ruby
moldorcoder7 has quit [Ping timeout: 256 seconds]
jpn has quit [Ping timeout: 248 seconds]
dollars1 has joined #ruby
dollars1 has quit [Ping timeout: 246 seconds]
tractor5 has joined #ruby
protektwar has quit [Ping timeout: 264 seconds]
tractor5 has quit [Ping timeout: 260 seconds]
dionysus69 has joined #ruby
jpn has joined #ruby
protektwar has joined #ruby
protektwar has quit [Changing host]
protektwar has joined #ruby
jl- has joined #ruby
jl- has quit [Ping timeout: 246 seconds]
joshcom has joined #ruby
gr33n7007h has joined #ruby
Ziyan has quit [Ping timeout: 260 seconds]
protektwar has quit [Ping timeout: 264 seconds]
nmollerup has quit [Remote host closed the connection]
nmollerup has joined #ruby
Ziyan has joined #ruby
joshcom has quit [Remote host closed the connection]
dionysus69 has quit [Ping timeout: 246 seconds]
reset has quit [Quit: reset]
jl- has joined #ruby
jl- has quit [Ping timeout: 260 seconds]
freeworld has joined #ruby
freeworld is now known as Linux-Kerio
Linux-Kerio has quit [Quit: Konversation terminated!]
freeworld has joined #ruby
freeworld has quit [Client Quit]
freeworld has joined #ruby
freeworld has quit [Client Quit]
freeworld has joined #ruby
Ziyan has quit [Ping timeout: 240 seconds]
Ziyan has joined #ruby
freeworld has quit [Client Quit]
freeworld has joined #ruby
freeworld is now known as Linux_Kerio
Linux_Kerio has quit [Client Quit]
Linux_Kerio has joined #ruby
s-liao-2000 has joined #ruby
jpn has quit [Ping timeout: 256 seconds]
perrierjouet has quit [Quit: WeeChat 3.5]
perrierjouet has joined #ruby
jpn has joined #ruby
s-liao-2000 has quit [Quit: Client closed]
username9431 has joined #ruby
perrierjouet has quit [Quit: WeeChat 3.5]
moldorcoder7 has joined #ruby
jpn has quit [Ping timeout: 260 seconds]
markong has joined #ruby
username9431 has quit [Remote host closed the connection]
username9431 has joined #ruby
username9431 has quit [Ping timeout: 260 seconds]
jpn has joined #ruby
jpn has quit [Ping timeout: 248 seconds]
jpn has joined #ruby
jl- has joined #ruby
rvalue has quit [Read error: Connection reset by peer]
rvalue has joined #ruby
Ziyan_ has joined #ruby
Ziyan has quit [Ping timeout: 264 seconds]
jl- has quit [Ping timeout: 276 seconds]
perrierjouet has joined #ruby
freeworld has joined #ruby
freeworld has quit [Client Quit]
freeworld has joined #ruby
freeworld has quit [Client Quit]
Linux_Kerio has quit [Quit: Konversation terminated!]
Linux_Kerio has joined #ruby
Linux_Kerio has quit [Client Quit]
Linux_Kerio has joined #ruby
Linux_Kerio has quit [Client Quit]
Linux_Kerio has joined #ruby
bastienleonard has joined #ruby
s-liao-2000 has joined #ruby
Tempesta has quit [Quit: See ya!]
Linux_Kerio has quit [Quit: Konversation terminated!]
Linux_Kerio has joined #ruby
Tempesta has joined #ruby
Linux_Kerio has quit [Client Quit]
Linux_Kerio has joined #ruby
constxd has joined #ruby
Linux_Kerio has quit [Client Quit]
Linux_Kerio has joined #ruby
desnudopenguino has quit [Ping timeout: 272 seconds]
Linux_Kerio has quit [Client Quit]
Linux_Kerio has joined #ruby
Linux_Kerio has quit [Quit: Konversation terminated!]
Linux_Kerio has joined #ruby
Linux_Kerio has quit [Client Quit]
Linux_Kerio has joined #ruby
gcd has quit [Ping timeout: 268 seconds]
jpn has quit [Ping timeout: 248 seconds]
cocalero has joined #ruby
gcd has joined #ruby
cocalero has quit [Client Quit]
jpn has joined #ruby
davidw_ has joined #ruby
jl- has joined #ruby
jl- has quit [Ping timeout: 246 seconds]
jpn has quit [Ping timeout: 276 seconds]
bastienleonard has quit [Ping timeout: 240 seconds]
protektwar has joined #ruby
protektwar has quit [Changing host]
protektwar has joined #ruby
jpn has joined #ruby
jpn has quit [Ping timeout: 240 seconds]
jpn has joined #ruby
jpn has quit [Ping timeout: 240 seconds]
s-liao-2000 has quit [Quit: Client closed]
jl- has joined #ruby
protektwar has quit [Ping timeout: 264 seconds]
jl- has quit [Ping timeout: 264 seconds]
sympt has joined #ruby
leah2 has quit [Ping timeout: 240 seconds]
leah2 has joined #ruby
perrierjouet has quit [Quit: WeeChat 3.5]
michigan has joined #ruby
jpn has joined #ruby
Ziyan_ has quit [Ping timeout: 268 seconds]
Ziyan has joined #ruby
jpn has quit [Ping timeout: 240 seconds]
sagax has joined #ruby
fandre1986 has joined #ruby
Ziyan has quit [Ping timeout: 264 seconds]
Ziyan has joined #ruby
bastienleonard has joined #ruby
sympt has quit [Read error: Connection reset by peer]
sympt has joined #ruby
rvalue has quit [Read error: Connection reset by peer]
rvalue has joined #ruby
bastienleonard has quit [Ping timeout: 268 seconds]
Ziyan has quit [Ping timeout: 240 seconds]
perrierjouet has joined #ruby
protektwar has joined #ruby
protektwar has joined #ruby
protektwar has quit [Changing host]
Ziyan has joined #ruby
markong has quit [Ping timeout: 260 seconds]
perrierjouet has quit [Quit: WeeChat 3.5]
perrierjouet has joined #ruby
desnudopenguino has joined #ruby
Ziyan has quit [Ping timeout: 272 seconds]
Ziyan has joined #ruby
Ziyan has quit [Quit: Textual IRC Client: www.textualapp.com]
perrierjouet has quit [Quit: WeeChat 3.5]
perrierjouet has joined #ruby
gproto23 has joined #ruby
jpn has joined #ruby
gproto23 has quit [Read error: Connection reset by peer]
jpn has quit [Ping timeout: 246 seconds]
protektwar has quit [Ping timeout: 248 seconds]
perrierjouet has quit [Quit: WeeChat 3.5]
perrierjouet has joined #ruby
perrierjouet has quit [Remote host closed the connection]
perrierjouet has joined #ruby
perrierjouet has quit [Client Quit]
fandre1986 has quit [Quit: Connection closed]
perrierjouet has joined #ruby
parachute7 has joined #ruby
Guest943 has joined #ruby
jl- has joined #ruby
parachute7 has quit [Ping timeout: 240 seconds]
parachute7 has joined #ruby
parachute7 has quit [Remote host closed the connection]
jl- has quit [Ping timeout: 240 seconds]
Guest943 has quit [Quit: Client closed]
cocalero has joined #ruby
leah2 has quit [Ping timeout: 240 seconds]
_ht has quit [Remote host closed the connection]
gproto23 has joined #ruby
leah2 has joined #ruby
jpn has joined #ruby
leah2 has quit [Ping timeout: 260 seconds]
jpn has quit [Ping timeout: 240 seconds]
leah2 has joined #ruby
Linux_Kerio has quit [Ping timeout: 248 seconds]
jpn has joined #ruby
markong has joined #ruby
jl- has joined #ruby
jpn has quit [Ping timeout: 256 seconds]
jl- has quit [Ping timeout: 276 seconds]
jl- has joined #ruby
desnudopenguino has quit [Ping timeout: 272 seconds]
jl- has quit [Ping timeout: 246 seconds]
jpn has joined #ruby
jpn has quit [Ping timeout: 260 seconds]
wand has quit [Ping timeout: 268 seconds]
gproto23 has quit [Remote host closed the connection]
wand has joined #ruby
jpn has joined #ruby
bastienleonard has joined #ruby
jpn has quit [Ping timeout: 256 seconds]
wand has quit [Remote host closed the connection]
wand has joined #ruby
jpn has joined #ruby
jpn has quit [Ping timeout: 256 seconds]
mooff has joined #ruby
jpn has joined #ruby
jpn has quit [Ping timeout: 246 seconds]
<mooff> (seeing scrollback from before my bouncer disconnected)
<mooff> > kinda silly one can't include a class when a class is a module
<mooff> agree. i would love this to be possible. @banister made this ~12 years ago: https://github.com/banister/remix
<mooff> :: def hexdigest(value)= Digest::MD5.hexdigest(value); hexdigest("foobar")
* mooff takes a wrench to ruby-eval
ruby-eval has joined #ruby
<mooff> :: def hexdigest(value)= Digest::MD5.hexdigest(value)
<ruby-eval> => :hexdigest
jpn has joined #ruby
jl- has joined #ruby