From a4e5d3cf8ecba1d2fa03ec590424a4a5e535e5d1 Mon Sep 17 00:00:00 2001 From: Eric Christopher Date: Wed, 16 Sep 2015 23:38:13 +0000 Subject: constify the Function parameter to the TTI creation callback and propagate to all callers/users/etc. llvm-svn: 247864 --- llvm/lib/Target/TargetMachine.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'llvm/lib/Target/TargetMachine.cpp') diff --git a/llvm/lib/Target/TargetMachine.cpp b/llvm/lib/Target/TargetMachine.cpp index 83174c20c8e..6dc3b97fc98 100644 --- a/llvm/lib/Target/TargetMachine.cpp +++ b/llvm/lib/Target/TargetMachine.cpp @@ -150,7 +150,7 @@ void TargetMachine::setOptLevel(CodeGenOpt::Level Level) const { } TargetIRAnalysis TargetMachine::getTargetIRAnalysis() { - return TargetIRAnalysis([this](Function &F) { + return TargetIRAnalysis([this](const Function &F) { return TargetTransformInfo(F.getParent()->getDataLayout()); }); } -- cgit v1.2.3