diff options
author | Michał Łępicki <michallepicki@users.noreply.github.com> | 2023-05-17 16:39:06 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-05-17 16:39:06 +0200 |
commit | 04d2592800a0c44b57f0bdba01dd003b782b0c5c (patch) | |
tree | cddb1338f9c4bfaa3549bb9ba8a3b02b6a9adc39 | |
parent | df521d308694b187fa1dc8835f1e5c8f7b79e4e8 (diff) | |
download | elixir-04d2592800a0c44b57f0bdba01dd003b782b0c5c.tar.gz |
for compatibility with Mix.Task.Compiler.Diagnostic struct
-rw-r--r-- | lib/elixir/lib/code.ex | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/lib/elixir/lib/code.ex b/lib/elixir/lib/code.ex index c5c5b63d2..825e611c6 100644 --- a/lib/elixir/lib/code.ex +++ b/lib/elixir/lib/code.ex @@ -198,11 +198,12 @@ defmodule Code do Diagnostics returned by the compiler and code evaluation. """ @type diagnostic(severity) :: %{ - file: Path.t(), - severity: severity, - message: String.t(), - position: position, - stacktrace: Exception.stacktrace() + required(:file) => Path.t(), + required(:severity) => severity, + required(:message) => String.t(), + required(:position) => position, + required(:stacktrace) => Exception.stacktrace(), + optional(any()) => any() } @typedoc "The line. 0 indicates no line." |