Skip to content

Commit

Permalink
Quote 'maybe' type
Browse files Browse the repository at this point in the history
  • Loading branch information
ieQu1 committed May 5, 2024
1 parent 3e458d7 commit d388648
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 5 deletions.
10 changes: 7 additions & 3 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,13 +13,17 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
otp: [25.2, 21.3.8.21]
otp: [27, 21]
container:
image: erlang:${{ matrix.otp }}

steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
- name: Fix repository ownership
run: git config --global --add safe.directory /__w/snabbkaffe/snabbkaffe
- name: Compile and run tests
run: make
run: |
cd /__w/snabbkaffe/snabbkaffe
make
- name: Test with concuerror
run: make concuerror_test
3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -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.
Expand Down
4 changes: 2 additions & 2 deletions src/snabbkaffe.erl
Original file line number Diff line number Diff line change
Expand Up @@ -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()
Expand All @@ -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
]).

Expand Down

0 comments on commit d388648

Please sign in to comment.