# Julia's loop scope behavior differs from Fortran?

**URL:** https://discourse.julialang.org/t/julias-loop-scope-behavior-differs-from-fortran/50275
**Category:** General Usage
**Created:** [November 17, 2020, 6:55am UTC](https://discourse.julialang.org/t/julias-loop-scope-behavior-differs-from-fortran/50275 "2020-11-17T06:55:06Z")
**Posts on this page:** 1
**Showing post:** 15

<div class="post-metadata">

### Author: ![Henrique\_Becker](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/henrique_becker/32/15443_2.png) [@Henrique\_Becker](https://discourse.julialang.org/u/Henrique_Becker)
#### Post date: [November 17, 2020, 1:25pm UTC](https://discourse.julialang.org/t/julias-loop-scope-behavior-differs-from-fortran/50275/15 "2020-11-17T13:25:59Z")

</div>

I need to take some time to check if the documentation would not benefit from a gigantic red box pointing out this `for` loop scope property. [It is not the first question this comes up.](https://discourse.julialang.org/t/i-thought-i-understood-pass-by-sharing-in-julia-until-i-found-this/46897/19) And it is also important [if you are dealing with closures inside a `for` loop too](https://discourse.julialang.org/t/i-thought-i-understood-pass-by-sharing-in-julia-until-i-found-this/46897/24). There is [a section of the manual that points out this scope property and also that you may reuse an existing variable as iterator with the keyword `outer`](https://docs.julialang.org/en/v1/manual/variables-and-scoping/#Loops-and-Comprehensions), but maybe it is not very noticeable.

---

_[View the full topic](https://discourse.julialang.org/t/julias-loop-scope-behavior-differs-from-fortran/50275)._
