Skip to content

Instantly share code, notes, and snippets.

@lovesegfault
Created April 22, 2021 10:03
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save lovesegfault/5199c7b058be9e3666c2751a4ad31b88 to your computer and use it in GitHub Desktop.
Save lovesegfault/5199c7b058be9e3666c2751a4ad31b88 to your computer and use it in GitHub Desktop.
/home/bemeurer/src/exercism/haskell/acronym/src/Acronym.hs:7:14: error:
• Couldn't match type ‘[Text]’ with ‘Text’
Expected type: Text -> Text
Actual type: [Text] -> [Text]
• In the expression:
split (\ c -> isSpace c || c `elem` ['-', '_']) . Data.Text.concat
In an equation for ‘abbreviate’:
abbreviate
= split (\ c -> isSpace c || c `elem` ['-', '_'])
. Data.Text.concat
|
7 | abbreviate = split(\c -> isSpace c || c `elem` [ '-', '_' ])
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^...
-- While building package acronym-1.7.0.11 (scroll up to its section to see the error) using:
/home/bemeurer/.stack/setup-exe-cache/x86_64-linux-nix/Cabal-simple_mPHDZzAJ_3.0.1.0_ghc-8.8.4 --builddir=.stack-work/dist/x86_64-linux-nix/Cabal-3.0.1.0 build lib:acronym --ghc-options " -fdiagnostics-color=always"
Process exited with code: ExitFailure 1
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment