mirror of
https://github.com/RPCS3/llvm.git
synced 2025-01-11 06:56:12 +00:00
[opaque pointer type] Use the value type of the GlobalVariable rather than accessing it through the pointee's type
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@237312 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
ea3c20f400
commit
7c001dac7a
@ -776,7 +776,7 @@ bool LLParser::ParseGlobal(const std::string &Name, LocTy NameLoc,
|
||||
Name, nullptr, GlobalVariable::NotThreadLocal,
|
||||
AddrSpace);
|
||||
} else {
|
||||
if (GVal->getType()->getElementType() != Ty)
|
||||
if (GVal->getValueType() != Ty)
|
||||
return Error(TyLoc,
|
||||
"forward reference and definition of global have different types");
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user