Skip to content

Add match statement (#621) #682

Add match statement (#621)

Add match statement (#621) #682

Workflow file for this run

on:
push:
branches:
- main
pull_request:
jobs:
test:
runs-on: macos-latest
timeout-minutes: 5
strategy:
matrix:
llvm-version: [14, 15, 16]
# Testing all levels because there was a bug that only happened with -O1. (#224)
opt-level: ['-O0', '-O1', '-O2', '-O3']
steps:
- uses: actions/checkout@v3
- run: brew install bash diffutils llvm@${{ matrix.llvm-version }}
- name: "Select LLVM version"
run: |
echo "LLVM_CONFIG=/opt/homebrew/opt/llvm@${{ matrix.llvm-version }}/bin/llvm-config" >> $GITHUB_ENV
- name: "Compile and test stage 1 compiler"
run: ./runtests.sh --verbose --jou-flags "${{ matrix.opt-level }}" --stage1
- name: "Compile and test stage 2 compiler"
run: ./runtests.sh --verbose --jou-flags "${{ matrix.opt-level }}" --stage2
- name: "Compile and test stage 3 compiler"
run: ./runtests.sh --verbose --jou-flags "${{ matrix.opt-level }}"
- name: "Test stage 3 compiler with the compiler's --verbose flag"
run: ./runtests.sh --verbose --jou-flags "${{ matrix.opt-level }} --verbose"
- run: make clean
- name: Check that "make clean" deleted all files not committed to Git
shell: bash
run: |
if [ "$(git status --porcelain --ignored)" != "" ]; then
git status --ignored
exit 1
fi
doctest:
runs-on: macos-latest
timeout-minutes: 5
steps:
- uses: actions/checkout@v3
- run: brew install bash diffutils llvm@15
- run: ./doctest.sh