For example:
cueball$ cat test.hs
#!/usr/bin/env stack
-- stack exec ghci
main = putStrLn "Hello!"
cueball$ stack test.hs
GHCi, version 7.10.2: http://www.haskell.org/ghc/ :? for help
[1 of 1] Compiling Main ( test.hs, interpreted )
Ok, modules loaded: Main.
*Main>
It can confuse and surprise if one writes a wrong comment.
I have a fix which restricts the commands to runhaskell and runghc in the interpreter mode.