comparison gen/structs.h @ 344:e20ce6d8d374 trunk

[svn r365] Implemented raw struct equality comparison, uses C memcmp. Renamed DtoDelegateCompare to DtoDelegateEquals, for consistency with the other equality helpers.
author lindquist
date Sun, 13 Jul 2008 04:11:08 +0200
parents a95056b3c996
children 74101be2a553
comparison
equal deleted inserted replaced
343:15eb8f5f2441 344:e20ce6d8d374
22 22
23 /** 23 /**
24 * Provides the llvm definition for a struct 24 * Provides the llvm definition for a struct
25 */ 25 */
26 void DtoDefineStruct(StructDeclaration* sd); 26 void DtoDefineStruct(StructDeclaration* sd);
27
28 /**
29 * Returns a boolean=true if the two structs are equal
30 */
31 LLValue* DtoStructEquals(TOK op, DValue* lhs, DValue* rhs);
27 32
28 typedef LLSmallVector<unsigned, 3> DStructIndexVector; 33 typedef LLSmallVector<unsigned, 3> DStructIndexVector;
29 LLValue* DtoIndexStruct(LLValue* ptr, StructDeclaration* sd, Type* t, unsigned os, DStructIndexVector& idxs); 34 LLValue* DtoIndexStruct(LLValue* ptr, StructDeclaration* sd, Type* t, unsigned os, DStructIndexVector& idxs);
30 35
31 struct DUnionField 36 struct DUnionField