haskell-perf / csv

Simple comparative benchmarks for CSV parsing libraries
17 stars 4 forks source link

Add generate executable #2

Closed 4e6 closed 6 years ago

4e6 commented 6 years ago

Issue

$ stack build
$ stack ghc -- Generate.hs -o generate

The command above relies on the fact that there is a QuickCheck library built and cached in the local .stack/snapshots directory.

When it's not the case (you build a fresh LTS snapshot), the command will result in an error:

$ stack ghc -- Generate.hs -o generate           
[1 of 1] Compiling Main             ( Generate.hs, Generate.o ) [Test.QuickCheck changed]

Generate.hs:8:1: error:
    Could not find module ‘Test.QuickCheck’
    Use -v to see a list of the files searched for.
  |
8 | import Test.QuickCheck
  | ^^^^^^^^^^^^^^^^^^^^^^

Using the

stack exec generate > in.csv

solves the problem, and also looks cleaner IMO.