Returns true if mod is an ancestor of other, or the two
modules are the same. Returns nil if there’s no relationship between the
two. (Think of the relationship in terms of the class definition:
“class A<B” implies “B>A”).
/*
* call-seq:
* mod >= other => true, false, or nil
*
* Returns true if <i>mod</i>isanancestorof<i>other</i>, or the
* two modules are the same. Returns
* <code>nil</code>ifthere's no relationship between the two.
* (Think of the relationship in terms of the class definition:
* "class A<B" implies "B>A").
*
*/
static VALUE
rb_mod_ge(mod, arg)
VALUE mod, arg;
{
switch (TYPE(arg)) {
case T_MODULE:
case T_CLASS:
break;
default:
rb_raise(rb_eTypeError, "compared with non class/module");
}
return rb_class_inherited_p(arg, mod);
}