summary |
shortlog |
log |
commit | commitdiff |
tree
raw |
patch |
inline | side by side (from parent 1:
b3dd3c7)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@229364
91177308-0d34-0410-b5e6-
96231b3b80d8
- if (Ty->isFunctionTy() || Ty->isLabelTy())
+ if (Ty->isFunctionTy() || !PointerType::isValidElementType(Ty))
return Error(TyLoc, "invalid type for global variable");
GlobalValue *GVal = nullptr;
return Error(TyLoc, "invalid type for global variable");
GlobalValue *GVal = nullptr;
--- /dev/null
+; RUN: not llvm-as < %s 2>&1 | FileCheck %s
+
+@gv = global metadata undef
+; CHECK: invalid type for global variable