ChanServ changed the topic of #ruby-lang to: Ruby 1.9.3-p125: http://ruby-lang.org | Paste >3 lines of text on http://pastie.org or use a gist
mrsolo has quit [Quit: Leaving]
wyhaines has joined #ruby-lang
wyhaines has quit [Remote host closed the connection]
chimkan___ has joined #ruby-lang
chimkan___ has quit [Client Quit]
benanne has quit [Quit: kbai]
Madis has quit [Quit: ChatZilla 0.9.89 [Firefox 16.0.1/20121026125834]]
chimkan has quit [Ping timeout: 255 seconds]
ryanlecompte has quit [Remote host closed the connection]
Nimotix has quit [Remote host closed the connection]
bosie has quit [Ping timeout: 255 seconds]
<tocki_> is it possible to move method from one class/object to another ?
datanoise has quit [Ping timeout: 244 seconds]
nertzy has quit [Quit: This computer has gone to sleep]
havenn has quit [Remote host closed the connection]
havenn has joined #ruby-lang
<totallymike> tocki_: in runtime?
<tocki_> yes
<tocki_> there is anything else but runtime ?
<totallymike> I was going to get all sarcastic and say copy/paste
havenn_ has joined #ruby-lang
bfreeman has quit [Quit: bfreeman]
havenn has quit [Read error: No route to host]
jarib has quit [Excess Flood]
jarib has joined #ruby-lang
nertzy has joined #ruby-lang
havenn has joined #ruby-lang
jtoy has joined #ruby-lang
havenn_ has quit [Ping timeout: 260 seconds]
runeb has joined #ruby-lang
justinseiter has quit [Read error: Operation timed out]
apeiros has joined #ruby-lang
<totallymike> tocki_: the only thing I can think is, if you want class/instance variables to be attached to the new object, is to make modules and mix them in when you need them
<totallymike> but I'm not sure what you're up to
krohrbaugh has quit [Quit: Leaving.]
runeb has quit [Ping timeout: 244 seconds]
apeiros_ has quit [Ping timeout: 276 seconds]
arubin_ has joined #ruby-lang
havenn has quit [Ping timeout: 252 seconds]
<tocki_> what is difference between method & proc ?
<tocki_> Method & Proc
<heftig> Procs are closures, methods are not
lcdhoffman has joined #ruby-lang
<tocki_> ruby OO is much more similiar to js than Java/.NET
<heftig> no, not at all
<heftig> JS uses prototyping, not classes
<tocki_> methods also _need_ class context
<bluepojo> procs don't create a new call frame
<tocki_> classes in ruby are basically prototypes based on Modules
<bluepojo> where methods do
<tocki_> js frameworks offer similar functionality
qwerxy has quit [Quit: offski]
cyri_ has quit [Quit: cyri_]
woollyams has quit [Quit: Computer has gone to sleep.]
jamjam has quit [Ping timeout: 260 seconds]
woollyams has joined #ruby-lang
<tocki_> its true, methods are not closures
<bluepojo> OO in JS is built on top of the language, not built in
<bluepojo> JS is a functional language
<bluepojo> not OO at all
<bougyman> what?
<bougyman> OO is a prototype language, I thought?
<bougyman> er JS is
<bougyman> it's a different OO, is all, I always thought.
datanoise has joined #ruby-lang
<bluepojo> well
<bluepojo> everything is a function in JS
<reactormonk> bougyman, kind of, but there's not way to add your own types to act like builtin, which is kinda my definition of OO
<bluepojo> functions have prototypes
<tocki_> ruby does something similar
<bougyman> reactormonk: well ruby fails in that.
<reactormonk> bougyman, where?
<bougyman> reactormonk: we have no access to the MOP
<reactormonk> MOP?
<bougyman> we can't change how the object protocol works.
<tocki_> js frameworks like extJS, jQuery, Prototype give you infrastructure for class inheretance and mixins
<tocki_> and essentially they do the same thing ruby does
<tocki_> there are no real types (or classes) in dynamically typed language
<tocki_> its faked
<bougyman> but ruby is strongly typed.
<reactormonk> bougyman, so lisp is more OO than ruby? ;>
<bougyman> reactormonk: crazy, no?
<bougyman> depends on where you want to go with it.
<reactormonk> bougyman, nah, sounds about right
<bougyman> everything in CL is an object _if you access it as an object_
<bougyman> kind of like a Fixnum in ruby
t0h has quit [Ping timeout: 255 seconds]
phaedrix has quit [Read error: Connection reset by peer]
toretore has quit [Quit: This computer has gone to sleep]
<tocki_> how peculiar
datanoise has quit [Ping timeout: 260 seconds]
tonni has joined #ruby-lang
t0h has joined #ruby-lang
tonni has quit [Ping timeout: 240 seconds]
kurko_ has quit [Ping timeout: 252 seconds]
sepp2k has quit [Remote host closed the connection]
kurko_ has joined #ruby-lang
male40 has joined #ruby-lang
male40 has quit [Client Quit]
kurko_ has quit [Ping timeout: 260 seconds]
kurko_ has joined #ruby-lang
tubbo`cloud has joined #ruby-lang
<tubbo`cloud> hi guys
mpan has quit [Read error: Connection reset by peer]
mpan has joined #ruby-lang
kurko_ has quit [Ping timeout: 255 seconds]
sn0wb1rd has quit [Quit: sn0wb1rd]
kurko_ has joined #ruby-lang
krohrbaugh has joined #ruby-lang
sn0wb1rd has joined #ruby-lang
jxie has quit [Ping timeout: 256 seconds]
kurko_ has quit [Ping timeout: 260 seconds]
dpatel has quit [Quit: dpatel]
cantonic has quit [Quit: cantonic]
kurko_ has joined #ruby-lang
datanoise has joined #ruby-lang
jtoy has quit [Quit: jtoy]
kurko_ has quit [Ping timeout: 245 seconds]
kurko_ has joined #ruby-lang
bfreeman has joined #ruby-lang
buscapepe has joined #ruby-lang
tonni has joined #ruby-lang
kurko_ has quit [Ping timeout: 244 seconds]
kurko_ has joined #ruby-lang
tonni has quit [Ping timeout: 256 seconds]
kurko_ has quit [Quit: Computer has gone to sleep.]
justinseiter has joined #ruby-lang
m3nd3s has quit [Remote host closed the connection]
davidbalber|away is now known as davidbalbert
justinseiter has quit [Ping timeout: 260 seconds]
Kant has joined #ruby-lang
Nisstyre-laptop has joined #ruby-lang
justinseiter has joined #ruby-lang
Kant has quit [Remote host closed the connection]
lcdhoffman has quit [Quit: lcdhoffman]
nXqd has quit [Ping timeout: 256 seconds]
guns has quit [Ping timeout: 260 seconds]
perryh has quit [Excess Flood]
Nisstyre-laptop has quit [Quit: Leaving]
perryh has joined #ruby-lang
cirenyc has joined #ruby-lang
nertzy has quit [Quit: This computer has gone to sleep]
justinseiter has quit [Ping timeout: 255 seconds]
datanoise has quit [Ping timeout: 252 seconds]
justinseiter has joined #ruby-lang
Asher has quit [Quit: Leaving.]
Asher has joined #ruby-lang
wyhaines has joined #ruby-lang
twittard has quit [Quit: twittard]
jxie has joined #ruby-lang
tonni has joined #ruby-lang
mpan has quit [Read error: Connection reset by peer]
mpan has joined #ruby-lang
tonni has quit [Ping timeout: 245 seconds]
chimkan has joined #ruby-lang
bluepojo has quit [Ping timeout: 260 seconds]
wallerdev has quit [Quit: wallerdev]
wallerdev has joined #ruby-lang
woollyams has quit [Quit: Computer has gone to sleep.]
gsav_ has quit [Quit: Lost terminal]
woollyams has joined #ruby-lang
gsav has joined #ruby-lang
ryanf has quit [Ping timeout: 248 seconds]
erichmenge has quit [Quit: Linkinus - http://linkinus.com]
alvaro_o has quit [Quit: Ex-Chat]
lcdhoffman has joined #ruby-lang
phaedrix has joined #ruby-lang
gsav has quit [Read error: Connection reset by peer]
gsav has joined #ruby-lang
runeb has joined #ruby-lang
savage- has joined #ruby-lang
runeb has quit [Ping timeout: 260 seconds]
jtoy has joined #ruby-lang
chimkan has quit [Remote host closed the connection]
chimkan_ has joined #ruby-lang
jxie has quit [Ping timeout: 240 seconds]
Nimotix has joined #ruby-lang
gsav has quit [Read error: Connection reset by peer]
areil has joined #ruby-lang
thone_ has joined #ruby-lang
svyatov has quit [Quit: svyatov]
postmodern has joined #ruby-lang
thone has quit [Ping timeout: 252 seconds]
<zenspider> HALP... I actually have no idea how to deal with this
havenn has joined #ruby-lang
<zenspider> in ruby 1.9, strings are arrays of chars... in 1.8 they're arrays of bytes
<zenspider> in 1.9, StringScanner.pos "Returns the byte position of the scan pointer"
<zenspider> but if I want to insert something at ss.pos, I can't use []= because that's char oriented, not byte oriented...
<zenspider> what the FUCK can I do to get around that?!?
havenn has quit [Remote host closed the connection]
havenn has joined #ruby-lang
tonni has joined #ruby-lang
<zzak> zenspider: you could scan until you're near that position and then insert?
havenn has quit [Ping timeout: 244 seconds]
<zzak> i dont know ss that well
<zenspider> ss.string[ss.pos] should return the next char to scan... and it doesn't
tonni has quit [Ping timeout: 255 seconds]
blazes816 has quit [Quit: blazes816]
mjio has joined #ruby-lang
perryh has quit [Excess Flood]
<zzak> i think you mean ss.pos=
perryh has joined #ruby-lang
alexkane_ is now known as alexkane
Serial_Killer_C has joined #ruby-lang
<tsou> zenspider: so you are using ss, scanning something, and at the position your scanner is you want to insert something?
Dreamer3__ has joined #ruby-lang
datanoise has joined #ruby-lang
lcdhoffman has quit [Quit: lcdhoffman]
<tsou> zenspider: off for a shower, but looks like ss.post_match / ss.pre_match can help you.. ss.post_match and ss.pre_match have what you're looking for
<tsou> whoops doubly-written mess-up, but you got me
mjio has quit [Quit: Computer has gone to sleep.]
arubin_ has quit [Quit: ["Textual IRC Client: www.textualapp.com"]]
heftig has quit [Ping timeout: 245 seconds]
heftig has joined #ruby-lang
stardiviner has joined #ruby-lang
tenderlove has quit [Ping timeout: 246 seconds]
ryanf has joined #ruby-lang
roadt has joined #ruby-lang
thinkdevcode has joined #ruby-lang
Dreamer3__ has quit [Quit: Leaving...]
datanoise has quit [Ping timeout: 276 seconds]
dhruvasagar has joined #ruby-lang
nazty has quit [Read error: Connection reset by peer]
nazty has joined #ruby-lang
Kant has joined #ruby-lang
dhruvasagar has quit [Ping timeout: 246 seconds]
chimkan__ has joined #ruby-lang
sailias has quit [Ping timeout: 260 seconds]
havenn has joined #ruby-lang
dhruvasagar has joined #ruby-lang
banisterfiend has quit [Ping timeout: 260 seconds]
chimkan_ has quit [Ping timeout: 256 seconds]
davidbalbert is now known as davidbalber|away
Nimotix has quit [Remote host closed the connection]
richardjortega has joined #ruby-lang
<richardjortega> how do you handle special characters with Ruby CSV, as in "42º North" and keep them with the special character encoded in the csv?
tonni has joined #ruby-lang
justinseiter has quit [Remote host closed the connection]
sailias has joined #ruby-lang
tonni has quit [Ping timeout: 260 seconds]
Kant has quit [Remote host closed the connection]
jxie has joined #ruby-lang
savage- has quit [Quit: savage-]
imajes has quit [Excess Flood]
imajes has joined #ruby-lang
woollyams has quit [Quit: Textual IRC Client: http://www.textualapp.com/]
datanoise has joined #ruby-lang
chimkan__ has quit [Quit: chimkan__]
Kant has joined #ruby-lang
chimkan has joined #ruby-lang
datanoise has quit [Ping timeout: 260 seconds]
sailias has quit [Ping timeout: 260 seconds]
wyhaines has quit [Remote host closed the connection]
ryanf_ has joined #ruby-lang
ryanf has quit [Quit: leaving]
ryanf_ is now known as ryanf
<Paradox> purple poop
<Spaceghostc2c> Paradox: Don't amsg
<Paradox> Spaceghostc2c, it wasnt an amsg, just to 3 chans
<Paradox> lol
<Paradox> but i wont
<Spaceghostc2c> :D
<musl> Knifin' around.
tpope has joined #ruby-lang
Serial_Killer_C has quit [Remote host closed the connection]
nXqd has joined #ruby-lang
keymone has quit [Read error: Connection reset by peer]
keymone has joined #ruby-lang
Dreamer3 has quit [Quit: Leaving...]
<zenspider> tsou: ss.string.byteslice(0, ss.len).length is what I needed :/
brianpWins has joined #ruby-lang
tenderlove has joined #ruby-lang
ryanf has quit [Quit: broken pipes |||]
ryanf_ has joined #ruby-lang
ryanf_ is now known as ryanf
savage- has joined #ruby-lang
perryh has quit [Excess Flood]
perryh has joined #ruby-lang
justinmcp has quit [Remote host closed the connection]
burgestrand has joined #ruby-lang
justinmcp has joined #ruby-lang
justinmcp has quit [Ping timeout: 260 seconds]
Mon_Ouie has joined #ruby-lang
yxhuvud has joined #ruby-lang
AlHafoudh has joined #ruby-lang
thinkdevcode has quit [Remote host closed the connection]
JohnBat26 has joined #ruby-lang
AlHafoudh has quit [Client Quit]
tonni has joined #ruby-lang
dc5ala has joined #ruby-lang
bhrgunatha has joined #ruby-lang
chimkan has quit [Remote host closed the connection]
chimkan has joined #ruby-lang
mistym has quit [Remote host closed the connection]
Kant has quit [Remote host closed the connection]
cirenyc has quit [Quit: Leaving...]
chimkan has quit [Ping timeout: 248 seconds]
bhrgunatha has quit [Quit: ChatZilla 0.9.89 [Firefox 19.0a1/20121101030705]]
tonni has quit [Remote host closed the connection]
chimkan has joined #ruby-lang
steph021 has joined #ruby-lang
richardjortega has quit [Quit: richardjortega]
tenderlove has quit [Read error: Connection reset by peer]
vikashk has joined #ruby-lang
tenderlove has joined #ruby-lang
chimkan__ has joined #ruby-lang
steph021 has quit [Client Quit]
savage- has quit [Quit: savage-]
nXqd has quit [Ping timeout: 264 seconds]
Uranio has quit [Ping timeout: 248 seconds]
nXqd has joined #ruby-lang
chimkan has quit [Ping timeout: 252 seconds]
chimkan__ is now known as chimkan
Guest15771 has joined #ruby-lang
charliesome has joined #ruby-lang
datanoise has joined #ruby-lang
datanoise has quit [Ping timeout: 255 seconds]
tonni has joined #ruby-lang
solars has joined #ruby-lang
chimkan has quit [Quit: chimkan]
rue|w has joined #ruby-lang
ryanf has quit [Quit: leaving]
rolfb has joined #ruby-lang
jbsan has quit [Read error: Connection reset by peer]
jbsan has joined #ruby-lang
mytrile has joined #ruby-lang
burgestrand has quit [Quit: Leaving.]
burgestrand has joined #ruby-lang
JohnBat26 has quit [Quit: KVIrc 4.3.1 Aria http://www.kvirc.net/]
burgestrand has quit [Ping timeout: 252 seconds]
jtoy has quit [Quit: jtoy]
JohnBat26 has joined #ruby-lang
justinmcp has joined #ruby-lang
workmad3 has joined #ruby-lang
gnufied has joined #ruby-lang
workmad3 has quit [Ping timeout: 240 seconds]
cschwartz has joined #ruby-lang
nazty has quit [Read error: Connection reset by peer]
qwerxy has joined #ruby-lang
nazty has joined #ruby-lang
srih4ri has joined #ruby-lang
rippa has joined #ruby-lang
<srih4ri> One of the tests i am looking at is failing because a caller[1] method is returning the full file name , but the test expects a relative file name.. When does output of caller[1] include full filename , and when it doesn't ? (It has something to do with the way i require files right?)
rippa has quit [Ping timeout: 265 seconds]
blacktulip has joined #ruby-lang
burgestrand has joined #ruby-lang
vikashk has quit [Quit: Leaving...]
havenn has quit [Remote host closed the connection]
srih4ri has quit [Ping timeout: 260 seconds]
Weems has quit [Ping timeout: 256 seconds]
GarethAdams has joined #ruby-lang
Weems has joined #ruby-lang
Weems has joined #ruby-lang
Weems has quit [Changing host]
ruurd has joined #ruby-lang
jarib has quit [Excess Flood]
jarib has joined #ruby-lang
justinmcp has quit [Remote host closed the connection]
vikashk has joined #ruby-lang
<yorickpeterse> Morning
<apeiros> evening!
achiu has quit [Quit: WeeChat 0.3.9]
irleif has joined #ruby-lang
chris2 has quit [Ping timeout: 260 seconds]
amaya_ has joined #ruby-lang
banisterfiend has joined #ruby-lang
<rolfb> morning!
adambeynon has joined #ruby-lang
chris2 has joined #ruby-lang
cyri_ has joined #ruby-lang
runeb has joined #ruby-lang
judofyr has joined #ruby-lang
keymone has quit [Quit: keymone]
Asher has quit [Ping timeout: 260 seconds]
cantonic has joined #ruby-lang
Asher has joined #ruby-lang
mylordangus has joined #ruby-lang
sn0wb1rd has quit [Quit: sn0wb1rd]
<tocki_> what is the meaning of unbound methods
<tocki_> i've seen that method can be unbound from one instance, and latter on bound to another instance of the same class
<tocki_> what is the purpose of this (if methods contain no state - since they are not closures like procs)
<tocki_> what is transfered from one instance to another (aside to the fact that object simply will not (or will) respond to method message)
sn0wb1rd has joined #ruby-lang
<zzak> i like to wear my crocs when composing lambdas or procs, it provides closure for any instance of my feet getting wet
benanne has joined #ruby-lang
<andrewvos> erikh: That looks quite cool, thanks.
amaya_ has quit [Read error: Connection reset by peer]
<zzak> yorickpeterse: please test it! one more preview before holidays and then feature freeze
<judofyr> tocki_: the purpose is so you can close over them yourself
<andrewvos> erikh: Though I'm not sure I understand how it will work on multiple devices. For example: Android devices have a back button, iphones don't. By very definition you're testing different applications.
<andrewvos> "by very definition" = "quite literally"
<yorickpeterse> zzak: I will give it a try this weekend
Mon_Ouie has quit [Ping timeout: 260 seconds]
<judofyr> tocki_: they are often used for monkey patching methods: class Foo; old = instance_method(:foo); define_method(:foo) { old.bind(self).call + 1 } end
<yorickpeterse> Is there any info on the performance impact of the refinements feature?
<tocki_> judofyr, interesting
<zzak> yorickpeterse: i think you will be interested in this ticket: https://bugs.ruby-lang.org/issues/7214
<yorickpeterse> Hmm
<tocki_> judofyr, thanks
<tocki_> what is greatest difference between 1.9.x branch & 2.0.x ?
<judofyr> tocki_: but more generally: without unbound method there wouldn't be a way to get an object for an instance method
<judofyr> tocki_: named arguments, refinements, Module#prepend, lazy enumerators
<yorickpeterse> and the GC improvements right?
<judofyr> yes
<judofyr> GC
<judofyr> bitmap
<judofyr> now we're just 20? 10? years behind Lisp GCs :)
wallerdev has quit [Quit: wallerdev]
workmad3 has joined #ruby-lang
<yorickpeterse> And list is 10 years behind on a proper syntax :)
<yorickpeterse> * Lisp
<judofyr> :D
jxie has quit [Quit: leaving]
<tocki_> has ruby switched to yarv on 1.9.x branch, or we are still using mri ?
<yorickpeterse> YARV
<tocki_> 2.0.0 is also yarv ?
<gnufied> yes
<tocki_> cool :)
<tocki_> refinements might make large projects very sensitive to 'context changes'.. monkey patching is somewhat conceptually simpler
<tocki_> is there a way to convert class to module (and vice versa) ?
benanne has quit [Ping timeout: 260 seconds]
<yorickpeterse> Why would you want to do that?
<yorickpeterse> They serve entirely different purposes
<andrewvos> Complains about refinements, then immediately asks how to convert a class to a module ;)
<yorickpeterse> Hm, seems I'll have some new syntax stuff to take care of as well with my linter for Ruby 2
<yorickpeterse> though that shouldn't be much of an issue
<tocki_> though they are not that much different
<judofyr> tocki_: MRI = the whole implementation. YARV = the VM that MRI uses since 1.9.
<tocki_> to say.. import all instance methods of a class into module as singleton methods
<tocki_> instance & class variables would automatically be recreated by simply referencing them
<yorickpeterse> If you want to turn a module into a class you'd have to define .new and .allocate I believe
<yorickpeterse> But one might ask himself: "Why not use a darn class instead"
<tocki_> true, thats what Class exactly does (as it inherits Module)
<yorickpeterse> But importing methods isn't that difficult
<tocki_> how!
<tocki_> how to transfer methods ?
<tocki_> between instances
<tocki_> of different classes
banisterfiend has quit [Ping timeout: 260 seconds]
<gnufied> some next level stuff going there
<gnufied> why will you want to transfer methods between instances of different classes? there is a reason classes have an interface
<yorickpeterse> tocki_: http://pastebin.com/raw.php?i=fm3BseFY Something along these lines
<yorickpeterse> Though I feel it can be done a lot easier than that
<yorickpeterse> and I'm not sure how to invoke UnboundMethod instances
<yorickpeterse> since #call() doesn't exist
<tocki_> yorickpeterse, yes - its close
<tocki_> but catch is in executing unbound method
benanne has joined #ruby-lang
<tocki_> having closure of dummy A class would probably do it
<tocki_> but thats... complicated
<yorickpeterse> To be honest I'd rather just define those methods in a module and include that
<tocki_> yes, but can this definition transfer be done without human ? :)
<yorickpeterse> without human?
<tocki_> how can ruby read method definition ?
jarib has quit [Excess Flood]
<tocki_> (aside from taking pointer to source, and parsing source afterwards to determine where method ends)
<tocki_> (which is what pry does)
<yorickpeterse> Start from the beginning: what's the problem you're having?
jarib has joined #ruby-lang
<tocki_> Is there a simple way to transfer method (method definition) from one class to another ?
<yorickpeterse> Right, what have you tried so far?
<judofyr> tocki_: method transplantation has been discussed on ruby-core. let me see if I can find a link.
<judofyr> transplanting*
<judofyr> tocki_: see this discussion: http://bugs.ruby-lang.org/issues/4254
<tocki_> yorickpeterse, don't know how to approach it at all
<tocki_> thank you, judofyr
<judofyr> tocki_: I think it's implemented in 2.0.0-preview1
<judofyr> tocki_: but no, in 1.9.3 there is no simple way
<judofyr> tocki_: actually, that only allows transplanting from a module to a class. not class to class.
<tocki_> heh.. its approved :)
<yorickpeterse> tocki_: hmm
<tocki_> module to module ?
<judofyr> yes. that too.
<judofyr> I think
<yorickpeterse> well, a dirty fix would be to simply redirect the method call
<tocki_> interesting :)
<yorickpeterse> define_method(name) { |*args| original_constant.send(name, *args) }
<yorickpeterse> but that doesn't actually move the method
<judofyr> yorickpeterse: that doesn't work for instance methods
<tocki_> yes, but what about class instance methods (and access to variables)
<yorickpeterse> judofyr: true
<tocki_> ok, this is quite important change :)
* judofyr installs 2.0.0-preview1
<judofyr> tocki_: you should install 2.0 too and test it yourself :)
<judofyr> "I'd like to allow method transplanting from a module, not a class, to either class or module." — matz
guns has joined #ruby-lang
<tocki_> so methods can be now poured around :)
<tocki_> from one class container to another
<judofyr> from one *module* to other classes/modules :)
<rolfb> remember children, it's important to write maintainable and readable code
<judofyr> pff
<rolfb> !yes
<tocki_> right.. module.. sorry :)
<yorickpeterse> zomg, that's so beautiful code
<yorickpeterse> * such
<rolfb> considering piping it to 'say'
<tocki_> this code will give someone a good laugh
<tocki_> it would not be maintainer
<tocki_> but someone close to him... sure :)
<rolfb> piping code to 'say' wasn't actually that bad :P
xalei has quit [Remote host closed the connection]
<rolfb> judofyr: why did you write it this way?
<yorickpeterse> I don't think judofyr wrote this :>
<yorickpeterse> I certain _why did
<rolfb> yorickpeterse: but i said why
<rolfb> :P
<judofyr> this is why I'm careful with updating my system: http://cl.ly/image/1e3A1s1P261n
<burgestrand> I see you like X11.
<judofyr> rolfb: _why wrote it, i refactored it
<yorickpeterse> judofyr: dude, you need to use a bigger font for your own name
<rolfb> :)
<yorickpeterse> wait...wait..
<yorickpeterse> are all those icons at the bottom X11 windows?
<judofyr> yes
<judofyr> 600 of them
<yorickpeterse> rofl
qwerxy has quit [Quit: offski]
elico has joined #ruby-lang
<tocki_> i'm still puzzled by nested singleton-classes.. if they can be put to any good use
<tocki_> right now they just seem like an.. language artifact..
<judofyr> tocki_: it would make it inconsistent if singleton classes didn't have singleton classes. all objects have singleton classes :)
<tocki_> true, but since singleton-class is unique for object (why have another one that can be nested)
<judofyr> hm?
<tocki_> though if you tried to do something like js prototyping in ruby (via object cloning), singleton_class.singleton_class would be unique for all related objects (all that originate from same primitive object)
<tocki_> while each cloned object would still have its own unique singleton_class
amaya_ has joined #ruby-lang
<judofyr> tocki_: if singleton classes didn't have singleton classes, then this wouldn't be possible: foo = "123"; def (foo.singleton_class).bar; 123 end; foo.singleton_class.bar
<judofyr> it's not a very useful feature
toretore has joined #ruby-lang
SoAwesomeMan has joined #ruby-lang
saLOUt_ has joined #ruby-lang
blacktulip has quit [Remote host closed the connection]
<tocki_> true, i just find it confusing.. since singleton class is something unique to object (then what is uniqueness of this uniqueness if not the very same thing)
<tocki_> btw, how to interpret this output:
<tocki_> => #<Class:#<Class:#<Class:#<Object:0x4d37e5>>>>
<tocki_> What do these nested classes mean ?
blacktulip has joined #ruby-lang
<tocki_> i get this from: jruby-1.6.8 :078 > cl.singleton_class.singleton_class
<judofyr> tocki_: the point about singleton classes is to be able to define methods that are only available on a single object
banisterfiend has joined #ruby-lang
<judofyr> tocki_: #<Object:0x4d37e5> is an object. #<Class:#<Object:0x4d37e5>> is that object's singletonclass. and because all (singleton)classes are also objects, #<Class:#<Class:#<Object:0x4d37e5>>> is that singleton class' singleton class
m3nd3s has joined #ruby-lang
<tocki_> Can there be anything else but "#<Class:" prefix ?
aetcore has quit []
aetcore has joined #ruby-lang
mylordangus has quit [Remote host closed the connection]
<judofyr> tocki_: that's how singleton classes are displayed
<banisterfiend> tocki_: of course...that just means anonymous class
ruurd has quit [Quit: Leaving...]
amaya_ has quit [Ping timeout: 244 seconds]
cultureulterior_ has joined #ruby-lang
<tocki_> hmmz.. it seems i can't inherit from singleton class even though (its .class is Class)
roadt has quit [Ping timeout: 246 seconds]
<banisterfiend> tocki_: they have some limitations, for reasons of sanity
<banisterfiend> tocki_: you can't instantiate them directly, either
<tocki_> it seems that singleton_class is 'virtual class', not full blood class like others
<tocki_> is singleton_class only virtual class ?
<banisterfiend> tocki_: it has some limitations that normal classes do not
<tocki_> hmmz.. it acts more like module than class
<judofyr> tocki_: hm… banisterfiend help me out here: is included-moduled called "virtual classes" or is it something else`
<judofyr> tocki_: but unlike a module it has a superclass
<banisterfiend> i dont see what you gain by calling them 'virtual', that's just a word, anyway
<tocki_> true!
<judofyr> banisterfiend: but included-module-classes are more "virtual" than singleton classes
<judofyr> because they have pointers into another module's struct
<tocki_> that is proxy class in inheritance chain ?
<tocki_> "proxy class"
runeb has quit [Remote host closed the connection]
<tocki_> for module
<judofyr> tocki_: yes. when you do: `class Foo; include Bar; end` then Foo's superclass is set to a proxy class of Bar.
<tocki_> and it is same entity breed as singleton cousin ?
<judofyr> tocki_: e.g.: `class Foo < Bar; include Baz; end` creates this inheritance chain: Foo < (Baz) < Bar
<judofyr> where (Baz) is a proxy/virtual class of Baz
<tocki_> cool
<judofyr> tocki_: every class has a method table pointer. a proxy class has a method table pointer which points to an existing method table.
<judofyr> (Baz) and Baz has the same method table pointer
runeb has joined #ruby-lang
<tocki_> cool, and this is used to resolve method invocations
<tocki_> its access-able from ruby as object.class.instance_method(false) ?
<banisterfiend> judofyr: i think the ruby source code refers to both singleton classes and iclasses as virtual classes
<banisterfiend> judofyr: have you looked at refinements much?
<banisterfiend> judofyr: is tehre a way to ask a class for a list of all modules that refine it?
<banisterfiend> i can go the other way, and ask a module which classes it refines..but htat's not as useful
<judofyr> tocki_: singleton classes always have an unique method table pointer
sepp2k has joined #ruby-lang
<tocki_> right.. but this is just resolving method invocation (from ruby perspective singleton_class is full blown object)
<judofyr> tocki_: yes
<judofyr> tocki_: method invocation always follows the superclass chain.
Hakon has joined #ruby-lang
elico has quit [Quit: Elico]
amaya_ has joined #ruby-lang
<tocki_> strongly typed languages really *need* OO (badly)
<tocki_> they *need* complex types, they need a way to handle numerous methods that deal with different types of data
<tocki_> but with dynamic languages its different.. we just need to organize our code
<tocki_> its a bit more fluid mindset
<tocki_> we should not be bound by idea of data-type (class)
<tocki_> though these `entities` are useful for organisation
<tocki_> imho
<workmad3> tocki_: incidentally, ruby is strongly typed
<workmad3> tocki_: it just isn't statically typed ;)
<tocki_> lol, i wanted to say statically typed :D
<workmad3> yeah, I figured :)
<workmad3> but I figured it was worth pointing out in case someone else misinterpreted what you'd said
<tocki_> thanks
Axsuul has joined #ruby-lang
perryh has quit [Excess Flood]
perryh has joined #ruby-lang
banisterfiend has quit [Remote host closed the connection]
tonni_ has joined #ruby-lang
qwerxy has joined #ruby-lang
ruurd has joined #ruby-lang
cultureulterior_ has quit [Ping timeout: 260 seconds]
jasiek_ has quit [Read error: Connection reset by peer]
cultureulterior_ has joined #ruby-lang
buscapepe has quit [Ping timeout: 255 seconds]
yalue has joined #ruby-lang
judofyr has quit [Remote host closed the connection]
aetcore has quit [Remote host closed the connection]
judofyr has joined #ruby-lang
aetcore has joined #ruby-lang
mwjcomputing has joined #ruby-lang
mwjcomputing has left #ruby-lang [#ruby-lang]
aetcore has quit [Remote host closed the connection]
jarib has quit [Excess Flood]
jarib has joined #ruby-lang
vikashk has quit [Quit: Leaving...]
lcdhoffman has joined #ruby-lang
outoftime has joined #ruby-lang
ruurd has quit [Read error: Connection reset by peer]
elico has joined #ruby-lang
irleif has quit [Quit: Computer has gone to sleep.]
ruurd has joined #ruby-lang
elico has quit [Client Quit]
chendo_ has quit [Ping timeout: 252 seconds]
chendo_ has joined #ruby-lang
aetcore has joined #ruby-lang
SoAwesomeMan has quit [Quit: ["Textual IRC Client: www.textualapp.com"]]
sullenel has joined #ruby-lang
cyri_ has quit [Quit: cyri_]
Madis has joined #ruby-lang
roadt has joined #ruby-lang
anachronistic has joined #ruby-lang
qwerxy has quit [Quit: offski]
cyri_ has joined #ruby-lang
jasiek has joined #ruby-lang
ddd has quit [Read error: Connection reset by peer]
irleif has joined #ruby-lang
cek2 has joined #ruby-lang
blacktul_ has joined #ruby-lang
tonni_ has quit [Remote host closed the connection]
irleif has quit [Quit: Computer has gone to sleep.]
blacktulip has quit [Ping timeout: 246 seconds]
Hakon has quit [Quit: Leaving...]
roadt has quit [Ping timeout: 256 seconds]
ddd has joined #ruby-lang
banisterfiend has joined #ruby-lang
ddd has quit [Client Quit]
ddd has joined #ruby-lang
anannie has joined #ruby-lang
totallymike has quit [Read error: Connection reset by peer]
x0F has quit [Disconnected by services]
x0F_ has joined #ruby-lang
x0F_ is now known as x0F
roadt has joined #ruby-lang
roadt has quit [Max SendQ exceeded]
roadt has joined #ruby-lang
roadt has quit [Max SendQ exceeded]
roadt has joined #ruby-lang
Hakon has joined #ruby-lang
cyri_ has quit [Quit: cyri_]
AlHafoudh has joined #ruby-lang
Hakon has quit [Client Quit]
jamjam has joined #ruby-lang
irleif has joined #ruby-lang
roadt has quit [Ping timeout: 260 seconds]
banisterfiend has quit [Ping timeout: 264 seconds]
AlHafoudh has quit [Quit: Textual IRC Client: http://www.textualapp.com/]
dhruvasagar has quit [Ping timeout: 245 seconds]
roadt has joined #ruby-lang
dhruvasagar has joined #ruby-lang
roadt has quit [Max SendQ exceeded]
voker57 has quit [Read error: Connection reset by peer]
roadt has joined #ruby-lang
nertzy has joined #ruby-lang
saLOUt_ has quit [Remote host closed the connection]
cirenyc has joined #ruby-lang
afader has joined #ruby-lang
afader has quit [Changing host]
afader has joined #ruby-lang
lcdhoffman has quit [Quit: lcdhoffman]
sailias has joined #ruby-lang
dhruvasagar has quit [Ping timeout: 244 seconds]
sailias has quit [Ping timeout: 252 seconds]
dhruvasagar has joined #ruby-lang
tubbo`cloud is now known as tubbo
ruurd has quit [Quit: Leaving...]
aetcore has quit [Remote host closed the connection]
stardiviner has quit [Quit: my website: http://stardiviner.dyndns-blog.com/]
aetcore has joined #ruby-lang
Hakon has joined #ruby-lang
vikashk has joined #ruby-lang
cyri_ has joined #ruby-lang
sailias has joined #ruby-lang
lcdhoffman has joined #ruby-lang
sandbags has joined #ruby-lang
sandbags has quit [Changing host]
sandbags has joined #ruby-lang
Hakon has quit [Ping timeout: 240 seconds]
rippa has joined #ruby-lang
lcdhoffman has quit [Read error: Connection reset by peer]
lcdhoffman has joined #ruby-lang
aetcore has quit [Remote host closed the connection]
guns has quit [Quit: guns]
irleif has quit [Quit: Computer has gone to sleep.]
rippa has quit [Ping timeout: 265 seconds]
mpan has quit [Ping timeout: 260 seconds]
perryh has quit [Excess Flood]
perryh has joined #ruby-lang
sailias has quit [Quit: Leaving.]
<tsou> zenspider: ..and not ss.pre_match.length ?
aetcore has joined #ruby-lang
justinram has joined #ruby-lang
aetcore has quit [Remote host closed the connection]
rolfb has quit [Quit: Linkinus - http://linkinus.com]
anachronistic has quit [Quit: anachronistic]
nemish has joined #ruby-lang
Spakman has joined #ruby-lang
irleif has joined #ruby-lang
methods has joined #ruby-lang
lcdhoffman has quit [Ping timeout: 252 seconds]
rue|w has quit [Remote host closed the connection]
wyhaines has joined #ruby-lang
cirenyc has quit [Quit: Leaving...]
cirenyc has joined #ruby-lang
gsav has joined #ruby-lang
cirenyc has quit [Client Quit]
justinram has quit [Remote host closed the connection]
m3nd3s has quit [Remote host closed the connection]
Serial_Killer_C has joined #ruby-lang
qwerxy has joined #ruby-lang
<Spakman> does anyone know if there is a way to access rb_reserved_fd_p() from Ruby (aside from FFI or a C extension)?
methods has left #ruby-lang [#ruby-lang]
wyhaines has quit [Remote host closed the connection]
charliesome has quit [Quit: Textual IRC Client: www.textualapp.com]
justinram has joined #ruby-lang
vikashk has quit [Quit: Leaving...]
thisirs has joined #ruby-lang
justinram has quit [Ping timeout: 240 seconds]
i_like_rails has joined #ruby-lang
anachronistic has joined #ruby-lang
gsav_ has joined #ruby-lang
<i_like_rails> I need to traverse a directory and for each result, figure out if it's a file or directory. For some reason, from the Dir.foreach, some of the results are failing .directory? and .file?. Should I be using some other Ruby API for this?
<andrewvos> i_like_rails: Which results are failing?
<andrewvos> i_like_rails: Could it be they are a symbolic link, or maybe a "." / ".." ?
<i_like_rails> andrewvos: It thinks that. and .. are directories, which is fine. But then it thinks that subdirectories and not directories or files, and the same with files. No symlinks, either.
<andrewvos> i_like_rails: `ls -ltah | gist.github.com`
mytrile has quit [Remote host closed the connection]
<i_like_rails> andrewvos: I'm not sure if the foreach for Dir is just meant to print out file names or what. The name variable is just a String, which seems weird.
herpless_ is now known as herpless
mistym has joined #ruby-lang
mistym has quit [Changing host]
mistym has joined #ruby-lang
<i_like_rails> andrewvos: If I use Find.find, it knows which are directories and which are files
cantonic has quit [Quit: cantonic]
<andrewvos> i_like_rails: I'm not sure about foreach. You might try Dir["*"] instead. It doesn't list ".." or "." which is good.
sullenel has quit [Quit: Leaving.]
<i_like_rails> andrewvos: Thanks
<andrewvos> i_like_rails: Or Dir.glob, but I might get chastised in here because everyone loves [].
perryh has quit [Excess Flood]
<i_like_rails> andrewvos: Sure, thanks
<andrewvos> (They're the same, except glob takes a block)
perryh has joined #ruby-lang
gsav has quit [Quit: Lost terminal]
amaya_ has quit [Quit: ChatZilla 0.9.88.2 [Firefox 16.0.2/20121024073032]]
gnufied has quit [Quit: Leaving.]
dpatel has joined #ruby-lang
m3nd3s has joined #ruby-lang
kith has quit [Read error: Connection reset by peer]
brianpWins has quit [Quit: brianpWins]
earthquake has joined #ruby-lang
gnufied has joined #ruby-lang
Kant has joined #ruby-lang
bfreeman has quit [Quit: bfreeman]
krohrbaugh has quit [Quit: Leaving.]
havenn has joined #ruby-lang
rue|w has joined #ruby-lang
vikashk has joined #ruby-lang
areil has quit [Remote host closed the connection]
JospehJ has joined #ruby-lang
thorncp has quit [Quit: hills]
rue|w has quit [Ping timeout: 255 seconds]
Kant has quit [Remote host closed the connection]
vikashk has quit [Quit: Linkinus - http://linkinus.com]
m3nd3s has quit [Remote host closed the connection]
jxie has joined #ruby-lang
clocKwize has quit [Remote host closed the connection]
m3nd3s has joined #ruby-lang
tenderlove has quit [Remote host closed the connection]
senekis has joined #ruby-lang
tenderlove has joined #ruby-lang
i_like_rails has quit [Quit: Page closed]
brianpWins has joined #ruby-lang
tenderlove has quit [Ping timeout: 256 seconds]
TheDracle has joined #ruby-lang
datanoise has joined #ruby-lang
gnufied has quit [Quit: Leaving.]
justinram has joined #ruby-lang
gnufied has joined #ruby-lang
qwerxy has quit [Quit: offski]
wallerdev has joined #ruby-lang
qwerxy has joined #ruby-lang
krohrbaugh has joined #ruby-lang
perryh has quit [Excess Flood]
perryh has joined #ruby-lang
tenderlove has joined #ruby-lang
tenderlove has quit [Remote host closed the connection]
judofyr has quit [Remote host closed the connection]
outoftime has quit [Quit: Leaving]
tallship has joined #ruby-lang
cek2 has quit [Ping timeout: 252 seconds]
blazes816 has joined #ruby-lang
slyphon has quit [Ping timeout: 245 seconds]
mistym has quit [Remote host closed the connection]
alvaro_o has joined #ruby-lang
burgestrand has quit [Quit: Leaving.]
__butch__ has joined #ruby-lang
sn0wb1rd has quit [Quit: sn0wb1rd]
irleif has quit [Quit: Computer has gone to sleep.]
thisirs has quit [Remote host closed the connection]
davidbalber|away is now known as davidbalbert
kurko_ has joined #ruby-lang
cek2 has joined #ruby-lang
ryanlecompte has joined #ruby-lang
kurko_ has quit [Ping timeout: 244 seconds]
cek2 has quit [Client Quit]
judofyr has joined #ruby-lang
cek2 has joined #ruby-lang
perryh has quit [Remote host closed the connection]
postmodern has quit [Quit: Leaving]
senekis_ has joined #ruby-lang
kurko_ has joined #ruby-lang
senekis has quit [Ping timeout: 256 seconds]
qwerxy has quit [Quit: offski]
Uranio has joined #ruby-lang
JospehJ has quit [Remote host closed the connection]
chimkan_ has joined #ruby-lang
qwerxy has joined #ruby-lang
bfreeman has joined #ruby-lang
senekis has joined #ruby-lang
senekis_ has quit [Read error: Connection reset by peer]
Dreamer3 has joined #ruby-lang
jarib has quit [Excess Flood]
JohnBat26 has quit [Quit: KVIrc 4.3.1 Aria http://www.kvirc.net/]
cirenyc has joined #ruby-lang
nertzy has quit [Quit: This computer has gone to sleep]
jarib has joined #ruby-lang
mpan has joined #ruby-lang
wyhaines has joined #ruby-lang
svyatov has joined #ruby-lang
thinkdevcode has joined #ruby-lang
kurko_ has quit [Ping timeout: 252 seconds]
davidbalbert is now known as davidbalber|away
kurko_ has joined #ruby-lang
wyhaines has quit [Read error: Connection reset by peer]
wyhaines has joined #ruby-lang
benanne has quit [Quit: kbai]
davidbalber|away is now known as davidbalbert
Uranio has quit [Quit: WeeChat 0.3.8]
wyhaines_ has joined #ruby-lang
irleif has joined #ruby-lang
nXqd has quit [Ping timeout: 245 seconds]
Kingy has joined #ruby-lang
wyhaines has quit [Ping timeout: 252 seconds]
sn0wb1rd has joined #ruby-lang
nXqd has joined #ruby-lang
qwerxy has quit [Quit: offski]
irleif has quit [Quit: Computer has gone to sleep.]
mrsolo has joined #ruby-lang
judofyr has quit [Remote host closed the connection]
judofyr has joined #ruby-lang
mpan has quit [Ping timeout: 252 seconds]
irleif has joined #ruby-lang
judofyr has quit [Ping timeout: 256 seconds]
heftig has quit [Ping timeout: 245 seconds]
gnufied has quit [Quit: Leaving.]
heftig has joined #ruby-lang
ryanlecompte has quit [Remote host closed the connection]
runeb has quit [Remote host closed the connection]
cantonic has joined #ruby-lang
irleif has quit [Quit: Computer has gone to sleep.]
dhruvasagar has quit [Ping timeout: 248 seconds]
havenn has quit [Remote host closed the connection]
havenn has joined #ruby-lang
kitallis has joined #ruby-lang
chimkan_ has quit [Quit: chimkan_]
uuair has joined #ruby-lang
mpan has joined #ruby-lang
irleif has joined #ruby-lang
havenn has quit [Ping timeout: 252 seconds]
Kingy has quit [Quit: Leaving]
wallerdev has quit [Quit: wallerdev]
rolfb has joined #ruby-lang
cirenyc has quit [Quit: Leaving...]
sush24 has joined #ruby-lang
__butch__ has quit [Quit: Leaving.]
cultureulterior_ has quit [Quit: cultureulterior_]
outoftime has joined #ruby-lang
<yorickpeterse> Allright, lets give this Ruby 2.0 thing a try
kurko_ has quit [Ping timeout: 260 seconds]
kurko_ has joined #ruby-lang
Aiur has joined #ruby-lang
senekis_ has joined #ruby-lang
kurko_ has quit [Ping timeout: 252 seconds]
senekis has quit [Ping timeout: 256 seconds]
kurko_ has joined #ruby-lang
__butch__ has joined #ruby-lang
thatdutchguy has quit [Remote host closed the connection]
sepp2k1 has joined #ruby-lang
gregmoreno has quit [Read error: Connection reset by peer]
sepp2k has quit [Ping timeout: 256 seconds]
gregmoreno has joined #ruby-lang
cantonic has quit [Quit: cantonic]
chimkan has joined #ruby-lang
headius has joined #ruby-lang
uuair has quit [Quit: uuair]
uuair has joined #ruby-lang
workmad3 has quit [Ping timeout: 255 seconds]
Rizzle has quit [Ping timeout: 264 seconds]
rolfb has quit [Quit: Linkinus - http://linkinus.com]
gix has quit [Read error: Connection reset by peer]
dc5ala has quit [Quit: laters]
kitallis has quit [Quit: Computer has gone to sleep.]
_Mon_Ouie_ has left #ruby-lang [#ruby-lang]
Mon_Ouie has joined #ruby-lang
m3nd3s has quit [Remote host closed the connection]
gix has joined #ruby-lang
ryanlecompte has joined #ruby-lang
headius has quit [Quit: headius]
wallerdev has joined #ruby-lang
dhruvasagar has joined #ruby-lang
<yorickpeterse> Jezus christ the Ruby FTP server is slow
<yorickpeterse> 12 kb/sec
rolfb has joined #ruby-lang
burgestrand has joined #ruby-lang
ruskie has quit [Quit: ...]
kurko_ has quit [Ping timeout: 260 seconds]
senekis has joined #ruby-lang
kurko_ has joined #ruby-lang
cschwartz has quit [Ping timeout: 240 seconds]
senekis_ has quit [Ping timeout: 256 seconds]
adambeynon has quit [Quit: ["Textual IRC Client: www.textualapp.com"]]
cyri_ has quit [Quit: cyri_]
earthquake has quit [Quit: earthquake]
<herpless> is there a function to get all the values from an array and then empty it (while returning the values)? right now I'm doing: values = array.pop(array.length)
roadt has quit [Ping timeout: 252 seconds]
cirenyc has joined #ruby-lang
<yorickpeterse> Anybody else having some trouble with the FTP server, you can download a mirror here: http://downloads.yorickpeterse.com/files/ruby-2.0.0-preview1.tar.gz
<apeiros> herpless: err, that makes no sense really…
wyhaines_ has quit [Remote host closed the connection]
<apeiros> but… values = array.dup; array.clear
ruskie has joined #ruby-lang
<burgestrand> heh
mpan has quit [Ping timeout: 260 seconds]
<yorickpeterse> Nice! Keyword arguments work with the old hash syntax as well
<herpless> apeiros: well, I have a messages buffer, and I want to get the messages and clear the buffer. now, if I were to do values = buffer; buffer.clear or so, there's a short span between those two functions in which a new entry to the buffer could've been added (very small, but possible, I think) and the new entry would be lost. that's possible, yes?
cantonic has joined #ruby-lang
cirenyc has quit [Ping timeout: 245 seconds]
achiu has joined #ruby-lang
thorncp has joined #ruby-lang
runeb has joined #ruby-lang
chimkan__ has joined #ruby-lang
qpingu has joined #ruby-lang
nertzy has joined #ruby-lang
cschwartz has joined #ruby-lang
runeb has quit [Ping timeout: 264 seconds]
GarethAdams has quit [Quit: Leaving...]
chimkan has quit [Ping timeout: 260 seconds]
chimkan__ is now known as chimkan
Assurbanipal has joined #ruby-lang
<yorickpeterse> Damn, it seems Ruby 2.0 is also quite a bit faster
<yorickpeterse> test suite (with errors) runs in about 1 second on 1.9.3 and in about 860ms on 2.0
Uranio has joined #ruby-lang
kjr has joined #ruby-lang
senekis_ has joined #ruby-lang
senekis has quit [Ping timeout: 256 seconds]
slyphon has joined #ruby-lang
adambeynon has joined #ruby-lang
rindolf has joined #ruby-lang
Carnage\ has joined #ruby-lang
irleif has quit [Quit: Computer has gone to sleep.]
cored has joined #ruby-lang
cored has quit [Changing host]
cored has joined #ruby-lang
<apeiros> herpless: only if you have a threaded env and then you should probably have proper thread safe datastructures in place anyway
adambeynon has quit [Quit: ["Textual IRC Client: www.textualapp.com"]]
kurko_ has quit [Ping timeout: 245 seconds]
<herpless> apeiros: I am using threads. I'm relatively new to ruby; what's considered a "proper thread safe datastructure"? (eventually have any docs/posts or so where I can read about this?)
havenn has joined #ruby-lang
<apeiros> herpless: in your case, you probably want Queue
<apeiros> and then there's no reason to get all currently "on the queue" items usually. just process them one by one. which is what you'll most likely do anyway…
sandbags has quit [Remote host closed the connection]
kurko_ has joined #ruby-lang
<herpless> awesome, thanks. i'll take a look at it.
nyuszika7h has quit [Remote host closed the connection]
irleif has joined #ruby-lang
nyuszika7h has joined #ruby-lang
kentos has joined #ruby-lang
justinram has quit [Remote host closed the connection]
kurko_ has quit [Quit: Computer has gone to sleep.]
irleif has quit [Quit: Computer has gone to sleep.]
uuair has quit [Quit: uuair]
senekis_ has quit [Ping timeout: 256 seconds]
senekis has joined #ruby-lang
kurko_ has joined #ruby-lang
m3nd3s has joined #ruby-lang
irleif has joined #ruby-lang
bluepojo has joined #ruby-lang
<reactormonk> herpless, and I have to say jruby got some nice threading stuff
outoftime has quit [Quit: Leaving]
<cored> hello everyone
<cored> I have a general doubt regarding testing on a web framework
<cored> I have this sinatra app which is faulting to a nil exception, because of smoething like current_user.projects.first.id
<cored> before that line I have a line that's says, current_user.projects.count > 1, and then I try to access the id in the first item, the thing is that even when I know that I have to double check that assertion I want to add an spec to assert that the bug is gone
kurko_ has quit [Ping timeout: 276 seconds]
<cored> don't know if is better to do thta inside the routes specs, which as far as I can see in others projects they just check for noticing the the actual route returns the proper http code, or add the test some where else. Any suggestion on this ?
kurko_ has joined #ruby-lang
lcdhoffman has joined #ruby-lang
justinram has joined #ruby-lang
alexkane has quit [Quit: alexkane]
<steveklabnik> what are sinatra 'routes specs'?
kurko_ has quit [Quit: Computer has gone to sleep.]
rolfb has quit [Quit: Linkinus - http://linkinus.com]
irleif has quit [Quit: Computer has gone to sleep.]
workmad3 has joined #ruby-lang
cirenyc has joined #ruby-lang
wyhaines has joined #ruby-lang
savage- has joined #ruby-lang
cek2 has left #ruby-lang [#ruby-lang]
ryanlecompte has quit [Ping timeout: 260 seconds]
workmad3 has quit [Ping timeout: 260 seconds]
GarethAdams has joined #ruby-lang
chimkan_ has joined #ruby-lang
chimkan has quit [Read error: Operation timed out]
joast has quit [Remote host closed the connection]
cirenyc has quit [Remote host closed the connection]
cirenyc has joined #ruby-lang
chimkan_ has quit [Ping timeout: 276 seconds]
cirenyc has quit [Ping timeout: 246 seconds]
kgrz has joined #ruby-lang
GarethAdams has quit [Quit: Leaving...]
irleif has joined #ruby-lang
workmad3 has joined #ruby-lang
Dreamer3 has quit [Quit: Leaving...]
Dreamer3 has joined #ruby-lang
steveklabnik has quit [Ping timeout: 256 seconds]
Dreamer3 has quit [Client Quit]
Dreamer3 has joined #ruby-lang
<ddd> can someone tell me where I can find info on, or just tell me, the specific role of GEM_DIR? GEM_PATH is for the binaries installed by the various gems, and GEM_HOME (if modified) is for where gems should be installed. But I am failing to find information on what GEM_DIR's specific responsibility is
sush24 has quit [Ping timeout: 268 seconds]
<ddd> I've been googling but not finding specific docs on its role. figured I'd ask here and see if anyone had urls they could throw at me, or a specific explanation of the var's role.
gsav_ has quit [Ping timeout: 256 seconds]
<ddd> my other question that directly relates to that (and could be why I'm failing to find the proper docs due to cross-over) is: Is GEM_DIR a *ruby* variable, since gem is part of ruby with the 1.9 series, or is that a variable specifically part of rubygems (rubygems.org)? I've been looking through the docs there too and can't find a specific reference to that specific var's role or usage pattern
outoftime has joined #ruby-lang
havenn has quit [Remote host closed the connection]
<ddd> --
havenn has joined #ruby-lang
alexkane has joined #ruby-lang
cyri_ has joined #ruby-lang
<ddd> to be a bit more thorough, I've come across docs like http://fedoraproject.org/wiki/PackagingDrafts/Ruby which show it set to /usr/share/gems which states its where gems live. But non-project specific information or usage patterns aren't answering to my google-fu :)
<ddd> the closest i've gotten is rubygems specific which is http://docs.rubygems.org/read/chapter/13 Section 5.3
workmad3 has quit [Ping timeout: 240 seconds]
headius has joined #ruby-lang
<zenspider> GEM_DIR??
<ddd> yes
<ddd> hehe thats why i'm asking. i don't know its use
<zenspider> has nothing to do with rubygems... so....
havenn has quit [Ping timeout: 260 seconds]
<ddd> i see GEM_PATH, GEM_HOME, and GEM_DIR referenced in many conversations so I went digging. I can find information on the first two but not GEM_DIR, so I'm a bit confused
<zenspider> again... not part of rubygems
<ddd> ok. wonder if its just a variable most of the ruby version managers use and thus is specific to that particular role
<ddd> thanks zenspider. so the only two i really need to know is GEM_(PATH|DIR) correct?
<ddd> s/DIR/HOME/
mpan has joined #ruby-lang
<ddd> i'll take the silence as a 'duh!' :)
<zenspider> I have no idea what context you're working within... so I can't ansnwer that
havenn has joined #ruby-lang
<ddd> well, I'm actually working with Dash for OSX which is a doc set lookup tool. Trying to ascertain the needed directories (using the available variables so things aren't hard coded) to look at for grabbing rdocs to dynamically turn into doc sets that are pulled into Dash. (http://kapeli.com/dash/)
voker57 has joined #ruby-lang
voker57 has quit [Changing host]
voker57 has joined #ruby-lang
irleif has quit [Quit: Computer has gone to sleep.]
gsav has joined #ruby-lang
cored has quit [Ping timeout: 268 seconds]
irleif has joined #ruby-lang
cored has joined #ruby-lang
cored has quit [Changing host]
cored has joined #ruby-lang
Rizzle has joined #ruby-lang
kith has joined #ruby-lang
dc5ala has joined #ruby-lang
hakunin has joined #ruby-lang
cored has quit [Ping timeout: 260 seconds]
kurko_ has joined #ruby-lang
cored has joined #ruby-lang
Guest15771 has quit [Quit: Guest15771]
benanne has joined #ruby-lang
dc5ala has quit [Quit: Ex-Chat]
irleif has quit [Quit: Computer has gone to sleep.]
<whitequark> zenspider: ohai
jtoy has joined #ruby-lang
<whitequark> could you post those 182 files which RP currently fails? I'm curious
KU0N has joined #ruby-lang
totallymike has joined #ruby-lang
workmad3 has joined #ruby-lang
havenn has quit [Remote host closed the connection]
havenn has joined #ruby-lang
runeb has joined #ruby-lang
irleif has joined #ruby-lang
yalue has quit [Quit: Leaving]
havenn has quit [Ping timeout: 256 seconds]
justinmcp has joined #ruby-lang
workmad3 has quit [Ping timeout: 245 seconds]
mpan has quit [Ping timeout: 252 seconds]
kentos has quit [Quit: Leaving]
kentos has joined #ruby-lang
lcdhoffman has quit [Quit: lcdhoffman]
jtoy has quit [Quit: jtoy]
irleif has quit [Quit: Computer has gone to sleep.]
Carnage\ has quit []
omeichim has joined #ruby-lang
omeichim has quit [Client Quit]
s0ber has quit [Read error: Connection reset by peer]
s0ber has joined #ruby-lang
nertzy2 has joined #ruby-lang
ryanlecompte has joined #ruby-lang
workmad3 has joined #ruby-lang
headius has quit [Quit: headius]
omeichim has joined #ruby-lang
headius has joined #ruby-lang
headius has quit [Client Quit]
nertzy has quit [Ping timeout: 260 seconds]
irleif has joined #ruby-lang
savage- has quit [Ping timeout: 248 seconds]
omeichim has left #ruby-lang [#ruby-lang]
mpan has joined #ruby-lang
headius has joined #ruby-lang
thinkdevcode has quit [Remote host closed the connection]
havenn has joined #ruby-lang
steveklabnik has joined #ruby-lang
blazes816 has left #ruby-lang [#ruby-lang]
Uranio has quit [Remote host closed the connection]
kurko_ has quit [Quit: Computer has gone to sleep.]
svyatov has quit [Quit: svyatov]
havenn_ has joined #ruby-lang
faces has joined #ruby-lang
datanoise has quit [Ping timeout: 248 seconds]
steez_ has joined #ruby-lang
havenn has quit [Read error: Connection reset by peer]
facest has quit [Read error: Connection reset by peer]
Guest41156 has quit [Read error: Operation timed out]
adam12 has quit [Read error: Operation timed out]
jarib has quit [Read error: Operation timed out]
steez has quit [Read error: Operation timed out]
t0h has quit [Read error: Operation timed out]
t0h has joined #ruby-lang
jarib_ has joined #ruby-lang
chimkan has joined #ruby-lang
adam12 has joined #ruby-lang
Guest41156 has joined #ruby-lang
svyatov has joined #ruby-lang
davidbalbert is now known as davidbalber|away
Guest41156 has quit [Read error: Operation timed out]
Guest41156 has joined #ruby-lang
jarib_ has quit [Excess Flood]
jarib has joined #ruby-lang
tallship has quit [Read error: Operation timed out]
headius has quit [Quit: headius]
adambeynon has joined #ruby-lang
qpingu has quit [Read error: Operation timed out]
Guest41156 has quit [Read error: Operation timed out]
wnd^ has quit [Excess Flood]
qpingu has joined #ruby-lang
wnd has joined #ruby-lang
tallship has joined #ruby-lang
adam12 has quit [Ping timeout: 252 seconds]
Guest41156 has joined #ruby-lang
adam12 has joined #ruby-lang
blazes816 has joined #ruby-lang
Uranio has joined #ruby-lang
davidbalber|away is now known as davidbalbert
headius has joined #ruby-lang
justinseiter has joined #ruby-lang
workmad3 has quit [Ping timeout: 240 seconds]
headius has quit [Client Quit]
justinmcp has quit [Remote host closed the connection]
justinseiter has quit [Ping timeout: 256 seconds]
mpan has quit [Quit: Leaving]
blacktul_ has quit [Remote host closed the connection]
kjr has quit [Quit: kjr]
havenn_ has quit [Remote host closed the connection]
havenn has joined #ruby-lang
gsav has quit [Ping timeout: 244 seconds]
roadt has joined #ruby-lang
justinseiter has joined #ruby-lang
rindolf has quit [Quit: Yay! I'm a llama again. http://www.shlomifish.org/]
datanoise has joined #ruby-lang
irleif has quit [Quit: Computer has gone to sleep.]
havenn has quit [Ping timeout: 260 seconds]
kentos has quit [Quit: Leaving]
chimkan has quit [Quit: chimkan]
kurko_ has joined #ruby-lang
Serial_Killer_C has quit [Remote host closed the connection]
KU0N has quit [Quit: Linkinus - http://linkinus.com]
Assurbanipal has quit [Quit: Konversation terminated!]
headius has joined #ruby-lang
nXqd has quit [Ping timeout: 268 seconds]
datanoise has quit [Ping timeout: 246 seconds]
Axsuul has quit [Ping timeout: 268 seconds]
Axsuul has joined #ruby-lang
justinmcp has joined #ruby-lang
senekis has quit [Remote host closed the connection]
mantono has quit [Quit: Don't panic]
Guest41156 has quit [Read error: Operation timed out]
kurko_ has quit [Ping timeout: 252 seconds]
Guest41156 has joined #ruby-lang
kurko_ has joined #ruby-lang
chimkan has joined #ruby-lang
rdavila has joined #ruby-lang
adambeynon has quit [Quit: ["Textual IRC Client: www.textualapp.com"]]
nemish has quit [Quit: nemish]
afader has quit []
gregmore_ has joined #ruby-lang
kurko_ has quit [Ping timeout: 260 seconds]
gregmoreno has quit [Ping timeout: 244 seconds]
kjr has joined #ruby-lang
Dreamer3 has quit [Quit: Computer has gone to sleep.]
kurko_ has joined #ruby-lang
Mchl has quit [Quit: ZNC - http://znc.sourceforge.net]
Mchl has joined #ruby-lang
nertzy2 has quit [Quit: This computer has gone to sleep]
headius has quit [Quit: headius]
ipabs has quit [Ping timeout: 256 seconds]
datanoise has joined #ruby-lang
justinseiter has quit [Ping timeout: 260 seconds]
justinseiter has joined #ruby-lang
datanoise has quit [Ping timeout: 255 seconds]
Dreamer3 has joined #ruby-lang
justinseiter has quit [Ping timeout: 255 seconds]
rdavila has quit [Quit: rdavila]
thisirs has joined #ruby-lang
DEac- has joined #ruby-lang
DEac-_ has quit [Read error: Connection reset by peer]
CaptainJet has joined #ruby-lang
justinseiter has joined #ruby-lang
mistym has joined #ruby-lang
mistym has quit [Changing host]
mistym has joined #ruby-lang
geermc4 has joined #ruby-lang
jamjam has quit [Ping timeout: 245 seconds]
CaptainJet has quit []
kjr has quit [Quit: kjr]
CaptainJet has joined #ruby-lang
chimkan has quit [Quit: chimkan]
havenn has joined #ruby-lang
jasiek_ has joined #ruby-lang
jasiek has quit [Read error: Connection reset by peer]
franckverrot has quit [Ping timeout: 264 seconds]
franckverrot has joined #ruby-lang
blazes816 has quit [Quit: blazes816]
Aiur has quit [Quit: ["Textual IRC Client: www.textualapp.com"]]
havenn has quit [Ping timeout: 252 seconds]
thinkdevcode has joined #ruby-lang
kurko_ has quit [Ping timeout: 252 seconds]
kurko_ has joined #ruby-lang
__butch__ has quit [Quit: Leaving.]
mrsolo has quit [Quit: Leaving]
cantonic has quit [Quit: cantonic]
justinseiter has quit [Ping timeout: 240 seconds]
solars has quit [Ping timeout: 268 seconds]
kurko_ has quit [Ping timeout: 260 seconds]
roadt has quit [Ping timeout: 260 seconds]
kurko_ has joined #ruby-lang