From 5e9b9ff9cb1f7897eb08c1d4f22ae0e206340f49 Mon Sep 17 00:00:00 2001 From: mame Date: Thu, 5 Jun 2008 14:41:41 +0000 Subject: * gc.c (rb_objspace_alloc): this function is needed only when ENABLE_VM_OBJSPACE macro is defined. * vm.c: ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@16848 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- ChangeLog | 7 +++++++ gc.c | 2 ++ vm.c | 2 ++ 3 files changed, 11 insertions(+) diff --git a/ChangeLog b/ChangeLog index 8efc5a307d..112699e24b 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,10 @@ +Thu Jun 5 23:40:08 2008 Yusuke Endoh + + * gc.c (rb_objspace_alloc): this function is needed only when + ENABLE_VM_OBJSPACE macro is defined. + + * vm.c: ditto. + Thu Jun 5 23:31:21 2008 Yusuke Endoh * test/stringio/test_stringio.rb: add tests to achieve over 95% test diff --git a/gc.c b/gc.c index 245b8ee2d9..0bd140ae4e 100644 --- a/gc.c +++ b/gc.c @@ -201,6 +201,7 @@ static rb_objspace_t rb_objspace = {{GC_MALLOC_LIMIT}, {HEAP_MIN_SLOTS}}; #define mark_stack_overflow objspace->markstack.overflow #define global_List objspace->global_list +#if defined(ENABLE_VM_OBJSPACE) && ENABLE_VM_OBJSPACE rb_objspace_t * rb_objspace_alloc(void) { @@ -210,6 +211,7 @@ rb_objspace_alloc(void) return objspace; } +#endif /* tiny heap size */ /* 32KB */ diff --git a/vm.c b/vm.c index 7c859110f1..0194ea6750 100644 --- a/vm.c +++ b/vm.c @@ -1728,7 +1728,9 @@ Init_VM(void) vm_init_redefined_flag(); } +#if defined(ENABLE_VM_OBJSPACE) && ENABLE_VM_OBJSPACE struct rb_objspace *rb_objspace_alloc(void); +#endif void Init_BareVM(void) -- cgit v1.2.3