-
[Fix] Revert C++20-only lambda captures for C++17 build
发布于
2026-06-17 04:13:09 +00:00 Revert four explicit-this lambda captures ([=, this, ...] -> [=, ...]) in
run_codegen.cc, inject_software_pipeline.cc, and cudnn_json_runtime.cc.These were introduced by the C++20 baseline upgrade (#19734); after reverting
the baseline to C++17, MSVC rejects capturing 'this' explicitly under a '='
capture-default (error C3791) -- that form is C++20-only. GCC and Clang accept
it as an extension in C++17, which is why only the Windows wheel build failed.
Dropping the explicit 'this' ('=' captures it implicitly in C++17) restores the
MSVC build with no behavior change.下载附件