forked from OSchip/llvm-project
Avoid error when convering a pointer to integer in
rewriting. llvm-svn: 92925
This commit is contained in:
parent
0f3aecf272
commit
9ab6349f2a
|
@ -3624,7 +3624,7 @@ void RewriteObjC::SynthesizeMetaDataIntoBuffer(std::string &Result) {
|
||||||
int CatDefCount = CategoryImplementation.size();
|
int CatDefCount = CategoryImplementation.size();
|
||||||
|
|
||||||
// This is needed for determining instance variable offsets.
|
// This is needed for determining instance variable offsets.
|
||||||
Result += "\n#define __OFFSETOFIVAR__(TYPE, MEMBER) ((int) &((TYPE *)0)->MEMBER)\n";
|
Result += "\n#define __OFFSETOFIVAR__(TYPE, MEMBER) ((long) &((TYPE *)0)->MEMBER)\n";
|
||||||
// For each implemented class, write out all its meta data.
|
// For each implemented class, write out all its meta data.
|
||||||
for (int i = 0; i < ClsDefCount; i++)
|
for (int i = 0; i < ClsDefCount; i++)
|
||||||
RewriteObjCClassMetaData(ClassImplementation[i], Result);
|
RewriteObjCClassMetaData(ClassImplementation[i], Result);
|
||||||
|
|
Loading…
Reference in New Issue