Main Page | Modules | Alphabetical List | Data Structures | File List | Data Fields | Globals

Bignum
[Numeric]


Defines

#define rb_big2int(x)   rb_big2long(x)
#define rb_big2uint(x)   rb_big2ulong(x)

Functions

VALUE rb_big_clone (VALUE)
void rb_big_2comp (VALUE)
VALUE rb_big_norm (VALUE)
VALUE rb_uint2big (unsigned long)
VALUE rb_int2big (long)
VALUE rb_uint2inum (unsigned long)
VALUE rb_int2inum (long)
VALUE rb_cstr_to_inum (const char *, int, int)
VALUE rb_str_to_inum (VALUE, int, int)
VALUE rb_cstr2inum (const char *, int)
VALUE rb_str2inum (VALUE, int)
VALUE rb_big2str (VALUE, int)
long rb_big2long (VALUE)
unsigned long rb_big2ulong (VALUE)
void rb_quad_pack (char *, VALUE)
VALUE rb_quad_unpack (const char *, int)
VALUE rb_dbl2big (double)
double rb_big2dbl (VALUE)
VALUE rb_big_plus (VALUE, VALUE)
VALUE rb_big_minus (VALUE, VALUE)
VALUE rb_big_mul (VALUE, VALUE)
VALUE rb_big_divmod (VALUE, VALUE)
VALUE rb_big_pow (VALUE, VALUE)
VALUE rb_big_and (VALUE, VALUE)
VALUE rb_big_or (VALUE, VALUE)
VALUE rb_big_xor (VALUE, VALUE)
VALUE rb_big_lshift (VALUE, VALUE)
VALUE rb_big_rand (VALUE, double *)


Define Documentation

#define rb_big2int  )     rb_big2long(x)
 

Definition at line 65 of file intern.h.

#define rb_big2uint  )     rb_big2ulong(x)
 

Definition at line 67 of file intern.h.


Function Documentation

double rb_big2dbl VALUE   ) 
 

Definition at line 877 of file bignum.c.

References BDIGIT, BDIGITS, BIGRAD, isinf(), rb_warn(), RBIGNUM, and VALUE.

Referenced by flo_cmp(), flo_div(), flo_divmod(), flo_eq(), flo_ge(), flo_gt(), flo_le(), flo_lt(), flo_minus(), flo_mod(), flo_mul(), flo_plus(), flo_pow(), rb_big_cmp(), rb_big_div(), rb_big_eq(), rb_big_minus(), rb_big_mul(), rb_big_plus(), rb_big_pow(), rb_big_quo(), rb_big_to_f(), and rb_Float().

long rb_big2long VALUE   ) 
 

Definition at line 776 of file bignum.c.

References big2ulong(), LONG_MIN, rb_eRangeError, rb_raise(), RBIGNUM, and VALUE.

Referenced by rb_num2long().

VALUE rb_big2str VALUE  ,
int 
 

Definition at line 617 of file bignum.c.

References BDIGIT, BDIGIT_DBL, BDIGITS, BIGUP, BIGZEROP, CHAR_BIT, FIXNUM_P, memmove(), rb_big_clone(), rb_eArgError, rb_fix2str(), rb_raise(), rb_str_new(), rb_str_new2(), RBIGNUM, RSTRING, ruby_digitmap, SIZEOF_BDIGITS, and VALUE.

Referenced by fix_to_s(), rb_big_to_s(), and rb_f_sprintf().

unsigned long rb_big2ulong VALUE   ) 
 

Definition at line 761 of file bignum.c.

References big2ulong(), rb_eRangeError, rb_raise(), RBIGNUM, and VALUE.

Referenced by rb_num2ulong().

void rb_big_2comp VALUE   ) 
 

Definition at line 92 of file bignum.c.

References get2comp(), and VALUE.

Referenced by rb_f_sprintf().

VALUE rb_big_and VALUE  ,
VALUE 
 

Definition at line 1637 of file bignum.c.

References BDIGIT, BDIGITS, bignew, bignorm(), FIX2LONG, FIXNUM_P, get2comp(), rb_big_clone(), rb_int2big(), rb_to_int(), RBIGNUM, and VALUE.

Referenced by fix_and(), and Init_Bignum().

VALUE rb_big_clone VALUE   ) 
 

Definition at line 59 of file bignum.c.

References BDIGIT, BDIGITS, bignew_1(), CLASS_OF, MEMCPY, RBIGNUM, and VALUE.

Referenced by bigdivrem(), limited_big_rand(), rb_big2str(), rb_big_abs(), rb_big_and(), rb_big_aref(), rb_big_neg(), rb_big_or(), rb_big_rshift(), rb_big_uminus(), rb_big_xor(), rb_f_rand(), and rb_f_sprintf().

VALUE rb_big_divmod VALUE  ,
VALUE 
 

Definition at line 1514 of file bignum.c.

References bigdivmod(), bignorm(), FIX2LONG, rb_assoc_new(), rb_int2big(), rb_num_coerce_bin(), T_BIGNUM, T_FIXNUM, TYPE, and VALUE.

Referenced by Init_Bignum(), and pack_pack().

VALUE rb_big_lshift VALUE  ,
VALUE 
 

Definition at line 1812 of file bignum.c.

References BDIGIT, BDIGIT_DBL, BDIGITS, BIGDN, BIGLO, bignew, bignorm(), BITSPERDIG, INT2FIX, NUM2INT, rb_big_rshift(), RBIGNUM, and VALUE.

Referenced by fix_lshift(), Init_Bignum(), and rb_big_rshift().

VALUE rb_big_minus VALUE  ,
VALUE 
 

Definition at line 1191 of file bignum.c.

References bigadd(), bignorm(), FIX2LONG, rb_big2dbl(), rb_float_new(), rb_int2big(), rb_num_coerce_bin(), RFLOAT, T_BIGNUM, T_FIXNUM, T_FLOAT, TYPE, and VALUE.

Referenced by fix_minus(), Init_Bignum(), and rb_f_rand().

VALUE rb_big_mul VALUE  ,
VALUE 
 

Definition at line 1217 of file bignum.c.

References BDIGIT, BDIGIT_DBL, BDIGITS, BIGDN, BIGLO, bignew, bignorm(), FIX2LONG, FIXNUM_P, rb_big2dbl(), rb_float_new(), rb_int2big(), rb_num_coerce_bin(), RBIGNUM, RFLOAT, T_BIGNUM, T_FIXNUM, T_FLOAT, TYPE, and VALUE.

Referenced by fix_mul(), Init_Bignum(), pack_unpack(), and rb_big_pow().

VALUE rb_big_norm VALUE   ) 
 

Definition at line 126 of file bignum.c.

References bignorm(), and VALUE.

Referenced by fix_aref(), limited_big_rand(), r_object0(), and random_seed().

VALUE rb_big_or VALUE  ,
VALUE 
 

Definition at line 1693 of file bignum.c.

References BDIGIT, BDIGITS, bignew, bignorm(), BIGRAD, FIX2LONG, FIXNUM_P, get2comp(), rb_big_clone(), rb_int2big(), rb_to_int(), RBIGNUM, and VALUE.

Referenced by fix_or(), and Init_Bignum().

VALUE rb_big_plus VALUE  ,
VALUE 
 

Definition at line 1165 of file bignum.c.

References bigadd(), bignorm(), FIX2LONG, rb_big2dbl(), rb_float_new(), rb_int2big(), rb_num_coerce_bin(), RFLOAT, T_BIGNUM, T_FIXNUM, T_FLOAT, TYPE, and VALUE.

Referenced by fix_plus(), Init_Bignum(), and pack_unpack().

VALUE rb_big_pow VALUE  ,
VALUE 
 

Definition at line 1587 of file bignum.c.

References bignorm(), FIX2LONG, INT2FIX, rb_big2dbl(), rb_big_mul(), rb_float_new(), rb_num_coerce_bin(), rb_warn(), RFLOAT, T_BIGNUM, T_FIXNUM, T_FLOAT, TYPE, and VALUE.

Referenced by fix_pow(), and Init_Bignum().

VALUE rb_big_rand VALUE  ,
double * 
 

Definition at line 2005 of file bignum.c.

References BDIGIT, BDIGITS, bignew, BIGZEROP, rb_float_new(), RBIGNUM, and VALUE.

VALUE rb_big_xor VALUE  ,
VALUE 
 

Definition at line 1750 of file bignum.c.

References BDIGIT, BDIGITS, bignew, bignorm(), FIX2LONG, FIXNUM_P, get2comp(), rb_big_clone(), rb_int2big(), rb_to_int(), RBIGNUM, and VALUE.

Referenced by fix_xor(), and Init_Bignum().

VALUE rb_cstr2inum const char *  ,
int 
 

VALUE rb_cstr_to_inum const char *  ,
int  ,
int 
 

Referenced by rb_cstr2inum(), and rb_str_to_inum().

VALUE rb_dbl2big double   ) 
 

Definition at line 870 of file bignum.c.

References bignorm(), and dbl2big().

Referenced by flo_ceil(), flo_floor(), flo_round(), flo_truncate(), rb_f_rand(), rb_f_sprintf(), and rb_Integer().

VALUE rb_int2big long   ) 
 

Definition at line 155 of file bignum.c.

References rb_uint2big(), RBIGNUM, and VALUE.

Referenced by bigdivmod(), bigdivrem(), fix_lshift(), fix_minus(), fix_mul(), fix_plus(), fix_pow(), fix_to_s(), rb_big_and(), rb_big_cmp(), rb_big_coerce(), rb_big_div(), rb_big_divmod(), rb_big_eq(), rb_big_minus(), rb_big_modulo(), rb_big_mul(), rb_big_or(), rb_big_plus(), rb_big_remainder(), rb_big_xor(), rb_f_sprintf(), rb_int2inum(), and w_object().

VALUE rb_int2inum long   ) 
 

Definition at line 181 of file bignum.c.

void rb_quad_pack char *  ,
VALUE 
 

Definition at line 191 of file bignum.c.

References BDIGIT, BDIGITS, BIGUP, FIX2LONG, FIXNUM_P, rb_eRangeError, rb_raise(), rb_to_int(), RBIGNUM, SIZEOF_BDIGITS, SIZEOF_LONG_LONG, and VALUE.

Referenced by pack_pack().

VALUE rb_quad_unpack const char *  ,
int 
 

Referenced by pack_unpack().

VALUE rb_str2inum VALUE  ,
int 
 

Definition at line 608 of file bignum.c.

References rb_str_to_inum(), and VALUE.

VALUE rb_str_to_inum VALUE  ,
int  ,
int 
 

Definition at line 511 of file bignum.c.

References ALLOCA_N, MEMCPY, rb_cstr_to_inum(), RSTRING, StringValue, StringValueCStr, and VALUE.

Referenced by obj2long(), rb_f_sprintf(), rb_Integer(), rb_str2inum(), rb_str_hex(), rb_str_oct(), and rb_str_to_i().

VALUE rb_uint2big unsigned  long  ) 
 

Definition at line 133 of file bignum.c.

References BDIGIT, BDIGIT_DBL, BDIGITS, BIGDN, BIGLO, bignew, DIGSPERLONG, RBIGNUM, and VALUE.

Referenced by bigdivrem(), pack_pack(), pack_unpack(), rb_cstr_to_inum(), rb_int2big(), and rb_uint2inum().

VALUE rb_uint2inum unsigned  long  ) 
 

Definition at line 173 of file bignum.c.


Generated on Wed Jan 18 23:32:12 2006 for Ruby by doxygen 1.3.5