New minimum required syntax breaks Visual Studio 17
The documentation here says that the new syntax will be ignored on older CMake versions. However, this is not true for the Visual Studio 17 (MSVC 15.7.5) built-in CMake 3.11. An error similar to this is produced:
1> Version string portion was too short or too long.
at System.Version.VersionResult.SetFailure(ParseFailureKind failure, String argument)
at System.Version.TryParseVersion(String version, VersionResult& result)
at System.Version.Parse(String input)
at System.Version..ctor(String version)
at libcmake.CMakeProjectBase`3.<ExtractInfoGeneric>d__94`1.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at libcmake.CMakeLists.<ExtractInfo>d__114.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at libcmake.CMakeLists.<ParseWithoutCacheAsync>d__113.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Microsoft.VisualStudio.CMake.Project.CMakeListsUtils.<ParseAsync>d__20.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.ValidateEnd(Task task)
at Microsoft.VisualStudio.CMake.Project.CMakeListsCache.<ParseAsync>d__28.MoveNext()
This note about MSVC should be added in the documentation. Originally discovered here. MS bug report here.
Edited by Henry Schreiner