NUM2LONG

Function NUM2LONG 

Source
pub unsafe fn NUM2LONG(obj: VALUE) -> c_long
Expand description

Convert Ruby Integer to long (akin to NUM2LONG).

Converts any Ruby Integer (Fixnum or Bignum) to a C long. May raise a RangeError exception if the value is out of range.

ยงSafety

  • obj must be a valid Integer VALUE
  • May call into Ruby runtime and potentially raise exceptions
  • May trigger garbage collection