From 0f56b07a4487ce49458375a0093cf2699db9a162 Mon Sep 17 00:00:00 2001 From: ieQu1 <99872536+ieQu1@users.noreply.github.com> Date: Sun, 5 May 2024 12:34:18 +0200 Subject: [PATCH] Quote 'maybe' type --- .github/workflows/ci.yml | 4 ++-- CHANGELOG.md | 3 +++ src/snabbkaffe.erl | 4 ++-- 3 files changed, 7 insertions(+), 4 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 81739cf..e3706ea 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -13,12 +13,12 @@ jobs: runs-on: ubuntu-latest strategy: matrix: - otp: [25.2, 21.3.8.21] + otp: [27.0, 21.3.8.21] container: image: erlang:${{ matrix.otp }} steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v3 - name: Compile and run tests run: make - name: Test with concuerror diff --git a/CHANGELOG.md b/CHANGELOG.md index d85c18f..644e6f9 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -7,6 +7,9 @@ - Added new module `snabbkaffe_diff` that helps to compare large lists - Added a new macro `?defer_assert(...)` that allows the run stage to continue after encountering a failure, and fails the testcase in the check stage instead. +### Fixes +- Quote a new reserved word (`maybe`) for compatibility with OTP27 + ## 1.0.9 ### Features - Now it is possible to redefine what `?snk_kind` macro translates to in prod mode by defining `SNK_PROD_KIND` macro. diff --git a/src/snabbkaffe.erl b/src/snabbkaffe.erl index 2649be2..508459d 100644 --- a/src/snabbkaffe.erl +++ b/src/snabbkaffe.erl @@ -101,7 +101,7 @@ -type maybe_pair() :: {pair, timed_event(), timed_event()} | {unmatched_cause | unmatched_effect, timed_event()}. --type maybe(A) :: {just, A} | nothing. +-type 'maybe'(A) :: {just, A} | nothing. -type run_config() :: #{ bucket => integer() @@ -123,7 +123,7 @@ | [trace_spec(Result) | {string(), trace_spec(Result)}]. -export_type([ kind/0, timestamp/0, event/0, timed_event/0, trace/0 - , maybe_pair/0, maybe/1, metric/0, run_config/0, predicate/0 + , maybe_pair/0, 'maybe'/1, metric/0, run_config/0, predicate/0 , predicate2/0, trace_spec/1, trace_specs/1, filter/0 ]).