Forum: Ruby How can we use pointer concept in Ruby?

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
1eb28f3c91b0a7b8bfb1a72cfa8befaa?d=identicon&s=25 Jaimin Pandya (jaimin)
on 2014-04-30 21:40
How can we use pointer concept (which we are using in C programming) in
Ruby?
B078cb4f4fb473c7a54d1fc36d10c70e?d=identicon&s=25 Regis d'Aubarede (raubarede)
on 2014-04-30 22:25
Jaimin Pandya wrote in post #1144580:
> How can we use pointer concept (which we are using in C programming) in
> Ruby?

all object are pointer (handle) on an object instance.
and method, class, module, thread... are ruby Object
So writing ruby code is  using pointers ...

But
* you can't use algebra on pointer : no addition/substraction
* you can't get the real memory address of an object

So  ruby interpreter implementation is free to use his self addressing
mechanism, which can not to be memory pointer (as in JVM/JRuby).
This topic is locked and can not be replied to.