brownbathrobe has quit [Remote host closed the connection]
arBmind has quit [Quit: Leaving.]
skade has joined #ruby-lang
havenn has quit [Remote host closed the connection]
kr3ssh has quit [Ping timeout: 264 seconds]
piotrj has quit [Read error: Connection reset by peer]
piotrj has joined #ruby-lang
Guest24 is now known as lele
kerunaru has joined #ruby-lang
charliesome has quit [Quit: zzz]
stardiviner has quit [Quit: Weird in coding now, or make love, only two things push me away from IRC.]
ecnalyr has joined #ruby-lang
DarkBushido has quit [Ping timeout: 256 seconds]
cschneid has quit [Ping timeout: 256 seconds]
DarkBushido has joined #ruby-lang
DarkBushido has quit [Changing host]
DarkBushido has joined #ruby-lang
cschneid has joined #ruby-lang
gwendall has joined #ruby-lang
ecnalyr has quit [Ping timeout: 265 seconds]
[spoiler] has quit [Ping timeout: 244 seconds]
gwendall has quit [Ping timeout: 272 seconds]
cschneid has quit [Ping timeout: 256 seconds]
jwaldrip has quit [Quit: Be back later ...]
jwaldrip has joined #ruby-lang
cschneid has joined #ruby-lang
vondruch has joined #ruby-lang
workmad3 has joined #ruby-lang
harly has quit [Read error: Connection reset by peer]
Forgetful_Lion has joined #ruby-lang
piotrj has quit [Remote host closed the connection]
|jemc| has quit [Ping timeout: 272 seconds]
workmad3 has quit [Ping timeout: 256 seconds]
jwaldrip has quit [Ping timeout: 256 seconds]
jwaldrip has joined #ruby-lang
kr3ssh has joined #ruby-lang
gwendall has joined #ruby-lang
jwaldrip has quit [Ping timeout: 252 seconds]
k3asd` has joined #ruby-lang
jwaldrip has joined #ruby-lang
piotrj has joined #ruby-lang
arBmind has joined #ruby-lang
araujo has joined #ruby-lang
elev has joined #ruby-lang
kr3ssh has quit [Ping timeout: 255 seconds]
<elev>
whats wrong with this code?
<elev>
puts "How old are you?"
<elev>
age = gets.chomp
<elev>
if age >70 && 12
<elev>
puts "You are young!"
<elev>
puts "How old are you?"
<elev>
age = gets.chomp
<elev>
if age >70 && 12
<elev>
puts "You are young!"
<elev>
end
<ledestin>
elev read topic please
[spoiler] has joined #ruby-lang
<elev>
what?
fusillicode1 has joined #ruby-lang
<elev>
puts "How old are you?"
<elev>
age = gets.chomp
<elev>
if age >70 && 12
<elev>
puts "You are young!"
<elev>
end
<elev>
whats wrong with it?
<ledestin>
elev don't paste unless you want to be banned
<elev>
ok sorry
<tbuehlmann>
elev, gets returns a string, if that helps
<elev>
what you mean?
<elev>
is the code wrong?
rikkipitt has joined #ruby-lang
fusillicode has quit [Ping timeout: 250 seconds]
<maloik>
You are comparing strings to integers
<ledestin>
elev I was talking about channel topic. If you have no idea, read documentation for your client.
<elev>
ok
<elev>
so you cant help me with my code?
<maloik>
... we are?
<elev>
so whats wrong with it?
<maloik>
we could spoonfeed you a solution, but making you stop and think for a second will make it stick :-)
<elev>
like where?
<maloik>
"you are comparing strings to integers" -> it implies the mistake is happening on the line where you... compare stuff? :-)
Guest20 has joined #ruby-lang
Guest20 has quit [Client Quit]
<maloik>
as in x > y
<ledestin>
whew. it's ArgumentEror when comparing string to an integer
<elev>
can you make a new code for me? fix the mistake?
<elev>
puts "How old are you?"
<elev>
age = gets.chomp
<elev>
if age >70 && 12
<elev>
puts "You are young!"
elev has left #ruby-lang [#ruby-lang]
<maloik>
sigh.
cschneid has quit [Ping timeout: 265 seconds]
<ledestin>
fried fish for table 2
<maloik>
lol
<maloik>
ledestin: I literally lol'ed, got some weird looks there
jwaldrip has quit [Ping timeout: 265 seconds]
<ledestin>
maloik :)
<maloik>
did he leave? couldn't seem to highlight
jwaldrip has joined #ruby-lang
<ledestin>
yep, right after pasting
piotrj has quit [Remote host closed the connection]
<ledestin>
my new client is great - Textual
<pipework>
ledestin: It's not that great for me, but I'm waiting for some bug fixes.
<maloik>
does it allow you to connect to a client running somewhere else?
<ledestin>
pipework I was on Colloquy before. that should explain it
<pipework>
It's the best graphical irc client I've used though, but I feel like it's not comparable to weechat, though I have bias.
<pipework>
maloik: It allows you to connect to anything that acts like an IRC server.
<pipework>
Like ZNC.
<maloik>
interesting
<maloik>
might need to look into that then
<maloik>
who am I kidding, I'm not going to bother as long as I have irssi running on this server :D
nofxx has quit [Ping timeout: 252 seconds]
<pipework>
maloik: Lol.
cschneid has joined #ruby-lang
<pipework>
I prefer weechat locally, connected through a VPN server to my current ZNC deployment that's connected to the networks I use (load balancers are awesome).
k3asd` has quit [Ping timeout: 265 seconds]
<pipework>
Then I don't need to bother with mosh or dealing with ssh blocking input.
alestube_ has quit [Remote host closed the connection]
piotrj has quit [Remote host closed the connection]
vondruch has joined #ruby-lang
skade has joined #ruby-lang
rcvalle has joined #ruby-lang
k3asd`_ has quit [Ping timeout: 276 seconds]
leat1 has quit [Remote host closed the connection]
leat1 has joined #ruby-lang
<yorickpeterse>
headius: yeah, just replied
<yorickpeterse>
totally hadn't considered they might be overwriting const_get
nertzy has quit [Quit: This computer has gone to sleep]
<headius>
yeah, I was just looking for "autoload" and when I didn't find that I knew there had to be something else lazy loading
dvlwrk has joined #ruby-lang
<headius>
because I was seeing half-initialized const tables all over the place
lytol has joined #ruby-lang
bantic has joined #ruby-lang
relix has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
delongG has joined #ruby-lang
charliesome has joined #ruby-lang
delongG has quit [Remote host closed the connection]
lytol has quit [Remote host closed the connection]
delongG has joined #ruby-lang
skade has quit [Quit: Computer has gone to sleep.]
delongG has quit [Remote host closed the connection]
delongG has joined #ruby-lang
relix has joined #ruby-lang
k3asd` has joined #ruby-lang
stan has quit [Ping timeout: 265 seconds]
nofxx has joined #ruby-lang
k3asd` has quit [Ping timeout: 250 seconds]
k3asd` has joined #ruby-lang
baweaver has joined #ruby-lang
shinnya has quit [Ping timeout: 255 seconds]
GarethAdams has joined #ruby-lang
momomomomo has joined #ruby-lang
howdoicomputer has quit [Quit: howdoicomputer]
Vivex has joined #ruby-lang
fsvehla has joined #ruby-lang
mikecmpbll has quit [Quit: i've nodded off.]
imperator2 has joined #ruby-lang
redtomahawk has joined #ruby-lang
lytol has joined #ruby-lang
scampbell has quit [Quit: Leaving]
momomomomo has quit [Ping timeout: 255 seconds]
charliesome has quit [Quit: zzz]
relix has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
sang has quit [Remote host closed the connection]
gwendall has quit [Remote host closed the connection]
banister has joined #ruby-lang
banister has quit [Max SendQ exceeded]
momomomomo has joined #ruby-lang
My_Hearing is now known as Mon_Ouie
baweaver has quit [Remote host closed the connection]
banister has joined #ruby-lang
b_hoffman has quit [Quit: b_hoffman]
alestuber has joined #ruby-lang
b_hoffman has joined #ruby-lang
baweaver_ has joined #ruby-lang
nofxx has quit [Ping timeout: 250 seconds]
ascarter has joined #ruby-lang
hahuang65 has joined #ruby-lang
momomomomo has quit [Quit: momomomomo]
dzejrou has quit [Read error: Connection reset by peer]
ascarter has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
Kache4 has joined #ruby-lang
ascarter has joined #ruby-lang
izzimus has quit [Remote host closed the connection]
benlovell has quit [Ping timeout: 276 seconds]
crankhar1er has quit [Ping timeout: 250 seconds]
alestuber has quit [Ping timeout: 250 seconds]
elia has quit [Quit: Computer has gone to sleep.]
cpt_yossarian has joined #ruby-lang
b_hoffman has quit [Quit: b_hoffman]
k3asd` has quit [Ping timeout: 256 seconds]
k3asd` has joined #ruby-lang
k3asd` has quit [Client Quit]
alestuber has joined #ruby-lang
joaomdmoura has joined #ruby-lang
bungoman has quit [Remote host closed the connection]
voxxit has quit [Remote host closed the connection]
voxxit has joined #ruby-lang
<pipework>
headius: I've always been rather skeptical of the benefits of lazy/auto loading. It has always seemed to me that the known pitfalls of those things makes it not worth it in my libraries and code. Do you perhaps have any notion contrary to that?
_djbkd has joined #ruby-lang
joaomdmoura has quit [Remote host closed the connection]
dzejrou has joined #ruby-lang
Asher has quit [Quit: Leaving.]
nertzy has joined #ruby-lang
fsvehla has quit [Quit: fsvehla]
<toretore>
pipework: i mostly agree with you, but have been shown examples such as libraries with dependencies that you may not want to load unless you actually need them
<toretore>
but in this case i say just make whoever is using the lib load these parts manually
banister has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
redtomahawk has quit [Remote host closed the connection]
arBmind has quit [Ping timeout: 244 seconds]
wallerdev has joined #ruby-lang
redtomahawk has joined #ruby-lang
<headius>
pipework: lazy loading would work a lot better in Ruby if the constant for a class was defined *after* the class body exits
<headius>
as it is there's no way to make lazy loading completely safe because unfinished classes are immediately visible and usable
<pipework>
headius: Unrelated, I'm amused by the return value of the class keyword.
<headius>
yeah :-\ I filed an issue to make it always return the class but no movement yet
arBmind has joined #ruby-lang
fsvehla has joined #ruby-lang
kr3ssh has quit [Ping timeout: 244 seconds]
marr has quit [Ping timeout: 248 seconds]
cpt_yossarian has quit [Ping timeout: 250 seconds]
gwendall has joined #ruby-lang
bruno- has quit [Ping timeout: 255 seconds]
alestube_ has joined #ruby-lang
<tubbo>
headius: when is a class "finished"?
<tubbo>
"finished" being defined*
<headius>
also hard to define in Ruby, but at the very least I would think you shouldn't see a class that's still open and being defined
<headius>
it might be reopened but that's a separate issue
gwendall has quit [Ping timeout: 272 seconds]
alestuber has quit [Ping timeout: 276 seconds]
relix has joined #ruby-lang
<tubbo>
yeah, not sure of the semantics there
banister has joined #ruby-lang
nertzy has quit [Quit: This computer has gone to sleep]
delongG has quit [Remote host closed the connection]
leat1 has quit [Ping timeout: 256 seconds]
leat1 has joined #ruby-lang
alestube_ has quit [Ping timeout: 256 seconds]
arBmind has quit [Ping timeout: 250 seconds]
delongG has joined #ruby-lang
brownbathrobe has joined #ruby-lang
alestuber has joined #ruby-lang
__butch__ has quit [Quit: Leaving.]
brownbathrobe has quit [Remote host closed the connection]
nofxx has joined #ruby-lang
mikecmpbll has joined #ruby-lang
brownbathrobe has joined #ruby-lang
ecnalyr has quit []
izzimus has joined #ruby-lang
_djbkd has quit [Ping timeout: 250 seconds]
ryba_ has quit [Ping timeout: 252 seconds]
chinmay_dd has quit [Quit: Leaving]
<apeiros>
tubbo: when you call .freeze on it ;-)
gwendall has joined #ruby-lang
malconis has quit [Ping timeout: 250 seconds]
<tubbo>
oh yeah :)
<headius>
that would be nice
_djbkd has joined #ruby-lang
_djbkd has quit [Read error: Connection reset by peer]
_djbkd has joined #ruby-lang
lytol has quit [Remote host closed the connection]
lytol has joined #ruby-lang
joaomdmoura has joined #ruby-lang
_djbkd has quit [Remote host closed the connection]
crankhar1er has joined #ruby-lang
lianj_ has quit [Ping timeout: 248 seconds]
malconis has joined #ruby-lang
<|jemc|>
headius: I think it's useful to be able to use the "namespacey" parts of a class/module before it's fully defined, but I think you're right about having the definition of the class/module itself be atomic
<|jemc|>
headius: part of the problem in my mind is that the namespace and class/module concepts are conflated in Ruby
<|jemc|>
when really they are two orthogonal concerns
dzejrou has quit [Ping timeout: 252 seconds]
chinmay_dd has joined #ruby-lang
charliesome has joined #ruby-lang
<headius>
|jemc|: I may have mentioned this before, but I did a patch to JRuby to make the new namespace/module/class only visible in that thread until it had been "committed" by closing the body
<headius>
then it was pushed out so all threads could see it
workmad3 has quit [Ping timeout: 250 seconds]
<headius>
I doubt that pattern would break anyone's app
<|jemc|>
headius: sounds reasonable in the context of ruby, but still a little hacky in the context of sanity :)
<headius>
I think it's far less hacky than what we have now
<headius>
it's predictable and consistent
<headius>
open a class, nobody will see your changes until you close it, but you can see them
<headius>
I used clojure's STM for it
<|jemc|>
I think it would make more sense to either be fully atomic or fully sequential, but I think it's a reasonable optimization in terms of not breaking existing ruby
<|jemc|>
I just meant it might be more reasonable to break ruby and be fully atomic
<|jemc|>
anyway, it's an interesting issue and one I've been dealing with lately in Myco
Vivex has quit [Read error: Connection reset by peer]
RobertBirnie has joined #ruby-lang
<headius>
the STM solution solves the issue of wanting to be able to access the constant during definition
<apeiros>
headius: hm, in what way was Kernel#autoload made thread-safe then?
_djbkd has joined #ruby-lang
<headius>
it also opens up the possibility of auditing concurrent class access during modification, hard erroring when someone attempts to commit changes to the class on two different threads, etc
<apeiros>
sounds to me like it was still pretty much not thread-safe?
<headius>
apeiros: autoload itself is thread-safe
RobertBi_ has joined #ruby-lang
<headius>
it will never load the same file twice, and until the constant in question has been defined it will block concurrent accessors
<apeiros>
but it might leave threads with incompletely loaded classes?
joaomdmo_ has joined #ruby-lang
<headius>
that's outside of what autoload can fix
<apeiros>
where "leave" = "have while it's still loading"?
<apeiros>
I don't think so
<headius>
well, you're wrong :-)
<apeiros>
autoload works by loading a file, no?
<headius>
once the constant table gets updated with the newly-opened file, autoload will no longer fire
<headius>
it is not in the picture anymore
<apeiros>
load the file in a Thread.exclusive
<apeiros>
expensive, but I prefer expensive over incorrect
<headius>
won't help
joaomdmoura has quit [Read error: Connection reset by peer]
<headius>
because you lose the autoload once the class starts being defined
<|jemc|>
heck, for MRI compatibility, just execute all files with a global Thread.exclusive :P
<headius>
and even if that worked, autoloaded files can define other classes that will seem to be defined?() right away even though they're not done
gwendall has quit [Remote host closed the connection]
<headius>
it's a fundamental problem with lazy loading in Ruby
gwendall has joined #ruby-lang
<apeiros>
I think I'll have to take a look at a complete example when I have a bit more time
RobertBirnie has quit [Ping timeout: 255 seconds]
ascarter_ has joined #ruby-lang
<apeiros>
I had thought about autoloading a couple of years ago and I was pretty sure I'd nailed it
ascarter has quit [Ping timeout: 250 seconds]
<apeiros>
but alas, mistakes in concurrency are myriad
charliesome has quit [Quit: zzz]
ascarter has joined #ruby-lang
gwendall has quit [Ping timeout: 272 seconds]
ryba_ has joined #ruby-lang
ascarter has quit [Client Quit]
<headius>
I may be wrong about how bad it is...I think it may lock on the exact autoloaded constant while the require is happening, but that doesn't prevent other classes the autoload defines from being visible :-(
baweaver_ has quit [Remote host closed the connection]
ascarter_ has quit [Ping timeout: 245 seconds]
ascarter has joined #ruby-lang
lytol has quit [Remote host closed the connection]
joaomdmoura has joined #ruby-lang
joaomdmo_ has quit [Read error: Connection reset by peer]
ascarter has quit [Max SendQ exceeded]
ascarter has joined #ruby-lang
wallerdev_ has joined #ruby-lang
wallerdev has quit [Ping timeout: 250 seconds]
wallerdev_ is now known as wallerdev
redtomahawk has quit [Remote host closed the connection]
bungoman has joined #ruby-lang
redtomahawk has joined #ruby-lang
alestuber has quit [Ping timeout: 250 seconds]
redtomahawk has quit [Read error: Connection reset by peer]
redtomahawk has joined #ruby-lang
piotrj has joined #ruby-lang
_djbkd has quit [Remote host closed the connection]
face has joined #ruby-lang
alestuber has joined #ruby-lang
imperator2 has quit [Quit: This computer has gone to sleep]
faces has quit [Ping timeout: 250 seconds]
baweaver has joined #ruby-lang
_djbkd has joined #ruby-lang
djbkd_ has joined #ruby-lang
baweaver has quit [Remote host closed the connection]
_djbkd has quit [Remote host closed the connection]
imperator2 has joined #ruby-lang
lytol has joined #ruby-lang
dvlwrk has quit [Quit: Leaving]
<crankharder>
where or in what project/thing is Gem::Specification defined?
<pipework>
Reminiscent of another terminal that's not open source I have for OSX.
<pipework>
I guess what I should have said was a toolkit for making retro software menus closer to the DOS 'windowing' of old, not the kind like kernel make menuconfig
<|jemc|>
ah I get it
baweaver has quit [Remote host closed the connection]
<|jemc|>
yeah, so much nostalgia for those in-game shareware advertisements
<pipework>
It'd be especially cool if that was one's desktop windowing system...
bungoman has quit [Remote host closed the connection]
j4cknewt has joined #ruby-lang
baweaver has joined #ruby-lang
alestube_ has quit [Ping timeout: 256 seconds]
yfeldblum has joined #ruby-lang
alestuber has joined #ruby-lang
bruno-_ has quit [Ping timeout: 240 seconds]
baweaver has quit [Remote host closed the connection]
victortyau has quit [Quit: Leaving]
CamonZ has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
Asher has joined #ruby-lang
crankhar1er has joined #ruby-lang
alestuber has quit [Remote host closed the connection]
gwendall has joined #ruby-lang
j4cknewt has quit []
delongG has quit [Remote host closed the connection]
crankhar1er has quit [Ping timeout: 250 seconds]
delongG has joined #ruby-lang
gwendall has quit [Ping timeout: 272 seconds]
yfeldblum has quit [Remote host closed the connection]
delongG has quit [Remote host closed the connection]
duderonomy has joined #ruby-lang
elia has quit [Quit: Computer has gone to sleep.]
delongG has joined #ruby-lang
crankharder has quit [Remote host closed the connection]
yfeldblum has joined #ruby-lang
arBmind1 has quit [Quit: Leaving.]
yfeldblum has quit [Ping timeout: 256 seconds]
yfeldblum has joined #ruby-lang
aeze has joined #ruby-lang
ascarter_ has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]