2
0
mirror of https://github.com/boostorg/compat.git synced 2026-01-20 16:32:23 +00:00

6 Commits

Author SHA1 Message Date
Peter Dimov
0008d02a62 Update ci.yml 2023-08-29 11:57:33 +03:00
Peter Dimov
0387e8afe1 Merge pull request #4 from ecatmur/gcc-13
Also suppress Wself-move under gcc 13
2023-08-29 02:50:54 +03:00
Ed Catmur
6292106e68 Update shared_lock_test.cpp 2023-08-28 15:51:11 -05:00
Ed Catmur
8f75ad2a75 Also suppress Wself-move under gcc 13
Compiling with gcc 13.1.0:

   ../libs/compat/test/shared_lock_test.cpp: In function 'void {anonymous}::move_assignment()':
   ../libs/compat/test/shared_lock_test.cpp:378:10: error: moving 'lock' of type '{anonymous}::shared_lock_type' {aka 'boost::compat::shared_lock<dummy_lock>'} to itself [-Werror=self-move]
     378 |     lock = std::move( lock );
         |     ~~~~~^~~~~~~~~~~~~~~~~~~
   ../libs/compat/test/shared_lock_test.cpp:378:10: note: remove 'std::move' call
   cc1plus: all warnings being treated as errors
2023-08-15 19:15:46 -05:00
Peter Dimov
f5da663cbc Add .appveyor.yml 2023-06-25 11:50:24 +03:00
Peter Dimov
8abbc6d979 Update latch.hpp 2023-06-25 11:47:43 +03:00
4 changed files with 84 additions and 6 deletions

56
.appveyor.yml Normal file
View File

@@ -0,0 +1,56 @@
# Copyright 2016-2023 Peter Dimov
# Distributed under the Boost Software License, Version 1.0.
# (See accompanying file LICENSE_1_0.txt or copy at http://boost.org/LICENSE_1_0.txt)
version: 1.0.{build}-{branch}
shallow_clone: true
branches:
only:
- master
- develop
- /feature\/.*/
environment:
matrix:
- APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2015
TOOLSET: msvc-14.0
ADDRMD: 32,64
- APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2017
TOOLSET: msvc-14.1
ADDRMD: 32,64
CXXSTD: 14,17,latest
- APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2017
TOOLSET: msvc-14.1
ADDRMD: 32,64
CXXSTD: 14,17,latest
CXXFLAGS: /permissive-
- APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2017
TOOLSET: clang-win
ADDRMD: 64
CXXSTD: 14,17,latest
- APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2019
TOOLSET: clang-win
ADDRMD: 64
CXXSTD: 14,17,latest
install:
- set BOOST_BRANCH=develop
- if "%APPVEYOR_REPO_BRANCH%" == "master" set BOOST_BRANCH=master
- cd ..
- git clone -b %BOOST_BRANCH% --depth 1 https://github.com/boostorg/boost.git boost-root
- cd boost-root
- git submodule update --init tools/boostdep
- xcopy /s /e /q %APPVEYOR_BUILD_FOLDER% libs\compat\
- python tools/boostdep/depinst/depinst.py compat
- cmd /c bootstrap
- b2 -d0 headers
build: off
test_script:
- if not "%CXXSTD%" == "" set CXXSTD=cxxstd=%CXXSTD%
- if not "%ADDRMD%" == "" set ADDRMD=address-model=%ADDRMD%
- if not "%CXXFLAGS%" == "" set CXXFLAGS=cxxflags=%CXXFLAGS%
- if "%CMAKE%%CMAKE_SUBDIR%%CMAKE_INSTALL%" == "" b2 -j3 libs/compat/test toolset=%TOOLSET% %CXXSTD% %ADDRMD% %CXXFLAGS% variant=debug,release embed-manifest-via=linker

View File

@@ -55,6 +55,11 @@ jobs:
cxxstd: "03,11,14,17,20,2b"
os: ubuntu-22.04
install: g++-12
- toolset: gcc-13
cxxstd: "03,11,14,17,20,2b"
os: ubuntu-latest
container: ubuntu:23.04
install: g++-13
- toolset: clang
compiler: clang++-3.9
cxxstd: "03,11,14"
@@ -123,12 +128,21 @@ jobs:
cxxstd: "03,11,14,17,20,2b"
os: ubuntu-22.04
install: clang-15
- toolset: clang
compiler: clang++-16
cxxstd: "03,11,14,17,20,2b"
os: ubuntu-latest
container: ubuntu:23.04
install: clang-16
- toolset: clang
cxxstd: "03,11,14,17,2a"
os: macos-11
- toolset: clang
cxxstd: "03,11,14,17,20,2b"
os: macos-12
- toolset: clang
cxxstd: "03,11,14,17,20,2b"
os: macos-13
runs-on: ${{matrix.os}}
container: ${{matrix.container}}
@@ -144,11 +158,13 @@ jobs:
if: matrix.container
run: |
apt-get update
apt-get -y install sudo python git g++
apt-get -y install sudo python3 git g++
- name: Install packages
if: matrix.install
run: sudo apt-get -y install ${{matrix.install}}
run: |
sudo apt-get update
sudo apt-get -y install ${{matrix.install}}
- name: Setup Boost
run: |
@@ -169,7 +185,7 @@ jobs:
mkdir -p libs/$LIBRARY
cp -r $GITHUB_WORKSPACE/* libs/$LIBRARY
git submodule update --init tools/boostdep
python tools/boostdep/depinst/depinst.py --git_args "--jobs 3" $LIBRARY
python3 tools/boostdep/depinst/depinst.py --git_args "--jobs 3" $LIBRARY
./bootstrap.sh
./b2 -d0 headers
@@ -251,6 +267,7 @@ jobs:
- os: ubuntu-22.04
- os: macos-11
- os: macos-12
- os: macos-13
runs-on: ${{matrix.os}}
@@ -299,6 +316,7 @@ jobs:
- os: ubuntu-22.04
- os: macos-11
- os: macos-12
- os: macos-13
runs-on: ${{matrix.os}}
@@ -357,6 +375,7 @@ jobs:
- os: ubuntu-22.04
- os: macos-11
- os: macos-12
- os: macos-13
runs-on: ${{matrix.os}}

View File

@@ -1,11 +1,11 @@
#ifndef BOOST_COMPAT_LATCH_HPP_INCLUDED
#define BOOST_COMPAT_LATCH_HPP_INCLUDED
// Copyright 2023 Peter Dimov.
// Copyright 2023 Christian Mazakas.
// Distributed under the Boost Software License, Version 1.0.
// https://www.boost.org/LICENSE_1_0.txt
#ifndef BOOST_COMPAT_LATCH_HPP_INCLUDED
#define BOOST_COMPAT_LATCH_HPP_INCLUDED
#include <boost/assert.hpp>
#include <climits>

View File

@@ -23,6 +23,9 @@
#ifdef __clang__
#pragma clang diagnostic ignored "-Wself-move"
#endif
#if defined(__GNUC__) && __GNUC__ >= 13
#pragma GCC diagnostic ignored "-Wself-move"
#endif
struct invalid_lock_use: public std::runtime_error
{