Skip to content

Fix CI and bugs for Erlang 27 and Elixir 1.17 #1926

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Jun 20, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
7 changes: 5 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,12 +16,15 @@ jobs:
fail-fast: false
matrix:
include:
- pair:
- pair: # Test very old elixir and Erlang
elixir: "1.13"
otp: "22"
- pair:
- pair: # Test Erlang without -doc attribute support
elixir: "1.16"
otp: "26"
- pair: # Test Erlang with -doc attribute support
elixir: "1.17"
otp: "27"
lint: lint
steps:
- uses: actions/checkout@v3
Expand Down
13 changes: 9 additions & 4 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,12 +29,16 @@ jobs:
fail-fast: true
matrix:
include:
- otp: 24
otp_version: "24.0"
- otp: 25
otp_version: "25.0.4"
otp_version: "25.3.2.12"
elixir_version: "1.16.2"
- otp: 26
otp_version: "26.0.2"
otp_version: "26.2.5"
elixir_version: "1.16.2"
- otp: 27
otp_version: "27.0"
elixir_version: "1.17.0"

runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v4
Expand All @@ -44,6 +48,7 @@ jobs:
with:
otp_version: ${{ matrix.otp_version }}
otp: ${{ matrix.otp }}
elixir_version: ${{ matrix.elixir_version }}

- name: Upload Pre-built
env:
Expand Down
4 changes: 3 additions & 1 deletion .github/workflows/release_pre_built/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,13 +5,15 @@ inputs:
description: "The major OTP version"
otp_version:
description: "The exact OTP version (major.minor[.patch])"
elixir_version:
description: "The exact Elixir version (major.minor[.patch])"
runs:
using: "composite"
steps:
- uses: erlef/[email protected]
with:
otp-version: ${{ inputs.otp_version }}
elixir-version: "1.16.0"
elixir-version: ${{ inputs.elixir_version }}
- name: Build ex_doc
shell: bash
run: |
Expand Down
2 changes: 1 addition & 1 deletion lib/ex_doc/language/erlang.ex
Original file line number Diff line number Diff line change
Expand Up @@ -561,7 +561,7 @@ defmodule ExDoc.Language.Erlang do
name == :record and acc != [] ->
{ast, acc}

name in [:"::", :when, :%{}, :{}, :|, :->] ->
name in [:"::", :when, :%{}, :{}, :|, :->, :...] ->
{ast, acc}

# %{required(...) => ..., optional(...) => ...}
Expand Down
3 changes: 3 additions & 0 deletions test/ex_doc/retriever/erlang_test.exs
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ defmodule ExDoc.Retriever.ErlangTest do
test "module with no docs is generated", c do
erlc(c, :mod, ~S"""
-module(mod).
-moduledoc("").
""")

assert {[_], []} = Retriever.docs_from_modules([:mod], %ExDoc.Config{})
Expand Down Expand Up @@ -217,6 +218,7 @@ defmodule ExDoc.Retriever.ErlangTest do
erlc(c, :mod, ~S"""
-module(mod).
-export([f/0]).
-moduledoc("").

f() -> ok.
""")
Expand Down Expand Up @@ -319,6 +321,7 @@ defmodule ExDoc.Retriever.ErlangTest do
erlc(c, :mod, ~s"""
-module(mod).
-export([function/0]).
-moduledoc("").

-record(a, { a = 1 :: pos_integer(),
b :: non_neg_integer(),
Expand Down
Loading