mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2025-01-31 20:51:52 +01:00
Check that there are not more attributes than
function parameters. llvm-svn: 44452
This commit is contained in:
parent
47b368da69
commit
8d9be63cd3
@ -396,6 +396,10 @@ void Verifier::visitFunction(Function &F) {
|
||||
bool SawSRet = false;
|
||||
|
||||
if (const ParamAttrsList *Attrs = F.getParamAttrs()) {
|
||||
Assert1(Attrs->size() &&
|
||||
Attrs->getParamIndex(Attrs->size()-1) <= FT->getNumParams(),
|
||||
"Function has excess attributes!", &F);
|
||||
|
||||
bool SawNest = false;
|
||||
|
||||
for (unsigned Idx = 0; Idx <= FT->getNumParams(); ++Idx) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user