Commit Graph

22 Commits

Author SHA1 Message Date
Yukihiro Matsumoto 0e5958d404 rename ruby_digitmap to mrb_digitmap 2012-05-30 21:19:04 +09:00
Masaki Muranaka 34dddc58e1 Use default case in switch statement. 2012-05-29 16:15:43 +09:00
Yukihiro Matsumoto ad9e841c53 made mrb_get_args() better (optinal args, type checks); close #173 #176 2012-05-24 01:09:36 +09:00
Yukihiro Matsumoto 4523bee953 cast style consistency 2012-05-23 03:31:55 +09:00
Mitchell Blank Jr 9e336b00e5 More C++ compilability work: mrb_obj_alloc void* conversions
One of the biggest set of changes needed to make C++ compile, is that you
can't autoconvert "void*" to a different pointer type without a cast (you
can of course, convert pointers *to* "void*"!)

For the first part, convert the users of "mrb_obj_alloc".  Since it has
to return something, make it RBasic* (that's what mrb_obj_alloc() is
operating on anyway).  This way, even in C you'll get a warning if you
don't cast it.

For places where there are a lot of similar calls to mrb_obj_alloc(),
this can be easily hidden through a macro.  I did this in string.c:
    #define mrb_obj_alloc_string(mrb) ((struct RString *) mrb_obj_alloc((mrb), MRB_TT_STRING, (mrb)->string_class))

I also updated the mrb_object() macro to also return a RBasic* -- my
previous commit changed that from "void*" -> "RObject*", but I figure
it should be consistent with mrb_obj_alloc()
2012-05-20 09:43:14 -07:00
Yukihiro Matsumoto b68e69aa32 remove unused assignments 2012-05-17 12:57:08 +09:00
Masaki Muranaka c6f0e296bd Remove some redundant function declarations. 2012-05-16 14:31:48 +09:00
Yukihiro Matsumoto f4cf8ea423 partial VC support 2012-05-09 08:49:38 +09:00
Yukihiro Matsumoto 8b1a10ce4b allow compilation without INCLUDE_ENCODING; close #105; encoding support should be removed altogether in the future 2012-05-08 01:23:31 +09:00
Yukihiro Matsumoto d0e63a3a03 RMatch.src should not be mrb_value 2012-05-07 17:31:07 +09:00
roco 4ec6d41f16 rm whitespace 2012-04-30 14:29:19 -07:00
Yukihiro "Matz" Matsumoto 2b6be16308 Merge pull request #61 from pbhogan/fix-warnings
Fix various warnings
2012-04-27 08:56:39 -07:00
Yukihiro Matsumoto fdd4920ffd accessing out of region; fix #68 2012-04-28 00:45:33 +09:00
Yukihiro Matsumoto 32db0e5d8c struct RString member should not be mrb_value 2012-04-28 00:32:34 +09:00
Patrick Hogan 27cfbbe43a size_t is unsigned and can never be < 0
Removed to silence warning.

Signed-off-by: Patrick Hogan <pbhogan@gmail.com>
2012-04-26 08:36:32 -05:00
Yukihiro Matsumoto 2fc1b8af2d mv variable.h to mruby/variable.h 2012-04-24 15:59:50 +09:00
Yukihiro Matsumoto d4ef3baca8 remove code for unsupported taint-mode 2012-04-23 18:30:49 +09:00
mimaki c80487561f Merge branch 'master' of github.com:mruby/mruby
Conflicts:
	src/variable.c
2012-04-23 11:51:47 +09:00
mimaki 835443614d add file header 2012-04-23 11:46:16 +09:00
Yukihiro Matsumoto 41bf311cd1 remove dependency to SIZEOF_INT 2012-04-20 22:31:58 +09:00
Yukihiro Matsumoto 5622c977f4 remove dependency to SIZEOF_VOIDP 2012-04-20 22:25:04 +09:00
mimaki e0d6430f63 add mruby sources 2012-04-20 09:39:03 +09:00