anchor.diff:    Windows,
     {$ELSE}
     {$ENDIF}
  -  Classes, SysUtils, SyncObjs, utils_dvalue;
  +  Classes, SysUtils, SyncObjs, utils_dvalue, utils_BufferPool;
  +
  +const
  +  MAX_THREADID_VALUE = 65535;
  +
  +type
  +  TPointerNotifyProc = procedure(const sender:Pointer; const v:Pointer);
  +
  +  PThreadVarRecord = ^TThreadVarRecord;
  +  TThreadVarRecord = record
  +    FVar:Pointer;
  +    FReleaseCallBack:TPointerNotifyProc;
  +    FLastActivity:Cardinal;
  +  end;
  +
  +  PThreadVars = ^TThreadVars;
  +  TThreadVars = record
  +    FVarArray:array[1..MAX_THREADID_VALUE] of PThreadVarRecord;
  +    FListLocker:Integer;
  +    FList:TDHashTable;
  +  end;
  +
  +function NewThreadVars: PThreadVars;
  +procedure DisposeThreadVars(const p_thread_vars:PThreadVars);
  +function GetCurrentThreadVar(const p_thread_vars: PThreadVars): Pointer;
  +procedure SetCurrentThreadVar(const p_thread_vars: PThreadVars; const v:
  +    Pointer; pvReleaseCallBack: TPointerNotifyProc);
   
   
   function GetCurrentThreadDValue: TDValue;
  
positive.code:   end;
  end;
  
  
  initialization
    InitalizeForThreadVars;
  
negative.code: 
  procedure InitalizeForThreadVars;
  procedure FinalizeForThreadVars;
  
  
  implementation
  