From 3a28abfc3d3ff4b05d3c8c009209e4b7f005eed9 Mon Sep 17 00:00:00 2001 From: nobu Date: Fri, 1 Feb 2002 10:23:22 +0000 Subject: * intern.h: prototypes for new functions; rb_cstr_to_inum(), rb_str_to_inum(), rb_cstr_to_dbl(), rb_str_to_dbl() * bignum.c (rb_cstr_to_inum): changed from rb_cstr2inum(), and added argument badcheck to be consistent with parser. [new] * bignum.c (rb_str_to_inum): ditto. * bignum.c (rb_cstr2inum): wapper of rb_cstr_to_inum() now. * bignum.c (rb_str2inum): ditto. * object.c (rb_cstr_to_dbl): float number parser. [new] * object.c (rb_str_to_dbl): ditto. * object.c (rb_Float): use rb_cstr_to_dbl() for strict check. * object.c (rb_Integer): use rb_str_to_inum() for strict check. * string.c (rb_str_to_f): use rb_str_to_dbl() with less check. * string.c (rb_str_to_i): use rb_str_to_inum() with less check. * string.c (rb_str_hex): ditto. * string.c (rb_str_oct): ditto. * sprintf.c (rb_f_sprintf): ditto. * time.c (obj2long): ditto. * parse.y (yylex): use rb_cstr_to_inum() for strict check. git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@2041 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- intern.h | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'intern.h') diff --git a/intern.h b/intern.h index f3c6b6235..d41086dfd 100644 --- a/intern.h +++ b/intern.h @@ -61,6 +61,8 @@ 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)); @@ -263,6 +265,8 @@ VALUE rb_Integer _((VALUE)); VALUE rb_Float _((VALUE)); VALUE rb_String _((VALUE)); VALUE rb_Array _((VALUE)); +double rb_cstr_to_dbl _((const char *, int)); +double rb_str_to_dbl _((VALUE, int)); /* parse.y */ EXTERN int ruby_sourceline; EXTERN char *ruby_sourcefile; -- cgit