Changeset 106 for trunk/thune/make.c
- Timestamp:
- 03/31/06 22:47:57 (3 years ago)
- Files:
-
- 1 modified
-
trunk/thune/make.c (modified) (12 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/thune/make.c
r100 r106 55 55 56 56 #ifdef GC_STRESS_TEST 57 if( ur_env-> blocks.sweepStart && (ur_env->flags & UR_ENV_GC))57 if( ur_env->flags & UR_ENV_GC ) 58 58 ur_recycle(); 59 59 #endif … … 94 94 95 95 #ifdef GC_STRESS_TEST 96 if( ur_env-> bin.sweepStart && (ur_env->flags & UR_ENV_GC))96 if( ur_env->flags & UR_ENV_GC ) 97 97 ur_recycle(); 98 98 #endif … … 426 426 427 427 428 void ur_makeContext( UContext* ctx,UCell* proto )428 static void ur_makeContext( UContext* ctx, const UCell* proto ) 429 429 { 430 430 if( proto && ur_is(proto, UT_BLOCK) ) … … 435 435 UCell* start; 436 436 UCell* end; 437 UIndex hold; 437 438 438 439 blk = ur_blockPtr( proto->series.n ); … … 451 452 ctx->ctx.wordBlk = ur_makeBlock( size ); 452 453 453 ur_refPush( UT_BLOCK, ctx->ctx.wordBlk );454 hold = ur_hold( UT_BLOCK, ctx->ctx.wordBlk ); 454 455 ctx->ctx.protoValBlk = ur_makeBlock( size ); 455 456 ctx->ctx.valBlk = ctx->ctx.protoValBlk; 456 ur_re fPop( 1);457 ur_release( hold ); 457 458 458 459 … … 554 555 int argc = 1; 555 556 556 UR_S_DROP; 557 res = UR_TOS; 557 res = ur_s_prev(tos); 558 558 559 559 if( ur_is(res, UT_DATATYPE) ) … … 562 562 { 563 563 ur_copy(res, *tos); // UR_S_NIP; 564 UR_S_DROP; 564 565 return; 565 566 } … … 574 575 575 576 argc = 2; 576 UR_S_DROP;577 577 } 578 578 … … 611 611 str->ptr.c + str->used ); 612 612 } 613 if( ! blkN )613 else 614 614 { 615 615 blkN = ur_makeBlock(0); 616 616 } 617 617 618 ur_setType(res, UT_BLOCK); 619 ur_setSeries(res, blkN, 0); 618 if( blkN ) 619 { 620 ur_setType(res, UT_BLOCK); 621 ur_setSeries(res, blkN, 0); 622 } 620 623 } 621 624 break; … … 689 692 ur_bind( tos->series.n, res ); 690 693 691 UR_S_GROW;692 693 694 //ur_callControl( UR_CALL_DO ); 695 //return UC_DO; 694 696 UR_CALL_OP = OP_DO; 695 //return UC_DO;697 return; 696 698 } 697 699 //else if( ur_is(res, UT_CONTEXT) ) … … 701 703 702 704 case UT_BITSET: 705 { 706 // Make bitset before setting res in case GC is called. 707 UIndex binN = ur_makeBitset(tos); 703 708 ur_setType(res, UT_BITSET); 704 ur_setSeries(res, ur_makeBitset(tos), 0); 709 ur_setSeries(res, binN, 0); 710 } 705 711 break; 706 712 … … 708 714 goto error; 709 715 } 716 717 UR_S_DROPN( argc ); 710 718 return; 711 719 //return UC_CONT;
