Skip to content

Commit e445887

Browse files
committed
range-v3: fix compilation on Visual Studio
1 parent 49d945c commit e445887

2 files changed

Lines changed: 10 additions & 0 deletions

File tree

ci_config.json

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1334,7 +1334,9 @@
13341334
"ignore_upstream_meson": "3.2"
13351335
},
13361336
"range-v3": {
1337+
"_comment": "c++17 is required when using Visual Studio",
13371338
"build_options": [
1339+
"range-v3:cpp_std:c++17",
13381340
"range-v3:tests=enabled"
13391341
]
13401342
},

subprojects/packagefiles/range-v3/meson.build

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,14 @@ project(
66
license: 'BSL-1.0 and NCSA and MIT and Stepanov McJones Elements of Programming and SGI STL',
77
)
88

9+
cxx = meson.get_compiler('c++')
10+
if cxx.get_argument_syntax() == 'msvc'
11+
add_project_arguments(
12+
'/permissive-',
13+
language: 'c++',
14+
)
15+
endif
16+
917
range_inc = include_directories('include')
1018

1119
range_dep = declare_dependency(

0 commit comments

Comments
 (0)