Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 11 additions & 9 deletions .github/workflows/codecov.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,27 +21,29 @@ jobs:

- name: Build
run: |
brew install gcc@14 lcov ninja binutils
brew install gcc@15 lcov ninja binutils
brew link --force binutils
cmake -E make_directory ${{runner.workspace}}/build
cd ${{runner.workspace}}/build
cmake ${GITHUB_WORKSPACE} -GNinja -DCMAKE_CXX_COMPILER=g++-14 -DCMAKE_CXX_FLAGS="--coverage" -DCMAKE_EXE_LINKER_FLAGS="--coverage"
cmake --build .
cmake -B build -GNinja \
-DCMAKE_CXX_COMPILER=g++-15 \
-DCMAKE_CXX_FLAGS="--coverage" \
-DCMAKE_EXE_LINKER_FLAGS="--coverage" \
-DFLUX_BUILD_EXAMPLES=Off
cmake --build build

- name: Run tests
working-directory: ${{runner.workspace}}/build
working-directory: ${{github.workspace}}/build
run: ctest

- name: Generate coverage report
working-directory: ${{runner.workspace}}/build/test/CMakeFiles/test-flux.dir
working-directory: ${{github.workspace}}/build/test/CMakeFiles/test-flux.dir
run: |
lcov --directory . --capture --gcov gcov-14 --output-file coverage.info
lcov --directory . --capture --gcov gcov-15 --output-file coverage.info
lcov --remove coverage.info '*/test/*' --output-file coverage.info

- name: Upload coverage report
uses: codecov/codecov-action@v4
with:
files: ${{runner.workspace}}/build/test/CMakeFiles/test-flux.dir/coverage.info
files: ${{github.workspace}}/build/test/CMakeFiles/test-flux.dir/coverage.info
token: ${{secrets.CODECOV_TOKEN}}
verbose: true

28 changes: 13 additions & 15 deletions .github/workflows/codeql-analysis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ on:
jobs:
analyze:
name: Analyze
runs-on: ubuntu-24.04
runs-on: ubuntu-latest
permissions:
actions: read
contents: read
Expand All @@ -42,38 +42,36 @@ jobs:

# Initializes the CodeQL tools for scanning.
- name: Initialize CodeQL
uses: github/codeql-action/init@v3
uses: github/codeql-action/init@v4
with:
languages: ${{ matrix.language }}
build-mode: manual
# If you wish to specify custom queries, you can do so here or in a config file.
# By default, queries listed here will override any specified in a config file.
# Prefix the list here with "+" to use these queries and those in the config file.

# Details on CodeQL's query packs refer to : https://docs.github.com/en/code-security/code-scanning/automatically-scanning-your-code-for-vulnerabilities-and-errors/configuring-code-scanning#using-queries-in-ql-packs
# queries: security-extended,security-and-quality


# Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
# If this step fails, then you should remove it and run the build manually (see below)
- name: Autobuild
uses: github/codeql-action/autobuild@v3
# - name: Autobuild
# uses: github/codeql-action/autobuild@v4

# ℹ️ Command-line programs to run using the OS shell.
# 📚 See https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#jobsjob_idstepsrun

# If the Autobuild fails above, remove it and uncomment the following three lines.
# If the Autobuild fails above, remove it and uncomment the following three lines.
# modify them (or add more) to build your code if your project, please refer to the EXAMPLE below for guidance.

# - run: |
# echo "Run, Build Application using script"
# ./location_of_script_within_repo/buildscript.sh
#- run: |
# ${{matrix.install}}
# cmake -E make_directory ${{runner.workspace}}/build
# cd ${{runner.workspace}}/build
# cmake ${GITHUB_WORKSPACE} -GNinja -DCMAKE_CXX_COMPILER=g++-13
# cmake --build .

- run: |
cmake -B build -GNinja
cmake --build build


- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v3
uses: github/codeql-action/analyze@v4
14 changes: 6 additions & 8 deletions .github/workflows/generate-single-header.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ jobs:
run:
name: Generate
runs-on: ubuntu-latest

permissions:
contents: write

Expand All @@ -24,20 +24,18 @@ jobs:

- name: Build
run: |
brew install gcc@14 binutils
brew install gcc@15 binutils
brew link --force binutils
cmake -E make_directory ${{runner.workspace}}/build
cd ${{runner.workspace}}/build
cmake ${GITHUB_WORKSPACE} -DCMAKE_CXX_COMPILER=g++-14 -DFLUX_BUILD_TOOLS=On
cmake --build . --target make_single_header
cmake -B build -DCMAKE_CXX_COMPILER=g++-14 -DFLUX_BUILD_TOOLS=On
cmake --build build --target make_single_header

- name: Run
working-directory: ${{runner.workspace}}/build
working-directory: ${{github.workspace}}/build
run: |
./tools/make_single_header ${GITHUB_WORKSPACE}/include/flux.hpp ${GITHUB_WORKSPACE}/single_include/flux.hpp

- name: Upload
uses: stefanzweifel/git-auto-commit-action@v4
uses: stefanzweifel/git-auto-commit-action@v6
with:
commit_message: Update single header
file_pattern: 'single_include/*'
Expand Down
26 changes: 14 additions & 12 deletions .github/workflows/linux.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: linux
name: Linux CI

on:
push:
Expand All @@ -11,7 +11,7 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
compiler: [GCC-12, GCC-13, GCC-14, GCC-15, Clang-17, Clang-18, Clang-19, Clang-20]
compiler: [GCC-12, GCC-13, GCC-14, GCC-15, Clang-17, Clang-18, Clang-19, Clang-20, Clang-21]
test_with: [Headers, Module]
build_type: [Debug, Release]

Expand All @@ -22,8 +22,6 @@ jobs:
test_with: Module
- compiler: GCC-14
test_with: Module
- compiler: GCC-15
test_with: Module
- compiler: Clang-17
test_with: Module

Expand Down Expand Up @@ -68,6 +66,11 @@ jobs:
install: |
brew install llvm@20 ninja binutils
brew link --force binutils
- compiler: Clang-21
cxx: $(brew --prefix llvm@21)/bin/clang++
install: |
brew install llvm@21 ninja binutils
brew link --force binutils

steps:
- uses: actions/checkout@master
Expand All @@ -78,23 +81,22 @@ jobs:
- name: Create Build Environment
run: |
${{matrix.install}}
cmake -E make_directory ${{runner.workspace}}/build

- name: Configure
working-directory: ${{runner.workspace}}/build
run: |
cmake -GNinja -DCMAKE_BUILD_TYPE=${{matrix.build_type}} -DCMAKE_CXX_COMPILER=${{matrix.cxx}} \
cmake -B build -GNinja \
-DCMAKE_BUILD_TYPE=${{matrix.build_type}} \
-DCMAKE_CXX_COMPILER=${{matrix.cxx}} \
-DCMAKE_CXX_EXTENSIONS=Off \
-DFLUX_BUILD_BENCHMARKS=${{matrix.build_type == 'Release'}} \
-DFLUX_BUILD_MODULE=${{matrix.test_with == 'Module'}} \
-DFLUX_BUILD_TESTS_USING_MODULE=${{matrix.test_with == 'Module'}} \
$GITHUB_WORKSPACE
-DFLUX_BUILD_TESTS_USING_MODULE=${{matrix.test_with == 'Module'}}

- name: Build
working-directory: ${{runner.workspace}}/build
run: cmake --build .
run: cmake --build build

- name: Test
working-directory: ${{runner.workspace}}/build
working-directory: ${{github.workspace}}/build
run: ctest -C ${{matrix.build_type}}
env:
CTEST_OUTPUT_ON_FAILURE: True
31 changes: 19 additions & 12 deletions .github/workflows/macos.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Based on macos.yml from {fmt}
# https://github.com/fmtlib/fmt/blob/master/.github/workflows/macos.yml

name: macos
name: MacOS CI

on:
push:
Expand All @@ -14,7 +14,7 @@ jobs:
runs-on: macos-15
strategy:
matrix:
compiler: [AppleClang, LLVM-Clang-16, LLVM-Clang-17, LLVM-Clang-18, LLVM-Clang-19, LLVM-Clang-20]
compiler: [AppleClang, LLVM-Clang-16, LLVM-Clang-17, LLVM-Clang-18, LLVM-Clang-19, LLVM-Clang-20, LLVM-Clang-21]
test_with: [Headers, Module]
build_type: [Debug, Release]

Expand Down Expand Up @@ -50,6 +50,12 @@ jobs:
install: |
brew update
brew install llvm@20 ninja
- compiler: LLVM-Clang-21
cxx: $(brew --prefix llvm@21)/bin/clang++
ldflags: -L$(brew --prefix llvm@21)/lib/c++
install: |
brew update
brew install llvm@21 ninja


steps:
Expand All @@ -58,23 +64,24 @@ jobs:
- name: Create Build Environment
run: |
${{matrix.install}}
cmake -E make_directory ${{runner.workspace}}/build

- name: Configure
working-directory: ${{runner.workspace}}/build
run: |
cmake -GNinja -DCMAKE_BUILD_TYPE=${{matrix.build_type}} -DCMAKE_CXX_COMPILER=${{matrix.cxx}} \
-DFLUX_BUILD_BENCHMARKS=${{matrix.build_type == 'Release'}} \
-DFLUX_BUILD_MODULE=${{matrix.test_with == 'Module'}} \
-DFLUX_BUILD_TESTS_USING_MODULE=${{matrix.test_with == 'Module'}} \
$GITHUB_WORKSPACE
cmake -B build -GNinja \
-DCMAKE_BUILD_TYPE=${{matrix.build_type}} \
-DCMAKE_CXX_COMPILER=${{matrix.cxx}} \
-DCMAKE_EXE_LINKER_FLAGS=${{matrix.ldflags}} \
-DCMAKE_OSX_SYSROOT=$(xcrun --sdk macosx --show-sdk-path) \
-DCMAKE_CXX_EXTENSIONS=Off \
-DFLUX_BUILD_BENCHMARKS=${{matrix.build_type == 'Release'}} \
-DFLUX_BUILD_MODULE=${{matrix.test_with == 'Module'}} \
-DFLUX_BUILD_TESTS_USING_MODULE=${{matrix.test_with == 'Module'}}

- name: Build
working-directory: ${{runner.workspace}}/build
run: cmake --build . --config ${{matrix.build_type}}
run: cmake --build build --config ${{matrix.build_type}}

- name: Test
working-directory: ${{runner.workspace}}/build
working-directory: ${{github.workspace}}/build
run: ctest -C ${{matrix.build_type}}
env:
CTEST_OUTPUT_ON_FAILURE: True
24 changes: 11 additions & 13 deletions .github/workflows/santizers.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,12 +11,12 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
sanitizer: [ubsan, asan]
sanitizer: [address, undefined]
build_type: [Debug, Release]
include:
- cxx: g++-14
- cxx: g++-15
install: |
brew install gcc@14 ninja binutils
brew install gcc@15 ninja binutils
brew link --force binutils

steps:
Expand All @@ -28,23 +28,21 @@ jobs:
- name: Create Build Environment
run: |
${{matrix.install}}
cmake -E make_directory ${{runner.workspace}}/build

- name: Configure
working-directory: ${{runner.workspace}}/build
run: |
cmake -GNinja \
-DFLUX_ENABLE_ASAN=${{matrix.sanitizer == 'asan'}} \
-DFLUX_ENABLE_UBSAN=${{matrix.sanitizer == 'ubsan'}} \
-DCMAKE_CXX_COMPILER=g++-14 \
$GITHUB_WORKSPACE
cmake -B build -GNinja \
-DCMAKE_CXX_COMPILER=${{matrix.cxx}} \
-DCMAKE_CXX_EXTENSIONS=Off \
-DCMAKE_BUILD_TYPE=${{matrix.build_type}} \
-DCMAKE_CXX_FLAGS="-fsanitize=${{matrix.sanitizer}}" \
-DCMAKE_EXE_LINKER_FLAGS="-fsanitize=${{matrix.sanitizer}}"

- name: Build
working-directory: ${{runner.workspace}}/build
run: cmake --build .
run: cmake --build build

- name: Test
working-directory: ${{runner.workspace}}/build
working-directory: ${{github.workspace}}/build
run: ctest -C ${{matrix.build_type}}
env:
CTEST_OUTPUT_ON_FAILURE: True
19 changes: 7 additions & 12 deletions .github/workflows/windows.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: windows
name: Windows CI

on:
push:
Expand All @@ -8,7 +8,7 @@ on:

jobs:
build:
runs-on: windows-2022
runs-on: windows-2025
strategy:
matrix:
platform: [x86, x64]
Expand All @@ -21,25 +21,20 @@ jobs:
with:
arch: ${{matrix.platform}}

- name: Create Build Environment
run: cmake -E make_directory ${{runner.workspace}}/build

- name: Configure
# Use a bash shell for $GITHUB_WORKSPACE.
shell: bash
working-directory: ${{runner.workspace}}/build
run: |
cmake -G Ninja \
cmake -B build -G Ninja \
-DCMAKE_BUILD_TYPE=${{matrix.build_type}} \
-DFLUX_BUILD_BENCHMARKS=${{matrix.build_type == 'Release'}} \
$GITHUB_WORKSPACE
-DCMAKE_CXX_EXTENSIONS=Off \
-DFLUX_BUILD_BENCHMARKS=${{matrix.build_type == 'Release'}}

- name: Build
working-directory: ${{runner.workspace}}/build
run: cmake --build . --config ${{matrix.build_type}}
run: cmake --build build --config ${{matrix.build_type}}

- name: Test
working-directory: ${{runner.workspace}}/build
working-directory: ${{github.workspace}}/build
run: ctest -C ${{matrix.build_type}} -V
env:
CTEST_OUTPUT_ON_FAILURE: True
2 changes: 1 addition & 1 deletion include/flux/adaptor/reverse.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ struct reverse_adaptor : inline_sequence_base<reverse_adaptor<Base>>
-> std::strong_ordering
requires std::three_way_comparable<cursor_t<Base>, std::strong_ordering>
{
return rhs <=> lhs;
return rhs.base_cur <=> lhs.base_cur;
}
};

Expand Down
1 change: 1 addition & 0 deletions test/test_chain.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
#include <array>
#include <iostream>
#include <utility>
#include <variant>

#include "test_utils.hpp"

Expand Down
1 change: 1 addition & 0 deletions test/test_empty.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@

#include <doctest/doctest.h>

#include <compare>
#include <concepts>

#ifdef USE_MODULES
Expand Down
Loading
Loading