diff options
author | José Valim <jose.valim@plataformatec.com.br> | 2019-06-13 19:26:14 +0200 |
---|---|---|
committer | José Valim <jose.valim@plataformatec.com.br> | 2019-06-13 19:26:14 +0200 |
commit | 22dbddd3e82d85c63a089fecae190630400722a7 (patch) | |
tree | bfbfa3360db0f69c009607a63c2888078264beac | |
parent | 8564cb84b1f79305495df2c7013e887e746e7250 (diff) | |
download | elixir-22dbddd3e82d85c63a089fecae190630400722a7.tar.gz |
Add a metadata type
-rw-r--r-- | lib/elixir/lib/macro.ex | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/lib/elixir/lib/macro.ex b/lib/elixir/lib/macro.ex index 2437edfe8..ab88a299e 100644 --- a/lib/elixir/lib/macro.ex +++ b/lib/elixir/lib/macro.ex @@ -116,7 +116,7 @@ defmodule Macro do | number | binary - @typep input_expr :: {input_expr | atom, keyword, atom | [input]} + @typep input_expr :: {input_expr | atom, metadata, atom | [input]} @typedoc "The output of a macro" @type output :: @@ -129,7 +129,10 @@ defmodule Macro do | captured_remote_function | pid - @typep output_expr :: {output_expr | atom, keyword, atom | [output]} + @typep output_expr :: {output_expr | atom, metadata, atom | [output]} + + @typedoc "A keyword list of AST metadata" + @type metadata :: keyword @typedoc "A captured remote function in the format of &Mod.fun/arity" @type captured_remote_function :: fun |