Skip to content

[bug] detect_api.detect_msvc_compiler() returns an incorrect version #16577

@Todiq

Description

@Todiq

Describe the bug

version: 2.4.1
conan_path: D:\venv\Scripts\conan
python
version: 3.9.13
sys_version: 3.9.13 (tags/v3.9.13:6de2ca5, May 17 2022, 16:36:42) [MSC v.1929 64 bit (AMD64)]
sys_executable: D:\venv\Scripts\python.exe
is_frozen: False
architecture: AMD64
system
version: 10.0.22631
platform: Windows-10-10.0.22631-SP0
system: Windows
release: 10
cpu: Intel64 Family 6 Model 186 Stepping 3, GenuineIntel

How to reproduce it

Hello,

I just noticed that {% set compiler, version, ignored = detect_api.detect_msvc_compiler() %} returns an incorrect compiler version.

In fact, we can observe it in the source code:

def detect_msvc_compiler():

A VS version >= 17.10 should return a compiler version of 194 instead of 193.

This does not affect detect_api.detect_default_compiler(), which returns 194 as expected.

Could you please have a look?

Thanks for your hard work!

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions