The implementation converts the pointer/size pair anyway back to ArrayRef.
LinkDeclContextToDIE(function_decl, die);
if (!function_param_decls.empty()) {
- m_ast.SetFunctionParameters(function_decl,
- &function_param_decls.front(),
- function_param_decls.size());
+ m_ast.SetFunctionParameters(function_decl, function_param_decls);
if (template_function_decl)
m_ast.SetFunctionParameters(template_function_decl,
- &function_param_decls.front(),
- function_param_decls.size());
+ function_param_decls);
}
ClangASTMetadata metadata;
}
if (!params.empty())
- m_clang.SetFunctionParameters(&function_decl, params.data(), params.size());
+ m_clang.SetFunctionParameters(&function_decl, params);
}
clang::QualType PdbAstBuilder::CreateEnumType(PdbTypeSymId id,
}
}
if (params.size())
- m_ast.SetFunctionParameters(decl, params.data(), params.size());
+ m_ast.SetFunctionParameters(decl, params);
m_uid_to_decl[sym_id] = decl;
return decl;
}
-void TypeSystemClang::SetFunctionParameters(FunctionDecl *function_decl,
- ParmVarDecl **params,
- unsigned num_params) {
+void TypeSystemClang::SetFunctionParameters(
+ FunctionDecl *function_decl, llvm::ArrayRef<ParmVarDecl *> params) {
if (function_decl)
- function_decl->setParams(ArrayRef<ParmVarDecl *>(params, num_params));
+ function_decl->setParams(params);
}
CompilerType
int storage, bool add_decl = false);
void SetFunctionParameters(clang::FunctionDecl *function_decl,
- clang::ParmVarDecl **params, unsigned num_params);
+ llvm::ArrayRef<clang::ParmVarDecl *> params);
CompilerType CreateBlockPointerType(const CompilerType &function_type);