Skip to content

Commit a9cea73

Browse files
authored
Merge pull request #173 from boostorg/fix-warning
Avoid warning in test
2 parents f20b831 + 30f94c8 commit a9cea73

File tree

4 files changed

+17
-9
lines changed

4 files changed

+17
-9
lines changed

.appveyor.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -138,7 +138,7 @@ environment:
138138
CMAKE_FLAGS: -DBOOST_NOWIDE_DISABLE_CIN_TEST=ON
139139
GENERATOR: Visual Studio 17 2022
140140
configuration: Debug
141-
BOOST_ROOT: C:\Libraries\boost_1_77_0
141+
BOOST_ROOT: C:\Libraries\boost_1_83_0
142142

143143
# Coverity
144144
- COVERITY: true

.azure-pipelines.yml

+4-2
Original file line numberDiff line numberDiff line change
@@ -50,8 +50,8 @@ parameters:
5050
- { compiler: clang-8, cxxstd: '14,17', os: ubuntu-20.04 }
5151
- { compiler: clang-9, cxxstd: '14,17,2a', os: ubuntu-20.04 }
5252
- { compiler: clang-10, cxxstd: '14,17,20', os: ubuntu-20.04 }
53-
- { compiler: clang-11, cxxstd: '14,17,20', os: ubuntu-22.04 }
54-
- { compiler: clang-12, cxxstd: '14,17,20', os: ubuntu-22.04 }
53+
- { compiler: clang-11, cxxstd: '14,17,20', os: ubuntu-20.04 }
54+
- { compiler: clang-14, cxxstd: '14,17,20', os: ubuntu-22.04, gcc_toolchain: 12 }
5555
- { name: Linux_clang_6_libcxx,
5656
compiler: clang-6.0, cxxstd: '11,14,17', os: ubuntu-20.04, container: 'ubuntu:18.04', install: 'clang-6.0 libc++-dev libc++abi-dev', env: {B2_STDLIB: libc++ } }
5757
# OSX
@@ -94,6 +94,8 @@ stages:
9494
XCODE_APP: /Applications/Xcode_${{ item.xcode }}.app
9595
${{ if item.install }}:
9696
PACKAGES: ${{ item.install }}
97+
${{ if item.gcc_toolchain }}:
98+
GCC_TOOLCHAIN: ${{ item.gcc_toolchain }}
9799
${{ each var in item.env }}:
98100
${{var.Key}}: ${{var.Value}}
99101
steps:

.github/workflows/ci.yml

+5-4
Original file line numberDiff line numberDiff line change
@@ -78,8 +78,9 @@ jobs:
7878
- { compiler: clang-10, cxxstd: '03,11,14,17,20', os: ubuntu-20.04 }
7979
- { compiler: clang-11, cxxstd: '03,11,14,17,20', os: ubuntu-20.04 }
8080
- { compiler: clang-12, cxxstd: '03,11,14,17,20', os: ubuntu-20.04 }
81-
- { compiler: clang-13, cxxstd: '03,11,14,17,20', os: ubuntu-22.04 }
82-
- { compiler: clang-14, cxxstd: '03,11,14,17,20', os: ubuntu-22.04 }
81+
# Clang isn't compatible with libstdc++-13, so use the slightly older one
82+
- { compiler: clang-13, cxxstd: '03,11,14,17,20', os: ubuntu-22.04, install: 'clang-13 g++-12', gcc_toolchain: 12 }
83+
- { compiler: clang-14, cxxstd: '03,11,14,17,20', os: ubuntu-22.04, install: 'clang-14 g++-12', gcc_toolchain: 12 }
8384

8485
# libc++
8586
- { compiler: clang-6.0, cxxstd: '03,11,14', os: ubuntu-22.04, container: 'ubuntu:18.04', stdlib: libc++, install: 'clang-6.0 libc++-dev libc++abi-dev' }
@@ -104,9 +105,9 @@ jobs:
104105
fi
105106
if [ -n "${{matrix.container}}" ] && [ -f "/etc/debian_version" ]; then
106107
apt-get -o Acquire::Retries=$NET_RETRY_COUNT update
107-
apt-get -o Acquire::Retries=$NET_RETRY_COUNT install -y sudo software-properties-common
108+
apt-get -o Acquire::Retries=$NET_RETRY_COUNT install -y sudo software-properties-common curl
108109
# Need (newer) git, and the older Ubuntu container may require requesting the key manually using port 80
109-
apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys E1DD270288B4E6030699E45FA1715D88E1DF1F24
110+
curl -sSL --retry ${NET_RETRY_COUNT:-5} 'http://keyserver.ubuntu.com/pks/lookup?op=get&search=0xE1DD270288B4E6030699E45FA1715D88E1DF1F24' | sudo gpg --dearmor > /etc/apt/trusted.gpg.d/git-core_ubuntu_ppa.gpg
110111
for i in {1..${NET_RETRY_COUNT:-3}}; do sudo -E add-apt-repository -y ppa:git-core/ppa && break || sleep 10; done
111112
apt-get -o Acquire::Retries=$NET_RETRY_COUNT update
112113
apt-get -o Acquire::Retries=$NET_RETRY_COUNT install -y g++ python libpython-dev git

test/test_fs.cpp

+7-2
Original file line numberDiff line numberDiff line change
@@ -13,10 +13,15 @@
1313
#include <boost/nowide/convert.hpp>
1414
#include <boost/nowide/cstdio.hpp>
1515
#include <boost/nowide/fstream.hpp>
16-
#include <boost/nowide/quoted.hpp>
1716
#include <boost/nowide/utf/convert.hpp>
1817
#include "test.hpp"
19-
#include <iomanip>
18+
19+
#include <iomanip> // Required for feature macro check below
20+
// Conditional include to avoid warning/message
21+
#if defined(__cpp_lib_quoted_string_io) && __cpp_lib_quoted_string_io >= 201304
22+
#include <boost/nowide/quoted.hpp>
23+
#endif
24+
2025
#include <sstream>
2126
#include <type_traits>
2227
#if defined(_MSC_VER)

0 commit comments

Comments
 (0)