Page 1 of 1

(RUBY) The mysterious parents of Jack...

Posted: Fri Jul 10, 2015 8:18 pm
by tulamide
If you've played around with Ruby a bit, you probably stumbled across two undocumented Ruby instance methods: caption and parent.

While I already explained what caption does, it wasn't until now that I found out what parent is good for. Instead of explaining it, I'll show it to you in this little schematic.

I'm already trying to find any use for this...

Re: (RUBY) The mysterious parents of Jack...

Posted: Fri Jul 10, 2015 9:42 pm
by KG_is_back
Can you use them to change names of parent an child?

Re: (RUBY) The mysterious parents of Jack...

Posted: Fri Jul 10, 2015 11:43 pm
by martinvicanek
Freaky stuff. :ugeek:

Re: (RUBY) The mysterious parents of Jack...

Posted: Sat Jul 11, 2015 6:38 am
by tulamide
KG_is_back wrote:Can you use them to change names of parent an child?

I wish. But I couldn't find a way :(

Re: (RUBY) The mysterious parents of Jack...

Posted: Sat Jul 11, 2015 6:12 pm
by MyCo

Re: (RUBY) The mysterious parents of Jack...

Posted: Sun Jul 12, 2015 11:37 pm
by tulamide
Indeed, you were. And not just seconds, but years! :mrgreen: