Cabal reports that it cannot find the module

I set up the following cabal file, but when I do cabal build, I just get an error in the Tasty.hs file saying Could not find module TicTac.Essentialthat I am missing here?

name:                tdd
version:             0.1.0.0
cabal-version:       >=1.8
-- synopsis:            
-- description:         
-- license:             
license-file:        LICENSE
author:              adfaf
maintainer:          info@adfadsf.se
-- copyright:           
-- category:            
build-type:          Simple
extra-source-files:  README

library
  hs-source-dirs:      src
  build-depends:       base >= 4
  ghc-options:         -Wall
  exposed-modules      TicTac.Essential  
  default-language:    Haskell2010

test-suite Tasty
  type:                exitcode-stdio-1.0 
  build-depends:       base >=4.6 && <4.7, tasty, tasty-quickcheck, tdd
  hs-source-dirs:      test
  main-is:             Tasty.hs 

Source tasty.hs

module Main where

import Test.Tasty
import Test.Tasty.QuickCheck as QC 

import TicTac.Essential
+4
source share
1 answer

You are missing a colon after "open modules". Must be

library
  hs-source-dirs:      src
  build-depends:       base >= 4
  ghc-options:         -Wall
  exposed-modules:     TicTac.Essential  
  default-language:    Haskell2010
+3
source

Source: https://habr.com/ru/post/1535265/


All Articles