Exemplo n.º 1
0
// Assign (const char *)
//------------------------------------------------------------------------------
void AString::Assign( const char * string )
{
	Assign( string, string + StrLen( string ) );
}
Exemplo n.º 2
0
TCopyParamType & TCopyParamType::operator =(const TCopyParamType & rhp)
{
  Assign(&rhp);
  return *this;
}
Exemplo n.º 3
0
	/** assignment operator from another smart ptr */
	inline CCountedPtr& operator=(const CCountedPtr &src)
	{
		Assign(src.m_pT);
		return *this;
	}
Exemplo n.º 4
0
 /** \brief Assignment operator.
   
     Implemented in Terms of Assign(const ParserByteCode &a_ByteCode)
 */
 ParserByteCode& ParserByteCode::operator=(const ParserByteCode &a_ByteCode)
 {
   Assign(a_ByteCode);
   return *this;
 }
Exemplo n.º 5
0
FluxCalibrationInstance::FluxCalibrationInstance( const FluxCalibrationInstance& x ) :
ProcessImplementation( x )
{
   Assign( x );
}
Exemplo n.º 6
0
//============================================================
// <T>构造字符串缓冲。</T>
//
// @param pValue 字符串
// @param length 长度
//============================================================
TStringBuffer8::TStringBuffer8(TChar8C* pValue, TInt length){
   Assign(pValue, length);
}
Exemplo n.º 7
0
//============================================================
// <T>构造字符串缓冲。</T>
//
// @param value 字符串
//============================================================
TStringBuffer8::TStringBuffer8(const MString8& value){
   Assign(value.MemoryC(), value.Length());
}
Exemplo n.º 8
0
BinarizeInstance::BinarizeInstance( const BinarizeInstance& x ) :
ProcessImplementation( x )
{
   Assign( x );
}
Exemplo n.º 9
0
short ResolveReferences(void)
{
   Stack Ref;
   Instruction I,j;
   int Labelref;

   Ref = AllocateStack (200);

   for (I = 1; I <= SizeOf (Labels); I++) 
   {
      if (LabelOf(I) != UndefinedString)
         if (Element(Ref,LabelOf(I)) == UndefinedString)
            Assign(Ref,LabelOf(I),I);
         else 
         {
            fprintf(output,"<<< MACHINE ERROR >>>: ");
            fprintf(output,"DUPLICATE INSTRUCTION WITH LABEL ");
    	    fprintf(output," %d **",LabelOf(I));
    	    WriteString(output,LabelOf(I));
            fprintf(output,"**: LINE %1d \n",I);
            return(false);
         }
   }

   for (I = 1; I <= SizeOf(Labels); I++) 
   {
      if (OpCodeOf(I) == GOTOOP || OpCodeOf(I) == CONDOP ||
                                   OpCodeOf(I) == CODEOP) 
      {
         Labelref = Element(Ref,Operand1Of(I));
         if (Labelref == 0) 
         {
            fprintf(output,"<<< MACHINE ERROR >>>: ");
            fprintf(output,"NO INSTRUCTION WITH LABEL ");
    	    fprintf(TraceFile," %d ",Operand1Of(I));
            fprintf(output,"': LINE %1d \n",I);
            return(false);
         }
         
         Assign ( Ref, Operand1Of(I), 1000000+Labelref );
         Assign ( Operand1, I, Labelref % 1000000);
      }

      if (OpCodeOf(I) == CONDOP) 
      {
         Labelref = Element(Ref,Operand2Of(I));
         if (Labelref == 0) 
         {
            fprintf(output,"<<< MACHINE ERROR >>>: ");
            fprintf(output,"NO INSTRUCTION WITH LABEL ");
    	    fprintf(output," %d ",Operand2Of(I));
            fprintf(output,"': LINE %1d \n",I);
            return(false);
         }
         Assign (Ref, Operand2Of(I), 1000000+Labelref );
         Assign (Operand2, I, Labelref % 1000000);
      }

      if (OpCodeOf(I) == LITOP || OpCodeOf(I) ==  LLVOP
            || OpCodeOf(I) ==  LGVOP  || OpCodeOf(I) == SLVOP
            || OpCodeOf(I) ==  SGVOP  || OpCodeOf(I) == LLIVOP
            || OpCodeOf(I) ==  LGIVOP || OpCodeOf(I) == SLIVOP
            || OpCodeOf(I) ==  SGIVOP || OpCodeOf(I) == LLAOP
            || OpCodeOf(I) ==  LGAOP  || OpCodeOf(I) == LUVOP
            || OpCodeOf(I) ==  SUVOP  || OpCodeOf(I) == POPOP
            || OpCodeOf(I) ==  CALLOP || OpCodeOf(I) == RTNOP)
          Assign (Operand1,I,StringToInteger(Operand1Of(I)));

       if (OpCodeOf(I) == LUVOP || OpCodeOf(I) == SUVOP )
          Assign(Operand2,I,StringToInteger(Operand2Of(I)));
   }

   for (I =1; I <= TextSize(); I++ ) 
   {
      if (Element(Ref,I) != 0)
         if (Element(Ref,I) < 1000000) 
         {
            fprintf(output,"<<< MACHINE ERROR >>>: ");
            fprintf(output,"NO REFERENCE TO INSTRUCTION WITH LABEL ");
	    fprintf(output,"%d ", I);
            fprintf(output,": LINE %1d \n",I);
            fprintf(output,"Element(Ref)= %d\n",Element(Ref,I));
            PrintAllStrings(stdout);
            return(false);
	 }
   }

   return(true);
}
Exemplo n.º 10
0
	const CDuiString& CDuiString::operator=(const CDuiString& src)
	{      
		Assign(src);
		return *this;
	}
Exemplo n.º 11
0
CFI& CFI::Assign(const string &str)
{
    CFI tmp(str);
    return Assign(std::move(tmp));
}
Exemplo n.º 12
0
	CDuiString::CDuiString(const CDuiString& src) : m_pstr(m_szBuffer)
	{
		m_szBuffer[0] = '\0';
		Assign(src.m_pstr);
	}
Exemplo n.º 13
0
	CDuiString::CDuiString(LPCTSTR lpsz, int nLen) : m_pstr(m_szBuffer)
	{      
		ASSERT(!::IsBadStringPtr(lpsz,-1) || lpsz==NULL);
		m_szBuffer[0] = '\0';
		Assign(lpsz, nLen);
	}
Exemplo n.º 14
0
 /*!
  * Reconstruct the buffer to be a copy of another buffer.
  *
  *  @param[in] other    The contents of this buffer are copied.
  *
  * @return  Reference to the new data buffer.
  */
 DATA &operator =(const DATA &other)
 {
     Assign(other);
     return *this;
 }
Exemplo n.º 15
0
DataBuffer::DataBuffer( char const *bytes, u32 len )
{
  Assign( bytes, len );
}
int main()
{
  StartClock();
  unsigned int *no_init_ptr;
  unsigned int *ptr;
  struct UnsignedInt_Type1 ptr_str;
  ((ptr_str.Void_Type0::ptr = ptr , ptr_str.addr = (reinterpret_cast < unsigned long long  >  ((&ptr)))) , ((Assign(&ptr_str,UnsignedInt_Type1_Cast_Void_Type0(malloc_overload(400UL))) , ptr = ptr_str.Void_Type0::ptr)));
  unsigned int *ptr2;
  struct UnsignedInt_Type1 ptr2_str;
  ((ptr2_str.Void_Type0::ptr = ptr2 , ptr2_str.addr = (reinterpret_cast < unsigned long long  >  ((&ptr2)))) , ((Assign(&ptr2_str,UnsignedInt_Type1_Cast_Void_Type0(malloc_overload(40UL))) , ptr2 = ptr2_str.Void_Type0::ptr)));
  unsigned int *ptr_index;
  unsigned int counter = 0U;
  struct UnsignedInt_Type1 UnsignedInt_Type1_ovl_2;
  struct UnsignedInt_Type1 UnsignedInt_Type1_ovl_3;
  for ((((UnsignedInt_Type1_ovl_2 = create_struct(ptr_index,(reinterpret_cast < unsigned long long  >  ((&ptr_index)))) , UnsignedInt_Type1_Assign_UnsignedInt_Type1_UnsignedInt_Type1((reinterpret_cast < unsigned long long  >  ((&UnsignedInt_Type1_ovl_2))),ptr_str)) , ((unsigned int *)( *(reinterpret_cast < void ** >  (UnsignedInt_Type1_ovl_2.addr)))) = UnsignedInt_Type1_ovl_2.Void_Type0::ptr) , UnsignedInt_Type1_ovl_2); b_LessThan_UnsignedInt_Type1_UnsignedInt_Type1(create_struct(ptr_index,(reinterpret_cast < unsigned long long  >  ((&ptr_index)))),UnsignedInt_Type1_Add_UnsignedInt_Type1_i(ptr_str,100)); (((UnsignedInt_Type1_ovl_3 = create_struct(ptr_index,(reinterpret_cast < unsigned long long  >  ((&ptr_index)))) , UnsignedInt_Type1_Increment_UnsignedInt_Type1((reinterpret_cast < unsigned long long  >  ((&UnsignedInt_Type1_ovl_3))))) , ((unsigned int *)( *(reinterpret_cast < void ** >  (UnsignedInt_Type1_ovl_3.addr)))) = UnsignedInt_Type1_ovl_3.Void_Type0::ptr) , UnsignedInt_Type1_ovl_3)) {
     *Deref(create_struct(ptr_index,(reinterpret_cast < unsigned long long  >  ((&ptr_index))))) = counter++;
  }
  struct UnsignedInt_Type1 UnsignedInt_Type1_ovl_4;
  struct UnsignedInt_Type1 UnsignedInt_Type1_ovl_5;
  for ((((UnsignedInt_Type1_ovl_4 = create_struct(ptr_index,(reinterpret_cast < unsigned long long  >  ((&ptr_index)))) , UnsignedInt_Type1_Assign_UnsignedInt_Type1_UnsignedInt_Type1((reinterpret_cast < unsigned long long  >  ((&UnsignedInt_Type1_ovl_4))),UnsignedInt_Type1_Sub_UnsignedInt_Type1_i(UnsignedInt_Type1_Add_UnsignedInt_Type1_i(ptr_str,100),1))) , ((unsigned int *)( *(reinterpret_cast < void ** >  (UnsignedInt_Type1_ovl_4.addr)))) = UnsignedInt_Type1_ovl_4.Void_Type0::ptr) , UnsignedInt_Type1_ovl_4); b_GreaterOrEqual_UnsignedInt_Type1_UnsignedInt_Type1(create_struct(ptr_index,(reinterpret_cast < unsigned long long  >  ((&ptr_index)))),ptr_str); (((UnsignedInt_Type1_ovl_5 = create_struct(ptr_index,(reinterpret_cast < unsigned long long  >  ((&ptr_index)))) , UnsignedInt_Type1_Decrement_UnsignedInt_Type1((reinterpret_cast < unsigned long long  >  ((&UnsignedInt_Type1_ovl_5))))) , ((unsigned int *)( *(reinterpret_cast < void ** >  (UnsignedInt_Type1_ovl_5.addr)))) = UnsignedInt_Type1_ovl_5.Void_Type0::ptr) , UnsignedInt_Type1_ovl_5)) {
    printf("%u\n", *Deref(create_struct(ptr_index,(reinterpret_cast < unsigned long long  >  ((&ptr_index))))));
  }
  EndClock();
  return 1;
}
Exemplo n.º 17
0
clNode& clNode::operator=(const clNode &source)
{
  return(Assign(source));
}
Exemplo n.º 18
0
//---------------------------------------------------------------------------
// Construct the object
NaUnit::NaUnit (unsigned nInDim_, unsigned nOutDim_, unsigned nFbDepth_)
{
    pTimer = &TheTimer;
    Assign(nInDim_, nOutDim_, nFbDepth_);
}
Exemplo n.º 19
0
//============================================================
// <T>构造字符串缓冲。</T>
//
// @param ptr 字符串指针
//============================================================
TStringBuffer8::TStringBuffer8(const TString8PtrC& ptr){
   Assign(ptr.MemoryC(), ptr.Length());
}
Exemplo n.º 20
0
GxFont& GxFont::operator = (const GxFont& other)
{
	Assign(other);
	return *this;
}
Exemplo n.º 21
0
void CMidiSetupRow::SetInfo(const INFO& Info)
{
	m_RangeStart.SetVal(Info.Range.Start);
	m_RangeEnd.SetVal(Info.Range.End);
	Assign(Info.Event, Info.Chan, Info.Ctrl);
}
Exemplo n.º 22
0
 /** \brief Copy constructor. 
   
     Implemented in Terms of Assign(const ParserByteCode &a_ByteCode)
 */
 ParserByteCode::ParserByteCode(const ParserByteCode &a_ByteCode)
 {
   Assign(a_ByteCode);
 }
Exemplo n.º 23
0
CDVDStreamInfo::CDVDStreamInfo(const CDemuxStream &right, bool withextradata )       { extradata = NULL; Clear(); Assign(right, withextradata); }
Exemplo n.º 24
0
//-----------------------------------------------------------------------------------------------
Variable::Variable(const Variable &obj)
    :IValue(cmVAR)
{
    Assign(obj);
    AddFlags(IToken::flVOLATILE);
}
Exemplo n.º 25
0
TCopyParamType::TCopyParamType(const TCopyParamType & Source)
{
  Assign(&Source);
}
Exemplo n.º 26
0
//-----------------------------------------------------------------------------------------------
Variable& Variable::operator=(const Variable &obj)
{
    Assign(obj);
    return *this;
}
Exemplo n.º 27
0
	/** assignment operator from raw ptr */
	inline CCountedPtr& operator=(Tcls *pT)
	{
		Assign(pT);
		return *this;
	}
Exemplo n.º 28
0
void DataBuffer::operator <<( NetworkMessage const &netMsg )
{
  u32 typeSize = sizeof( MsgType );
  Assign( (char *) &netMsg.type_, typeSize );
  Append( netMsg.msg_.Bytes(), netMsg.msg_.Size() );
}
Exemplo n.º 29
0
// Constructor with assignment.
CUIHelper::CUIHelper(const IID &HelperIID, PVOID pHelper)
{
    // Assign the interface.
    Assign(HelperIID, pHelper);
}
Exemplo n.º 30
0
void
nsTSubstring_CharT::Assign( const substring_tuple_type& tuple )
  {
    if (!Assign(tuple, fallible_t()))
      NS_RUNTIMEABORT("OOM");
  }