atom-haskell-archive / haskell-ghc-mod

haskell-ghc-mod atom package
https://atom.io/packages/haskell-ghc-mod
MIT License
69 stars 20 forks source link

Completion not working in Yesod test-suite #213

Closed soiamsoNG closed 7 years ago

soiamsoNG commented 7 years ago

Use stack template yesod-sqlite to create the project (i name it PP here )

So there will be a library name PP an exe name PP a test-suite name test

Edit the file inside the test folder, and find out that the Completion not fully working just has prelude completion, in the debug info find below EXCEPTION , i suspect ghc-mod did not load (interpret) the library first (PP, or as PP:lib) like the effect of below two command show.

stack ghci PP:test:test above will fail since there is still no library PP in any inventory, need ghci interpret the PP:lib first

stack ghci PP:lib PP:test:test above will success load

Below is the exception message

browse, -d, -p, --, TestImport

`EXCEPTION: browse:

       ByteCodeLink.lookupCE
       During interactive linking, GHCi couldn't find the following symbol:
         yesodzm1zi4zi5zmGjjcx4wipmk9Grx3eCzz8hV_YesodziDefaultziConfig2_configSettingsYml_closure
       This may be due to you not asking GHCi to load extra object files,
       archives or DLLs needed by your current session.  Restart GHCi, specifying
       the missing library using the -L/path/to/object/dir and -lmissinglibname
       flags, or simply by naming the relevant files on the GHCi command line.
       Alternatively, this link failure might indicate a bug in GHCi.
       If you suspect the latter, please send a bug report to:
         glasgow-haskell-bugs@haskell.org`