Yes, this is a known bug; the output suppression in the REPL (and IJulia,
and IPython) is a quick hack that doesn't really parse the source code, so
it gets confused by comments. (Doing it properly is complicated because
you have to distinguish real comments from # embedded in strings.) See:
https://github.com/JuliaLang/IJulia.jl/issues/109
https://github.com/ipython/ipython/issues/4525
https://github.com/JuliaLang/julia/issues/6225
The funny thing is that this went unnoticed for years in IPython, and now
suddenly people keep filing issues. Without support from the Julia
parser, it doesn't seem worth the trouble to fix, but it sure keeps popping
up.