Rather than failing late when compiling e.g. a debug configuration
```
build.bat -c debug --tail-call-interp
```
with hundreds of
```
error C4737: Unable to perform required tail call. Performance may be degraded.
```
-- fail early with an explicit error message for configurations that are not supported by MSVC.
This is a follow-up on https://github.com/python/cpython/issues/140513 / https://github.com/python/cpython/pull/140548
--- /dev/null
+Fail fast with an explicit and clear error message if tail-calling is not
+possible for MSVC builds on Windows. Patch by Chris Eibl.
<Target Name="_DeletePyBuildDirTxt" BeforeTargets="PrepareForBuild">
<Delete Files="$(OutDir)pybuilddir.txt" />
</Target>
+
+ <Target Name="_CheckTailCalling" BeforeTargets="PrepareForBuild" Condition="'$(UseTailCallInterp)' == 'true' and $(PlatformToolset) != 'ClangCL'">
+ <Error Text="MSVC supports tail-calling only for x64."
+ Condition="$(Platform) != 'x64'" />
+ <Error Text="Platform toolset >= v145 is required for tail-calling."
+ Condition="$(PlatformToolset.Replace('v', '0')) < '145'" />
+ <Error Text="MSVC requires optimization to be enabled for tail-calling."
+ Condition="$(Configuration) == 'Debug'" />
+ </Target>
</Project>