method

remove_class_variable

v1_8_7_72 - Show latest stable - Class: Module
remove_class_variable(p1)
public

Removes the definition of the sym, returning that constant’s value.

   class Dummy
     @@var = 99
     puts @@var
     remove_class_variable(:@@var)
     puts(defined? @@var)
   end

produces:

   99
   nil