havenwood changed the topic of #ruby to: Rules: https://ruby-community.com | Ruby 3.2.1, 3.1.3, 3.0.5, 2.7.7: https://www.ruby-lang.org | Paste 4+ lines to: https://gist.github.com | Books: https://t.ly/9ua4 | Logs: https://libera.irclog.whitequark.org/ruby/
* John_Ivan sighs
Linux_Kerio has quit [Ping timeout: 260 seconds]
markong has joined #ruby
<panella32> Thanks guys, I'm still having hard time understanding how differentiate between a local variable like age and (self.)age which the self keyword has been omitted. How the method understand which one I mean? I think this image express my question a bit better https://i.imgur.com/HlZeHs3.png
<leftylink> what you forgot is that `attr_accessor` defines method `age`.
<leftylink> therefore, in `Bar`, `age` is the method, `age`.
<panella32> leftylink great point! Thanks! So does this mean it's impossible for a method to have a local variable named `age`?
<leftylink> of course it is possible. write `age = 7` and then you've just set a local variable `age` to be 7.
<panella32> so in this circumstance, age =7 and self.age = 7 means completely two different things, and it means `self.` must not be omitted right?
<leftylink> that is right
pcw has left #ruby [#ruby]
<panella32> leftylink so as a final step, back to the code from Hartl book. https://i.imgur.com/jxf59lJ.png In line 23 'remember_token' could be either a `method` or a `local variable`. Without self, how can it not be confused with a local variable?
<leftylink> because there's no local variable with the name `remember_token`
<leftylink> therefore it has to be a method
<panella32> Solved :) Thanks a lot leftylink!! I know my question seems a bit stupid!
Akiyen24 has quit [Ping timeout: 246 seconds]
<leftylink> for everything that it seems like everyone already knows, they all had to learn it for the first time at some point in the past
<leftylink> the best thing that a teacher can do is not ridicule students for asking questions that seem obvious. because actually it probably isn't obvious
<leftylink> if there are teachers that would ridicule "stupid" questions: well, I wouldn't say that it automatically means one should find a better teacher, but they could definitely improve by not doing that
tomtmym has quit [Quit: Gone.]
<panella32> totally agreed, I wish everybody thought that way. Thanks for that link btw!
hd1 has joined #ruby
hd1 has left #ruby [#ruby]
<leftylink> there's also the "today's lucky 10000" https://xkcd.com/1053/
qxz2 has joined #ruby
qxz2 has quit [Changing host]
<panella32> glad to be one of today's lucky 10,000! It was even a better link thanks!
panella32 has quit [Quit: Textual IRC Client: www.textualapp.com]
molle has quit [Remote host closed the connection]
molle has joined #ruby
c10l has quit [Ping timeout: 246 seconds]
markong has quit [Ping timeout: 246 seconds]
<Al2O3> pretty sure lucky 10K has to do with dilbert today.
dionysus69 has quit [Ping timeout: 255 seconds]
gr33n7007h has quit [Quit: WeeChat 3.8]
gr33n7007h has joined #ruby
panella32 has joined #ruby
razetime has joined #ruby
panella32 has quit [Client Quit]
Sankalp has quit [Ping timeout: 268 seconds]
Sankalp has joined #ruby
yosileyid has joined #ruby
<yosileyid> People in here familiar with jekyll or its more ruby specific?
yosileyid has quit []
CharleyBates has quit [Ping timeout: 246 seconds]
CharleyBates has joined #ruby
quazimodo has quit [Ping timeout: 255 seconds]
quazimodo has joined #ruby
cek has quit [Quit: Connection closed for inactivity]
ur5us has quit [Ping timeout: 255 seconds]
TomyWork has joined #ruby
ur5us has joined #ruby
Guest6635 has joined #ruby
Guest6635 has quit [Client Quit]
quazimodo has quit [Ping timeout: 248 seconds]
quazimodo has joined #ruby
ur5us has quit [Ping timeout: 255 seconds]
razetime has quit [Ping timeout: 246 seconds]
razetime has joined #ruby
razetime has quit [Ping timeout: 255 seconds]
siery has joined #ruby
shokohsc64 has joined #ruby
shokohsc6 has quit [Ping timeout: 252 seconds]
shokohsc64 is now known as shokohsc6
hd1 has joined #ruby
hd1 has left #ruby [#ruby]
razetime has joined #ruby
tomtmym has joined #ruby
tomtmym has quit [Changing host]
tomtmym has joined #ruby
teclator has joined #ruby
infinityfye has joined #ruby
gonix has joined #ruby
gonix has quit [Client Quit]
razetime has quit [Ping timeout: 246 seconds]
Linux_Kerio has joined #ruby
razetime has joined #ruby
razetime has quit [Remote host closed the connection]
_ht has joined #ruby
_ht has quit [Remote host closed the connection]
_ht has joined #ruby
ur5us has joined #ruby
ua_ has quit [Ping timeout: 246 seconds]
jvalleroy has quit [Quit: https://quassel-irc.org - Chat comfortably. Anywhere.]
jvalleroy has joined #ruby
dviola has joined #ruby
ur5us has quit [Ping timeout: 255 seconds]
dionysus69 has joined #ruby
KaitoDaumoto has quit [Remote host closed the connection]
moldorcoder7 has joined #ruby
Linux_Kerio has quit [Read error: Connection reset by peer]
Linux_Kerio has joined #ruby
quazimodo has quit [Ping timeout: 255 seconds]
Tomte has joined #ruby
Tomte has quit [Client Quit]
Tomte has joined #ruby
legahc has quit [Quit: %bye%]
legahc has joined #ruby
gr33n7007h has quit [Ping timeout: 255 seconds]
markong has joined #ruby
Tomte has quit [Ping timeout: 248 seconds]
markong has quit [Ping timeout: 248 seconds]
splud is now known as CmdrSpleen
CmdrSpleen is now known as splud
teclator has quit [Ping timeout: 246 seconds]
cek has joined #ruby
victori has quit [Quit: ZNC 1.8.2 - https://znc.in]
victori has joined #ruby
hightower2 has joined #ruby
tjnhxmzhmqgytuwt has quit [Ping timeout: 248 seconds]
moo- has joined #ruby
jhass[m] has quit [Ping timeout: 265 seconds]
tiziodcaio has quit [Ping timeout: 246 seconds]
moo has quit [Ping timeout: 248 seconds]
artemon has quit [Ping timeout: 252 seconds]
flan[m] has quit [Ping timeout: 256 seconds]
Demi has quit [Quit: ZNC 1.7.2+deb3 - https://znc.in]
mooff has quit [Quit: Ping timeout (120 seconds)]
zaben[m] has quit [Ping timeout: 264 seconds]
vinay[m] has quit [Ping timeout: 264 seconds]
mooff has joined #ruby
thecligu1 has quit [Remote host closed the connection]
brw has quit [Read error: Connection reset by peer]
brw5 has joined #ruby
Demi has joined #ruby
thecligu1 has joined #ruby
teclator has joined #ruby
jhass[m] has joined #ruby
Tomte has joined #ruby
flan[m] has joined #ruby
eddof13 has joined #ruby
tjnhxmzhmqgytuwt has joined #ruby
TomyWork has quit [Remote host closed the connection]
zaben[m] has joined #ruby
shokohsc68 has joined #ruby
shokohsc6 has quit [Ping timeout: 255 seconds]
shokohsc68 is now known as shokohsc6
artemon has joined #ruby
vinay[m] has joined #ruby
moo- is now known as moo
dionysus69 has quit [*.net *.split]
victori has quit [*.net *.split]
polychromata has quit [*.net *.split]
qxz2 has quit [*.net *.split]
dyCrazyEd has quit [*.net *.split]
peder has quit [*.net *.split]
quintasan has quit [*.net *.split]
Malin has quit [*.net *.split]
rhe has quit [*.net *.split]
bhaak has quit [*.net *.split]
dorian has quit [*.net *.split]
dannyAAM has quit [*.net *.split]
<rapha> hmm is it possible that module/include-based monkey patching doesn't work in JRuby the way we're used to from MRI Ruby?
tiziodcaio has joined #ruby
victori has joined #ruby
polychromata has joined #ruby
Malin has joined #ruby
quintasan has joined #ruby
bhaak has joined #ruby
rhe has joined #ruby
qxz2 has joined #ruby
dyCrazyEd has joined #ruby
peder has joined #ruby
dannyAAM has joined #ruby
dorian has joined #ruby
<adam12> rapha: I don't see why it wouldn't.
<rapha> hmm.
<rapha> adam12: i'm dealing with 2 things at once right now. could you confirm if the example with 'parser = Psych::Parser.new(...' from https://rubyapi.org/3.1/o/s?q=Psych should still work in Ruby 3.1 or 3.2?
<adam12> rapha: Which example is this? There are a couple without the elipses.
<adam12> bbiab. lunch
<rapha> ah, the ellipsis were just to mean "the one that starts like that", adam12
<rapha> have a good one!
<rapha> ah, i see the problem
<rapha> i mean the one that starts with this line:
<rapha> parser = Psych::Parser.new(TreeBuilder.new) # => #<Psych::Parser>
Tomte has quit [Ping timeout: 246 seconds]
hightower2 has quit [Ping timeout: 255 seconds]
graywolf has joined #ruby
<rapha> hmm nevermind
<rapha> it did have to do with JRuby
<rapha> i swear, whatever my next workplace will be, i'll take a job in FORTRAN before i take one that requires working with either Java or JRuby
* rapha just has to vent a little, sorry
John_Ivan has quit [Read error: Connection reset by peer]
John_Ivan has joined #ruby
Tomte has joined #ruby
moldorcoder7 has quit [Ping timeout: 255 seconds]
<adam12> rapha: Yeah, but if I search for Psych::Parser.new( there's 4 matches :P
<adam12> rapha: What was the fix?
hightower2 has joined #ruby
siery has quit [Ping timeout: 255 seconds]
Artea has quit [Quit: ZNC - https://znc.in]
dionysus69 has joined #ruby
Tomte has quit [Ping timeout: 260 seconds]
howdoi has joined #ruby
teclator has quit [Ping timeout: 256 seconds]
Tomte has joined #ruby
factor has quit [Read error: Connection reset by peer]
<rapha> adam12: using the provided alternative, `parser = Psych.parser`. TreeBuilder doesn't exist, not even after explicitly require'ing psych/tree_builder. i'm wondering if the example should be updated.
Tomte has quit [Read error: Connection reset by peer]
teclator has joined #ruby
siery has joined #ruby
sermon78 has joined #ruby
ua_ has joined #ruby
Linux_Kerio has quit [Ping timeout: 255 seconds]
moldorcoder7 has joined #ruby
gonix has joined #ruby
passbe has quit [Quit: So long]
ur5us has joined #ruby
gr33n7007h has joined #ruby
shokohsc69 has joined #ruby
shokohsc6 has quit [Ping timeout: 252 seconds]
shokohsc69 is now known as shokohsc6
gcd has quit [Quit: leaving]
gcd has joined #ruby
c10l has joined #ruby
_ht has quit [Quit: _ht]
mdemo has joined #ruby
c10l has quit [Quit: See ya! o/]
c10l has joined #ruby
gonix has quit [Ping timeout: 260 seconds]
sermon78 has quit [Ping timeout: 260 seconds]
siery has quit [Ping timeout: 246 seconds]
tomtmym has quit [Quit: Gone.]
c10l has quit [Quit: See ya! o/]
infinityfye has quit [Read error: Connection reset by peer]
quazimodo has joined #ruby
eddof13 has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
sidetracking has joined #ruby
barbaneigro has joined #ruby
graywolf has quit [Ping timeout: 264 seconds]
astilb27 has joined #ruby
shokohsc64 has joined #ruby
shokohsc6 has quit [Ping timeout: 255 seconds]
shokohsc64 is now known as shokohsc6
ruby[bot] has quit [Remote host closed the connection]
ruby[bot] has joined #ruby
shokohsc6 has quit [Ping timeout: 255 seconds]
c10l has joined #ruby
c10l has quit [Client Quit]
c10l has joined #ruby
astilb27 has quit [Ping timeout: 260 seconds]
shokohsc6 has joined #ruby
sidetracking has quit [Quit: Client closed]
shokohsc62 has joined #ruby
shokohsc6 has quit [Ping timeout: 255 seconds]
shokohsc62 is now known as shokohsc6
dionysus69 has quit [Ping timeout: 248 seconds]