From b1a474a848a852e37212652c4b1a5a3c132dbd21 Mon Sep 17 00:00:00 2001 From: Benjamin Lorenz Date: Tue, 4 Apr 2023 11:50:11 +0200 Subject: [PATCH] (re-)allow include_dependency(directory) same for symlinks, adjust docs accordingly and clarify that it refers to the mtime --- base/loading.jl | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/base/loading.jl b/base/loading.jl index 4c5a7df320dbe..a20f0e67ee1e5 100644 --- a/base/loading.jl +++ b/base/loading.jl @@ -1543,11 +1543,11 @@ end """ include_dependency(path::AbstractString) -In a module, declare that the file specified by `path` (relative or absolute) is a -dependency for precompilation; that is, the module will need to be recompiled if this file -changes. +In a module, declare that the file, directory, or symbolic link specified by `path` +(relative or absolute) is a dependency for precompilation; that is, the module will need +to be recompiled if the modification time of `path` changes. -This is only needed if your module depends on a file that is not used via [`include`](@ref). It has +This is only needed if your module depends on a path that is not used via [`include`](@ref). It has no effect outside of compilation. """ function include_dependency(path::AbstractString) @@ -2822,7 +2822,7 @@ end end for chi in includes f, ftime_req = chi.filename, chi.mtime - if !isfile(f) + if !ispath(f) _f = fixup_stdlib_path(f) if isfile(_f) && startswith(_f, Sys.STDLIB) # mtime is changed by extraction