D7net
Home
Console
Upload
information
Create File
Create Folder
About
Tools
:
/
opt
/
alt
/
ruby18
/
share
/
ri
/
1.8
/
system
/
Object
/
Filename :
remove_instance_variable-i.yaml
back
Copy
--- !ruby/object:RI::MethodDescription aliases: [] block_params: comment: - !ruby/struct:SM::Flow::P body: Removes the named instance variable from <em>obj</em>, returning that variable's value. - !ruby/struct:SM::Flow::VERB body: " class Dummy\n attr_reader :var\n def initialize\n @var = 99\n end\n def remove\n remove_instance_variable(:@var)\n end\n end\n d = Dummy.new\n d.var #=> 99\n d.remove #=> 99\n d.var #=> nil\n" full_name: Object#remove_instance_variable is_singleton: false name: remove_instance_variable params: | obj.remove_instance_variable(symbol) => obj visibility: public