# Implicitly loaded modules in the future?

**URL:** <https://discourse.julialang.org/t/implicitly-loaded-modules-in-the-future/62646>\
**Category:** Internals & Design\
**Tags:** question, module, code-organization\
**Created:** [June 9, 2021, 8:58pm UTC](https://discourse.julialang.org/t/implicitly-loaded-modules-in-the-future/62646 "2021-06-09T20:58:00Z")\
**Posts on this page:** 1\
**Showing post:** 139

<div class="post-metadata">

**Author:** ![patrick-kidger](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/patrick-kidger/32/20378_2.png) [@patrick-kidger](https://discourse.julialang.org/u/patrick-kidger)\
**Post date:** [June 14, 2021, 9:50am UTC](https://discourse.julialang.org/t/implicitly-loaded-modules-in-the-future/62646/139 "2021-06-14T09:50:19Z")

</div>

In brief: the current approach to organising several files worth of code is something like:

```julia
# master.jl
include("utils.jl")
include("A.jl")
include("B.jl")

# utils.jl
common = 1

# A.jl
foo = common + 2

# B.jl
bar = common + 3

```

in which `A.jl` and `B.jl` implicitly depend upon `utils.jl`.

Being implicit in this way [introduces various issues](https://discourse.julialang.org/t/proper-modules-in-the-future/62646/44). For example it’s hard to tell, whilst reading `A.jl`, what `common` is, where it came from, what it does. (Much of this discussion has focussed around the task of reading or maintaining existing code.)

The hope is to switch this out for a syntax looking something like:

```julia
# master.jl
import "A.jl": foo
import "B.jl": bar

# utils.jl
common = 1

# A.jl
import "utils.jl": common
foo = common + 2

# B.jl
import "utils.jl": common
bar = common + 3

```

to make the dependency structure between files explicit. The main motivation being to try and address the drawbacks previously stated.

---

_[View the full topic](https://discourse.julialang.org/t/implicitly-loaded-modules-in-the-future/62646)._
