yesodweb / yesod-scaffold

The Yesod scaffolding, with branches for different versions.
MIT License
75 stars 39 forks source link

Add foregin-store: Fix compile error for lts-10 #175

Closed psibi closed 6 years ago

psibi commented 6 years ago

Right now, you get this error when you build:

[1 of 3] Compiling DevelMain        ( app/DevelMain.hs, .stack-work/dist/x86_64-linux/Cabal-2.0.1.0/build/todo/todo-tmp/DevelMain.o ) [Foreign.Store changed]

/home/sibi/todo/app/DevelMain.hs:40:1: error:
    Could not find module ‘Foreign.Store’
    Perhaps you meant
      Foreign.Ptr (from base-4.10.1.0)
      Foreign.Safe (from base-4.10.1.0)
      Foreign.Storable (from base-4.10.1.0)
    Use -v to see a list of the files searched for.
   |
40 | import Foreign.Store
   | ^^^^^^^^^^^^^^^^^^^^

My PR just adds the appropriate package in the package.yaml file.

MaxGabriel commented 6 years ago

Did something change with LTS 10/GHC 8.2 that causes this problem?

psibi commented 6 years ago

I'm not sure, it may be even a bug at GHC side.

So, the foreign-store package is needed by the file DevelMain.hs file. It's in the other-modules section of the cabal file. In previous version of ghc it didn't seemed to be compiled. In the newer version - that file is getting compiled.

MaxGabriel commented 6 years ago

Oh, weird. Regardless: LGTM