Revision: 4534 http://trac.macosforge.org/projects/ruby/changeset/4534 Author: lsansonetti@apple.com Date: 2010-09-22 13:53:10 -0700 (Wed, 22 Sep 2010) Log Message: ----------- fix a regression with earlier LLVM versions Modified Paths: -------------- MacRuby/trunk/compiler.cpp MacRuby/trunk/kernel.c Modified: MacRuby/trunk/compiler.cpp =================================================================== --- MacRuby/trunk/compiler.cpp 2010-09-22 01:00:06 UTC (rev 4533) +++ MacRuby/trunk/compiler.cpp 2010-09-22 20:53:10 UTC (rev 4534) @@ -6181,7 +6181,10 @@ bool need_wb = false; Value *slot = compile_lvar_slot(vid, &need_wb); if (need_wb) { - Value *args[] = { slot, val }; + Value *args[] = { + new BitCastInst(slot, RubyObjPtrTy, "", bb), + new BitCastInst(val, RubyObjTy, "", bb) + }; return CallInst::Create(writeBarrierFunc, args, args + 2, "", bb); } else { Modified: MacRuby/trunk/kernel.c =================================================================== --- MacRuby/trunk/kernel.c 2010-09-22 01:00:06 UTC (rev 4533) +++ MacRuby/trunk/kernel.c 2010-09-22 20:53:10 UTC (rev 4534) @@ -25,10 +25,10 @@ #endif PRIMITIVE VALUE -vm_gc_wb(void *slot, void *val) +vm_gc_wb(VALUE *slot, VALUE val) { GC_WB(slot, val); - return (VALUE)val; + return val; } PRIMITIVE VALUE