Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
20 commits
Select commit Hold shift + click to select a range
49753e2
Revert "Modernize `x3::with` (#829)"
saki7 Sep 12, 2025
ac6ed01
Revert "Merge pull request #827 from saki7/modernize-skip"
saki7 Sep 12, 2025
385a9c3
Revert "Merge pull request #820 from saki7/modernize-expect"
saki7 Sep 12, 2025
14dfeaf
Revert "Merge pull request #817 from saki7/modernize-char-string"
saki7 Sep 12, 2025
6218dcc
Revert "Merge pull request #826 from saki7/modernize-repeat"
saki7 Sep 12, 2025
069d2a0
Revert "Merge pull request #825 from saki7/modernize-raw"
saki7 Sep 12, 2025
5d52405
Revert "Merge pull request #824 from saki7/modernize-omit"
saki7 Sep 12, 2025
26d6ec1
Revert "Merge pull request #822 from saki7/modernize-matches"
saki7 Sep 12, 2025
bc3138d
Revert "Merge pull request #821 from saki7/modernize-lexeme"
saki7 Sep 12, 2025
c41c9ae
Revert "Modernize `x3::confix` (#819)"
saki7 Sep 12, 2025
569c522
Revert "Modernize `x3::action` (#815)"
saki7 Sep 12, 2025
e4d3fce
Revert "Merge pull request #813 from saki7/modernize-rule-parser"
saki7 Sep 12, 2025
63fabec
Revert "Use concepts for attribute category overload resolution (#812)"
saki7 Sep 12, 2025
96b81d3
Revert "Fix typo in README"
saki7 Sep 12, 2025
795d616
Revert "Harmless commit to make sure CI is working on direct push"
saki7 Sep 12, 2025
a0c9105
Revert "Skip the "build" job for empty changes case"
saki7 Sep 12, 2025
421707f
Revert "Add CI badge"
saki7 Sep 12, 2025
ec681a2
Revert "Merge pull request #808 from saki7/refine-ci-cpp23"
saki7 Sep 12, 2025
d88f114
Revert "Define the concept of "parser" in X3 (#807)"
saki7 Sep 12, 2025
6772cdd
Add information about Spirit.X4
saki7 Sep 13, 2025
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
77 changes: 77 additions & 0 deletions .appveyor.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,77 @@
#==============================================================================
# Copyright (c) 2016-2020 Nikita Kniazev
#
# Use, modification and distribution is subject to the Boost Software
# License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
# http://www.boost.org/LICENSE_1_0.txt)
#==============================================================================

clone_depth: 50

environment:
global:
PROJECT: libs\spirit

matrix:
- { APPVEYOR_BUILD_WORKER_IMAGE: 'Visual Studio 2019', ADDRMDL: 64, TOOLSET: 'msvc-14.2' }
- { APPVEYOR_BUILD_WORKER_IMAGE: 'Visual Studio 2017', ADDRMDL: 64, TOOLSET: 'msvc-14.1' }
- { APPVEYOR_BUILD_WORKER_IMAGE: 'Visual Studio 2015', ADDRMDL: 64, TOOLSET: 'msvc-14.0' }

init:
- set BOOST_ROOT=%APPVEYOR_BUILD_FOLDER%\..\boost
- set BOOST_BUILD_PATH=%BOOST_ROOT%\..\boost-build
- set B2_ARGS=link=shared threading=multi variant=release
address-model=%ADDRMDL% toolset=%TOOLSET%
define=BOOST_ALL_NO_LIB
define=BOOST_SPIRIT_X3_HIDE_CXX17_WARNING

before_build:
- set PATH=%BOOST_ROOT%;C:\Python36-x64\Scripts;%PATH%
- ps: |
# Creating %USERPROFILE%/user-config.jam file
@'

import feature os regex toolset pch ;


# A subfeature that tells Spirit tests to use PCH
feature.subfeature pch on : version : spirit : optional propagated incidental ;

'@ | sc "$env:USERPROFILE/user-config.jam"

- set BRANCH=%APPVEYOR_REPO_BRANCH%
# TODO: Determine the root branch when PR targeted/build from not our main branches.
- if not "%BRANCH%" == "master"
if not "%BRANCH%" == "develop"
set BRANCH=develop
- echo Root branch is %BRANCH%

# Sadly git's --shallow-submodules has hardcoded depth of 1 commit
# Patch the git binary with a little more depth to deal with boost-commitbot's lag
- ps: |
$git = Get-Command git | Select-Object -ExpandProperty Definition
$git = Split-Path -Parent $git | Split-Path -Parent
Get-ChildItem -Path "$git\mingw64\*" -Include *.exe -Recurse |
ForEach-Object -Process {(Get-Content -Raw $_).Replace("--depth=1","--depth=9") | Set-Content $_}

# Checkout Boost
- git clone -j10 --branch=%BRANCH% --depth=1 --quiet
--recurse-submodules=":(exclude)%PROJECT%" --shallow-submodules
https://github.com/boostorg/boost.git %BOOST_ROOT%
- pushd %BOOST_ROOT%
# Remove empty folder
- rmdir /S /Q %PROJECT%
# Move the repository to boost/libs and make a link to previous place
- move %APPVEYOR_BUILD_FOLDER% %PROJECT%
- mklink /J %APPVEYOR_BUILD_FOLDER% %PROJECT%

build_script:
- bootstrap.bat --with-toolset=msvc

# Let's have less noise (Appveyor cannot collapse command output)
- b2 headers 2>&1 >> deps_build.log
|| ( echo === deps_build.log === && cat deps_build.log )

test_script:
- b2 %B2_ARGS% %PROJECT%\classic\test %PROJECT%\repository\test %PROJECT%\test
warnings=extra warnings-as-errors=on pch=on-spirit
50 changes: 50 additions & 0 deletions .drone.star
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
# Use, modification, and distribution are
# subject to the Boost Software License, Version 1.0. (See accompanying
# file LICENSE.txt)
#
# Copyright Rene Rivera 2020.

# For Drone CI we use the Starlark scripting language to reduce duplication.
# As the yaml syntax for Drone CI is rather limited.
#
#
globalenv={'PROJECT': 'libs/spirit'}
linuxglobalimage="cppalliance/droneubuntu1804:1"
windowsglobalimage="cppalliance/dronevs2019"

def main(ctx):
return [
linux_cxx("STD=14 JOB=test/x3 Job 0", "clang-10", packages="clang-10 libc++-10-dev libc++abi-10-dev jq", llvm_os="bionic", llvm_ver="10", buildtype="boost", buildscript="drone", image=linuxglobalimage, environment={'STD': '14', 'JOB': 'test/x3', 'TRAVIS_COMPILER': 'clang-10', 'DRONE_JOB_UUID': 'b6589fc6ab'}, globalenv=globalenv),
linux_cxx("STD=14 JOB=test/x3 Job 1", "gcc-10", packages="g++-10 jq", buildtype="boost", buildscript="drone", image=linuxglobalimage, environment={'STD': '14', 'JOB': 'test/x3', 'TRAVIS_COMPILER': 'gcc-10', 'DRONE_JOB_UUID': '356a192b79'}, globalenv=globalenv),
linux_cxx("STD=11 JOB=test/qi Job 2", "clang-10", packages="clang-10 libc++-10-dev libc++abi-10-dev jq", llvm_os="bionic", llvm_ver="10", buildtype="boost", buildscript="drone", image=linuxglobalimage, environment={'STD': '11', 'JOB': 'test/qi', 'TRAVIS_COMPILER': 'clang-10', 'DRONE_JOB_UUID': 'da4b9237ba'}, globalenv=globalenv),
linux_cxx("STD=11 JOB=test/karma Job 3", "clang-10", packages="clang-10 libc++-10-dev libc++abi-10-dev jq", llvm_os="bionic", llvm_ver="10", buildtype="boost", buildscript="drone", image=linuxglobalimage, environment={'STD': '11', 'JOB': 'test/karma', 'TRAVIS_COMPILER': 'clang-10', 'DRONE_JOB_UUID': '77de68daec'}, globalenv=globalenv),
linux_cxx("STD=11 JOB=test/lex Job 4", "clang-10", packages="clang-10 libc++-10-dev libc++abi-10-dev jq", llvm_os="bionic", llvm_ver="10", buildtype="boost", buildscript="drone", image=linuxglobalimage, environment={'STD': '11', 'JOB': 'test/lex', 'TRAVIS_COMPILER': 'clang-10', 'DRONE_JOB_UUID': '1b64538924'}, globalenv=globalenv),
linux_cxx("STD=11 JOB=test/support Job 5", "clang-10", packages="clang-10 libc++-10-dev libc++abi-10-dev jq", llvm_os="bionic", llvm_ver="10", buildtype="boost", buildscript="drone", image=linuxglobalimage, environment={'STD': '11', 'JOB': 'test/support', 'TRAVIS_COMPILER': 'clang-10', 'DRONE_JOB_UUID': 'ac3478d69a'}, globalenv=globalenv),
linux_cxx("STD=11 JOB=repository/test Job 6", "clang-10", packages="clang-10 libc++-10-dev libc++abi-10-dev jq", llvm_os="bionic", llvm_ver="10", buildtype="boost", buildscript="drone", image=linuxglobalimage, environment={'STD': '11', 'JOB': 'repository/test', 'TRAVIS_COMPILER': 'clang-10', 'DRONE_JOB_UUID': 'c1dfd96eea'}, globalenv=globalenv),
# Not building #
# linux_cxx("STD=03 JOB=test/qi Job 7", "clang-10", packages="clang-10 libc++-10-dev libc++abi-10-dev jq", llvm_os="bionic", llvm_ver="10", buildtype="boost", buildscript="drone", image=linuxglobalimage, environment={'STD': '03', 'JOB': 'test/qi', 'TRAVIS_COMPILER': 'clang-10', 'DRONE_JOB_UUID': '902ba3cda1'}, globalenv=globalenv),
# Not building #
# linux_cxx("STD=03 JOB=test/karma Job 8", "clang-10", packages="clang-10 libc++-10-dev libc++abi-10-dev jq", llvm_os="bionic", llvm_ver="10", buildtype="boost", buildscript="drone", image=linuxglobalimage, environment={'STD': '03', 'JOB': 'test/karma', 'TRAVIS_COMPILER': 'clang-10', 'DRONE_JOB_UUID': 'fe5dbbcea5'}, globalenv=globalenv),
linux_cxx("STD=03 JOB=test/lex Job 9", "clang-10", packages="clang-10 libc++-10-dev libc++abi-10-dev jq", llvm_os="bionic", llvm_ver="10", buildtype="boost", buildscript="drone", image=linuxglobalimage, environment={'STD': '03', 'JOB': 'test/lex', 'TRAVIS_COMPILER': 'clang-10', 'DRONE_JOB_UUID': '0ade7c2cf9'}, globalenv=globalenv),
linux_cxx("STD=03 JOB=test/support Job 10", "clang-10", packages="clang-10 libc++-10-dev libc++abi-10-dev jq", llvm_os="bionic", llvm_ver="10", buildtype="boost", buildscript="drone", image=linuxglobalimage, environment={'STD': '03', 'JOB': 'test/support', 'TRAVIS_COMPILER': 'clang-10', 'DRONE_JOB_UUID': 'b1d5781111'}, globalenv=globalenv),
linux_cxx("STD=03 JOB=repository/test Job 11", "clang-10", packages="clang-10 libc++-10-dev libc++abi-10-dev jq", llvm_os="bionic", llvm_ver="10", buildtype="boost", buildscript="drone", image=linuxglobalimage, environment={'STD': '03', 'JOB': 'repository/test', 'TRAVIS_COMPILER': 'clang-10', 'DRONE_JOB_UUID': '17ba079149'}, globalenv=globalenv),
linux_cxx("STD=11 JOB=test/qi Job 12", "gcc-10", packages="g++-10 jq", buildtype="boost", buildscript="drone", image=linuxglobalimage, environment={'STD': '11', 'JOB': 'test/qi', 'TRAVIS_COMPILER': 'gcc-10', 'DRONE_JOB_UUID': '7b52009b64'}, globalenv=globalenv),
linux_cxx("STD=11 JOB=test/karma Job 13", "gcc-10", packages="g++-10 jq", buildtype="boost", buildscript="drone", image=linuxglobalimage, environment={'STD': '11', 'JOB': 'test/karma', 'TRAVIS_COMPILER': 'gcc-10', 'DRONE_JOB_UUID': 'bd307a3ec3'}, globalenv=globalenv),
linux_cxx("STD=11 JOB=test/lex Job 14", "gcc-10", packages="g++-10 jq", buildtype="boost", buildscript="drone", image=linuxglobalimage, environment={'STD': '11', 'JOB': 'test/lex', 'TRAVIS_COMPILER': 'gcc-10', 'DRONE_JOB_UUID': 'fa35e19212'}, globalenv=globalenv),
linux_cxx("STD=11 JOB=test/support Job 15", "gcc-10", packages="g++-10 jq", buildtype="boost", buildscript="drone", image=linuxglobalimage, environment={'STD': '11', 'JOB': 'test/support', 'TRAVIS_COMPILER': 'gcc-10', 'DRONE_JOB_UUID': 'f1abd67035'}, globalenv=globalenv),
linux_cxx("STD=11 JOB=repository/test Job 16", "gcc-10", packages="g++-10 jq", buildtype="boost", buildscript="drone", image=linuxglobalimage, environment={'STD': '11', 'JOB': 'repository/test', 'TRAVIS_COMPILER': 'gcc-10', 'DRONE_JOB_UUID': '1574bddb75'}, globalenv=globalenv),
# Not building #
# linux_cxx("STD=03 JOB=test/qi Job 17", "gcc-10", packages="g++-10 jq", buildtype="boost", buildscript="drone", image=linuxglobalimage, environment={'STD': '03', 'JOB': 'test/qi', 'TRAVIS_COMPILER': 'gcc-10', 'DRONE_JOB_UUID': '0716d9708d'}, globalenv=globalenv),
# Not building #
# linux_cxx("STD=03 JOB=test/karma Job 18", "gcc-10", packages="g++-10 jq", buildtype="boost", buildscript="drone", image=linuxglobalimage, environment={'STD': '03', 'JOB': 'test/karma', 'TRAVIS_COMPILER': 'gcc-10', 'DRONE_JOB_UUID': '9e6a55b6b4'}, globalenv=globalenv),
linux_cxx("STD=03 JOB=test/lex Job 19", "gcc-10", packages="g++-10 jq", buildtype="boost", buildscript="drone", image=linuxglobalimage, environment={'STD': '03', 'JOB': 'test/lex', 'TRAVIS_COMPILER': 'gcc-10', 'DRONE_JOB_UUID': 'b3f0c7f6bb'}, globalenv=globalenv),
linux_cxx("STD=03 JOB=test/support Job 20", "gcc-10", packages="g++-10 jq", buildtype="boost", buildscript="drone", image=linuxglobalimage, environment={'STD': '03', 'JOB': 'test/support', 'TRAVIS_COMPILER': 'gcc-10', 'DRONE_JOB_UUID': '91032ad7bb'}, globalenv=globalenv),
linux_cxx("STD=03 JOB=repository/test Job 21", "gcc-10", packages="g++-10 jq", buildtype="boost", buildscript="drone", image=linuxglobalimage, environment={'STD': '03', 'JOB': 'repository/test', 'TRAVIS_COMPILER': 'gcc-10', 'DRONE_JOB_UUID': '472b07b9fc'}, globalenv=globalenv),
# Not building #
# linux_cxx("STD=03 JOB=classic/test Job 22", "clang-10", packages="clang-10 libc++-10-dev libc++abi-10-dev jq", llvm_os="bionic", llvm_ver="10", buildtype="boost", buildscript="drone", image=linuxglobalimage, environment={'STD': '03', 'JOB': 'classic/test', 'TRAVIS_COMPILER': 'clang-10', 'DRONE_JOB_UUID': '12c6fc06c9'}, globalenv=globalenv),
# Not building #
# linux_cxx("STD=03 JOB=classic/test Job 23", "gcc-10", packages="g++-10 jq", buildtype="boost", buildscript="drone", image=linuxglobalimage, environment={'STD': '03', 'JOB': 'classic/test', 'TRAVIS_COMPILER': 'gcc-10', 'DRONE_JOB_UUID': 'd435a6cdd7'}, globalenv=globalenv),
]

# from https://github.com/boostorg/boost-ci
load("@boost_ci//ci/drone/:functions.star", "linux_cxx","windows_cxx","osx_cxx","freebsd_cxx")
88 changes: 88 additions & 0 deletions .drone/drone.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,88 @@
#!/bin/bash

# Copyright 2020 Rene Rivera, Sam Darwin
# Distributed under the Boost Software License, Version 1.0.
# (See accompanying file LICENSE.txt or copy at http://boost.org/LICENSE_1_0.txt)

set -e
export TRAVIS_BUILD_DIR=$(pwd)
export DRONE_BUILD_DIR=$(pwd)
export TRAVIS_BRANCH=$DRONE_BRANCH
export VCS_COMMIT_ID=$DRONE_COMMIT
export GIT_COMMIT=$DRONE_COMMIT
export REPO_NAME=$DRONE_REPO
export USER=$(whoami)
export CC=${CC:-gcc}
export PATH=~/.local/bin:/usr/local/bin:$PATH
export BOOST_ROOT="$HOME/boost"
export BOOST_BUILD_PATH="$HOME/build-boost"
export TRAVIS_PULL_REQUEST=${DRONE_PULL_REQUEST:-false}
export TRAVIS_REPO_SLUG=$REPO_NAME

if [ "$DRONE_JOB_BUILDTYPE" == "boost" ]; then

echo '==================================> INSTALL'

export CACHE_NAME=$TRAVIS_OS_NAME-$TOOLSET-$STD-$JOB
export PATH=$BOOST_ROOT:$PATH
if [[ "$TRAVIS_COMPILER" =~ ^clang- ]]; then export STDLIB=stdlib=libc++ ; fi
# Creating ~/user-config.jam file
sed 's/^ //' > ~/user-config.jam << 'EOF'

import feature ;
import os ;
import regex ;
import toolset ;


local TOOLSET = [ os.environ TRAVIS_COMPILER ] ;
local toolset-parts = [ regex.split $(TOOLSET) "-" ] ;
local toolset-name = $(toolset-parts[1]) ;
local toolset-feature = $(toolset-parts[2-]:J="-") ;

local cxx ;
switch $(toolset-name) {
case gcc : cxx ?= [ regex.replace $(TOOLSET) "gcc" "g++" ] ;
case clang : cxx ?= [ regex.replace $(TOOLSET) "clang" "clang++" ] ;
case * : EXIT "user-config: Unsupported toolset $(toolset-name)" ;
}

using $(toolset-name) : $(toolset-feature) : ccache $(cxx) ;

# Release variant with enabled asserts
variant sanitize : <optimization>speed <debug-symbols>off <inlining>full
<runtime-debugging>off ;

# Determining the root branch
if [[ "$TRAVIS_PULL_REQUEST" == "false" ]]; then
export BRANCH=$TRAVIS_BRANCH
else
# It is a pull request. Retrieve the base branch from GitHub
GH_PR_API=https://api.github.com/repos/$TRAVIS_REPO_SLUG/pulls/$TRAVIS_PULL_REQUEST
export BRANCH=`curl -s $GH_PR_API | jq -r .head.ref`;
fi
if [[ ! "$BRANCH" =~ ^(master|develop)$ ]]; then
# Travis has been triggered not from our main branches.
# Find out the base branch from the git history
# TODO: Not implemented yet, but in most cases it will be develop branch
export BRANCH=develop
fi
echo Root branch is $BRANCH

env
sed 's/--depth=1/--depth=9/g' `which git` > ~/git && chmod +x ~/git
~/git clone -j10 --branch=$BRANCH --depth=1 --quiet --recurse-submodules=":(exclude)$PROJECT" --shallow-submodules https://github.com/boostorg/boost.git $BOOST_ROOT
pushd $BOOST_ROOT
rm -rf $PROJECT
./bootstrap.sh --with-toolset=clang
./b2 headers
cp -rp $TRAVIS_BUILD_DIR $PROJECT
ln -s $PROJECT $TRAVIS_BUILD_DIR
cd $PROJECT
cd $JOB

echo '==================================> SCRIPT'

b2 link=shared threading=multi variant=release,sanitize toolset=$TRAVIS_COMPILER cxxstd=$STD $STDLIB warnings=extra warnings-as-errors=on

fi
Loading