well-typed / full-text-search

An in-memory full text search engine library. It lets you run full-text queries on a collection of your documents.
Other
47 stars 5 forks source link

build-search-demo no longer compiles #2

Open Mikolaj opened 5 years ago

Mikolaj commented 5 years ago

APIs probably have changed.

~/r/full-text-search$ cabal build -fbuild-search-demo
[...]
Preprocessing executable 'search-demo' for full-text-search-0.2.1.4..
Building executable 'search-demo' for full-text-search-0.2.1.4..
[1 of 9] Compiling ExtractNameTerms ( demo/ExtractNameTerms.hs, /home/mikolaj/r/full-text-search/dist-newstyle/build/x86_64-linux/ghc-8.6.4/full-text-search-0.2.1.4/x/search-demo/build/search-demo/search-demo-tmp/ExtractNameTerms.o )

demo/ExtractNameTerms.hs:60:41: warning: [-Wdeprecations]
    In the use of type constructor or class ‘ListT’
    (imported from Control.Monad.List, but defined in Control.Monad.Trans.List):
    Deprecated: "This transformer is invalid on most monads"
   |
60 | newtype Split a = Split (StateT String (ListT (WriterT [String] Identity)) a)
   |                                         ^^^^^

demo/ExtractNameTerms.hs:70:43: warning: [-Wdeprecations]
    In the use of ‘runListT’
    (imported from Control.Monad.List, but defined in Control.Monad.Trans.List):
    Deprecated: "This transformer is invalid on most monads"
   |
70 | runSplitter (Split m) s = snd (runWriter (runListT (runStateT m s)))
   |                                           ^^^^^^^^
[2 of 9] Compiling HaddockTypes     ( demo/HaddockTypes.hs, /home/mikolaj/r/full-text-search/dist-newstyle/build/x86_64-linux/ghc-8.6.4/full-text-search-0.2.1.4/x/search-demo/build/search-demo/search-demo-tmp/HaddockTypes.o )
[3 of 9] Compiling HaddockLex       ( /home/mikolaj/r/full-text-search/dist-newstyle/build/x86_64-linux/ghc-8.6.4/full-text-search-0.2.1.4/x/search-demo/build/search-demo/search-demo-tmp/HaddockLex.hs, /home/mikolaj/r/full-text-search/dist-newstyle/build/x86_64-linux/ghc-8.6.4/full-text-search-0.2.1.4/x/search-demo/build/search-demo/search-demo-tmp/HaddockLex.o )

demo/HaddockLex.x:121:28: warning: [-Wincomplete-patterns]
    Pattern match(es) are non-exhaustive
    In a case alternative: Patterns not matched: []
    |
121 | alexGetByte (_,[],(c:s)) = case utf8Encode c of
    |                            ^^^^^^^^^^^^^^^^^^^^...
[4 of 9] Compiling HaddockHtml      ( demo/HaddockHtml.hs, /home/mikolaj/r/full-text-search/dist-newstyle/build/x86_64-linux/ghc-8.6.4/full-text-search-0.2.1.4/x/search-demo/build/search-demo/search-demo-tmp/HaddockHtml.o )
[5 of 9] Compiling HaddockParse     ( /home/mikolaj/r/full-text-search/dist-newstyle/build/x86_64-linux/ghc-8.6.4/full-text-search-0.2.1.4/x/search-demo/build/search-demo/search-demo-tmp/HaddockParse.hs, /home/mikolaj/r/full-text-search/dist-newstyle/build/x86_64-linux/ghc-8.6.4/full-text-search-0.2.1.4/x/search-demo/build/search-demo/search-demo-tmp/HaddockParse.o )
[6 of 9] Compiling ExtractDescriptionTerms ( demo/ExtractDescriptionTerms.hs, /home/mikolaj/r/full-text-search/dist-newstyle/build/x86_64-linux/ghc-8.6.4/full-text-search-0.2.1.4/x/search-demo/build/search-demo/search-demo-tmp/ExtractDescriptionTerms.o )
[7 of 9] Compiling PackageIndexUtils ( demo/PackageIndexUtils.hs, /home/mikolaj/r/full-text-search/dist-newstyle/build/x86_64-linux/ghc-8.6.4/full-text-search-0.2.1.4/x/search-demo/build/search-demo/search-demo-tmp/PackageIndexUtils.o )

demo/PackageIndexUtils.hs:23:1: error:
    Could not find module ‘Distribution.PackageDescription.Parse’
    Perhaps you meant
      Distribution.PackageDescription.Parsec (from Cabal-2.4.0.1)
      Distribution.PackageDescription.Parsec (needs flag -package-key Cabal-2.4.1.0)
      Distribution.PackageDescription.Check (from Cabal-2.4.0.1)
    Use -v to see a list of the files searched for.
   |
23 | import Distribution.PackageDescription.Parse
   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^...

demo/PackageIndexUtils.hs:30:12: error:
    Module ‘Distribution.Simple.Utils’ does not export ‘fromUTF8’
   |
30 |          ( fromUTF8 )
   |            ^^^^^^^^