[tox]
envlist = py{27,34,35,36}-{c90,c99,cpp},py{37,38,39,310}-{c99,cpp}
skipsdist = True

[testenv]
allowlist_externals = make
commands = make testbuilddir={envdir}/build test-python
setenv=
    c90: TEST_USE_CPP=no
    c90: CFLAGS=-Werror -Wall -std=c90 -Wno-error=strict-aliasing
    c99: TEST_USE_CPP=no
    c99: CFLAGS=-Werror -Wall -std=c99 -Wno-error=strict-aliasing
    cpp: TEST_USE_CPP=yes
    cpp: CFLAGS=-Werror -Wall -Wno-error=strict-aliasing
    clang: CC=clang
    clang: CFLAGS=-Werror -Wall -std=c99

[tox]
envlist = py{27,34}-{c90,c99,cpp14},py{35,36}-{c90,c99,cpp17},py{37,38,39,310}-{c99,cpp}
skipsdist = True

[testenv]
allowlist_externals = make
commands = make testbuilddir={envdir}/build test-python
setenv=
    c90: TEST_USE_CPP=no
    c90: CFLAGS=-Werror -Wall -std=c90 -Wno-error=strict-aliasing
    c99: TEST_USE_CPP=no
    c99: CFLAGS=-Werror -Wall -std=c99 -Wno-error=strict-aliasing
    cpp17: TEST_USE_CPP=yes
    cpp17: CFLAGS=-Werror -Wall -Wno-error=strict-aliasing -std=c++17
    cpp14: TEST_USE_CPP=yes
    cpp14: CFLAGS=-Werror -Wall -Wno-error=strict-aliasing -std=c++14
    clang: CC=clang
    clang: CFLAGS=-Werror -Wall -std=c99

Use C++14 on Python 2.7 and 3.4; C++17 on newer ones
Use C++14 on Python 2.7 and 3.4; C++17 on newer ones

GCC now supports C++17 by default; the old Python versions
aren't compatioble with it (they use the removed `register`).
Use the new standard on newer Pythons only.
