summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristopher Keele <christhekeele@gmail.com>2023-04-29 04:14:05 -0500
committerGitHub <noreply@github.com>2023-04-29 11:14:05 +0200
commit88e02c2ddcb23d9ec2961d3b5fcfd0e11d907f13 (patch)
tree707723e4a1adb5f7af5e3dbfae30af82ffa1b2b4
parent1e2f1706dcea8343b9d7369db633f87c687a6c7c (diff)
downloadelixir-88e02c2ddcb23d9ec2961d3b5fcfd0e11d907f13.tar.gz
Document what an @external_resource path is relative to (#12539)
-rw-r--r--lib/elixir/lib/module.ex5
1 files changed, 5 insertions, 0 deletions
diff --git a/lib/elixir/lib/module.ex b/lib/elixir/lib/module.ex
index fc49c921d..5ed28ac96 100644
--- a/lib/elixir/lib/module.ex
+++ b/lib/elixir/lib/module.ex
@@ -261,6 +261,11 @@ defmodule Module do
in case any of the external resources change, see for example:
[`mix compile.elixir`](https://hexdocs.pm/mix/Mix.Tasks.Compile.Elixir.html).
+ The specified file path provided is interpreted as relative to
+ the folder containing the project's `mix.exs`, which is the
+ current working directory, not the file where `@external_resource`
+ is declared.
+
If the external resource does not exist, the module still has
a dependency on it, causing the module to be recompiled as soon
as the file is added.