Elixir release

1.17.0

Change breakdown

Organization at a glance

Detailed changelog

Enhancement

38 changes

Tool: Elixir Module: Access

Add Access.find/1 that mirrors Enum.find/2

Tool: Elixir Module: Code

Support cursor inside fn/rescue/catch/else/after inside Code.Fragment.container_cursor_to_quoted/2

Tool: Elixir Module: Date

Add Date.shift/2 to shift dates with duration and calendar-specific semantics

Tool: Elixir Module: Date

Allow Date to accept years outside of -9999..9999 range

Tool: Elixir Module: DateTime

Add DateTime.shift/2 to shift datetimes with duration and calendar-specific semantics

Tool: Elixir Module: Duration

Add a new Duration data type

Tool: Elixir Module: GenServer

Add c:GenServer.format_status/1 callback

Tool: Elixir Module: Kernel

Add Kernel.get_in/1 with safe nil-handling for access and structs

Tool: Elixir Module: Kernel

Add Kernel.is_non_struct_map/1 guard

Tool: Elixir Module: Kernel

Add Kernel.to_timeout/1

Tool: Elixir Module: Kernel

Emit warnings for undefined functions from modules defined within the same context as the caller code

Tool: Elixir Module: Kernel

Support integers in uppercase sigils

Tool: Elixir Module: Keyword

Add Keyword.intersect/2-3 to mirror the Map API

Tool: Elixir Module: Macro

Add Macro.Env.define_alias/4, Macro.Env.define_import/4, Macro.Env.define_require/4, Macro.Env.expand_alias/4, Macro.Env.expand_import/5, and Macro.Env.expand_require/6 to aid the implementation of language servers and embedded languages

Tool: Elixir Module: NaiveDateTime

Add NaiveDateTime.shift/2 to shift naive datetimes with duration and calendar-specific semantics

Tool: Elixir Module: Process

Add Process.set_label/1

Tool: Elixir Module: String

Add String.byte_slice/3 to slice a string to a maximum number of bytes while keeping it UTF-8 encoded

Tool: Elixir Module: System

Support use_stdio: false in System.cmd/3 and System.shell/2

Tool: Elixir Module: Time

Add Time.shift/2 to shift times with duration and calendar-specific semantics

Tool: ExUnit Module: ExUnit

Propagate the test process itself as a caller in start_supervised

Tool: ExUnit Module: ExUnit

Include max cases in ExUnit reports

Tool: IEx Module: IEx.Helpers

Warns if recompile was called and the current working directory changed

Tool: IEx Module: IEx.Helpers

Add c/0 as an alias to continue/0

Tool: IEx Module: IEx.Pry

Add IEx.Pry.annotate_quoted/3 to annotate a quoted expression with pry breakpoints

Tool: Logger Module: Logger

Format :gen_statem reports using Elixir data structures

Tool: Logger Module: Logger

Include process label in logger events

Tool: Mix Module: mix deps

Add :depth option to Mix.SCM.Git, thus supporting shallow clones of Git dependencies

Tool: Mix Module: mix deps

Warn if :optional is used in combination with :in_umbrella

Tool: Mix Module: mix deps.get

Do not add optional dependency requirements if its parent dep was skipped

Tool: Mix Module: mix deps.tree

Add --umbrella-only to mix deps.tree

Tool: Mix Module: mix profile.tprof

Add a new profiler, available on Erlang/OTP 27+, which can measure count, time, and heap usage

Tool: Mix Module: mix test

Add mix test --breakpoints that sets up a breakpoint before each test that will run

Tool: Mix Module: mix test

Add mix test --repeat-until-failure to rerun tests until a failure occurs

Tool: Mix Module: mix test

Add mix test --slowest-modules to print slowest modules based on all of the tests they hold

Tool: Mix Module: mix test

Generate cover HTML files in parallel

Tool: Elixir Module: GenServer

Deprecate c:GenServer.format_status/2 callback to align with Erlang/OTP 25+

Tool: Mix Module: mix profile.cprof

Deprecated in favor of the new mix profile.tprof

Tool: Mix Module: mix profile.eprof

Deprecated in favor of the new mix profile.tprof

Bugfix

12 changes

Tool: Elixir Module: bin/elixir.bat

Improve handling of quotes and exclamation marks in flags

Tool: Elixir Module: Code

Address a bug where AST nodes for (a -> b) were not wrapped as part of the literal encoder

Tool: Elixir Module: Kernel

Resolve inconsistencies of how .. and ... are handled at the AST level

Tool: Elixir Module: Kernel

Fix parsing precedence of ambiguous operators followed by containers

Tool: Elixir Module: Kernel

Do not expand code in quote bind_quoted: ... twice

Tool: Elixir Module: Kernel

Respect :line property when :file is given as option to quote

Tool: Elixir Module: Kernel

Do not crash on Macro.escape/2 when passing a quote triplet without valid meta

Tool: Elixir Module: Kernel

Avoid double tracing events when capturing a function

Tool: Elixir Module: Kernel

Fix a bug where captured arguments would conflict when a capture included a macro that also used captures

Tool: Elixir Module: Module

Return default value in Module.get_attribute/3 for persisted attributes which have not yet been written to

Tool: IEx Module: IEx.Helpers

Update the history size whenever history is pruned

Tool: Mix Module: mix deps

Fix error message for diverged SCM definition in sibling

Hard Deprecation

6 changes

Tool: Elixir Module: IO

Passing :all to IO.read/2 and IO.binread/2 is deprecated, pass :eof instead

Tool: Elixir Module: Kernel

Single-quote charlists are deprecated, use ~c instead

Tool: Elixir Module: Kernel

Deprecate escaping closing delimiter in uppercase sigils

Tool: Elixir Module: Range

left..right without explicit steps inside patterns and guards is deprecated, write left..right//step instead

Tool: Elixir Module: Range

Decreasing ranges, such as 10..1 without an explicit step is deprecated, write 10..1//-1 instead

Tool: ExUnit Module: ExUnit.Case

register_test/4 is deprecated in favor of register_test/6 for performance reasons