Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
home:user5664536:toolchain
llvm39
_service:download_files:0004-fix-lambda-paramet...
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File _service:download_files:0004-fix-lambda-parameter-name-redeclared.patch of Package llvm39
Description: Fix lambda parameter redeclaration bugs in clang source code /tmp/llvm-3.9.1.src/tools/clang/lib/CodeGen/CGOpenMPRuntime.cpp: In lambda function: /tmp/llvm-3.9.1.src/tools/clang/lib/CodeGen/CGOpenMPRuntime.cpp:6078:55: error: lambda parameter ‘CGF’ previously declared as a capture 6078 | &NumOfPtrs](CodeGenFunction &CGF, PrePostActionTy &) { | ~~~~~~~~~~~~~~~~~^~~ /tmp/llvm-3.9.1.src/tools/clang/lib/CodeGen/CGOpenMPRuntime.cpp: In lambda function: /tmp/llvm-3.9.1.src/tools/clang/lib/CodeGen/CGOpenMPRuntime.cpp:6126:53: error: lambda parameter ‘CGF’ previously declared as a capture 6126 | &NumOfPtrs](CodeGenFunction &CGF, PrePostActionTy &) { | ~~~~~~~~~~~~~~~~~^~~ /tmp/llvm-3.9.1.src/tools/clang/lib/CodeGen/CGOpenMPRuntime.cpp: In lambda function: /tmp/llvm-3.9.1.src/tools/clang/lib/CodeGen/CGOpenMPRuntime.cpp:6191:56: error: lambda parameter ‘CGF’ previously declared as a capture 6191 | auto &&ThenGen = [&D, &CGF, Device](CodeGenFunction &CGF, PrePostActionTy &) { | ~~~~~~~~~~~~~~~~~^~~ This bug cause compiler error when clang 9.0.0 is used, because lambda parameter of which the name is the same as the one of capture is no longer allowed. Author: Sun Ziping <sunziping2016@gmail.com> Last-Update: 2019-12-18 diff -ur a/tools/clang/lib/CodeGen/CGOpenMPRuntime.cpp b/tools/clang/lib/CodeGen/CGOpenMPRuntime.cpp --- a/tools/clang/lib/CodeGen/CGOpenMPRuntime.cpp 2016-06-24 12:05:48.000000000 +0800 +++ b/tools/clang/lib/CodeGen/CGOpenMPRuntime.cpp 2019-12-18 19:26:11.727652326 +0800 @@ -6073,7 +6073,7 @@ // Generate the code for the opening of the data environment. Capture all the // arguments of the runtime call by reference because they are used in the // closing of the region. - auto &&BeginThenGen = [&D, &CGF, &BasePointersArray, &PointersArray, + auto &&BeginThenGen = [&D, &BasePointersArray, &PointersArray, &SizesArray, &MapTypesArray, Device, &NumOfPtrs](CodeGenFunction &CGF, PrePostActionTy &) { // Fill up the arrays with all the mapped variables. @@ -6121,7 +6121,7 @@ }; // Generate code for the closing of the data region. - auto &&EndThenGen = [&CGF, &BasePointersArray, &PointersArray, &SizesArray, + auto &&EndThenGen = [&BasePointersArray, &PointersArray, &SizesArray, &MapTypesArray, Device, &NumOfPtrs](CodeGenFunction &CGF, PrePostActionTy &) { assert(BasePointersArray && PointersArray && SizesArray && MapTypesArray && @@ -6188,7 +6188,7 @@ "Expecting either target enter, exit data, or update directives."); // Generate the code for the opening of the data environment. - auto &&ThenGen = [&D, &CGF, Device](CodeGenFunction &CGF, PrePostActionTy &) { + auto &&ThenGen = [&D, Device](CodeGenFunction &CGF, PrePostActionTy &) { // Fill up the arrays with all the mapped variables. MappableExprsHandler::MapValuesArrayTy BasePointers; MappableExprsHandler::MapValuesArrayTy Pointers; @@ -6592,4 +6592,3 @@ } CGF.EmitRuntimeCall(RTLFn, Args); } -
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor