Speed up folds on Sequences (#510)
[packages/containers.git] / containers.cabal
1 name: containers
2 version: 0.5.11.0
3 license: BSD3
4 license-file: LICENSE
5 maintainer: libraries@haskell.org
6 bug-reports: https://github.com/haskell/containers/issues
7 synopsis: Assorted concrete container types
8 category: Data Structures
9 description:
10     .
11     This package contains efficient general-purpose implementations
12     of various immutable container types including sets, maps, sequences,
13     trees, and graphs.
14     .
15     For a walkthrough of what this package provides with examples of common
16     operations see the [containers
17     introduction](https://haskell-containers.readthedocs.io).
18     .
19     The declared cost of each operation is either worst-case or amortized, but
20     remains valid even if structures are shared.
21
22 build-type: Simple
23 cabal-version:  >=1.8
24 extra-source-files:
25     include/containers.h
26     tests/Makefile
27     tests/*.hs
28     benchmarks/Makefile
29     benchmarks/bench-cmp.pl
30     benchmarks/bench-cmp.sh
31     benchmarks/*.hs
32     benchmarks/SetOperations/Makefile
33     benchmarks/SetOperations/*.hs
34     benchmarks/LookupGE/Makefile
35     benchmarks/LookupGE/*.hs
36     changelog.md
37
38 source-repository head
39     type:     git
40     location: http://github.com/haskell/containers.git
41
42 Library
43     build-depends: base >= 4.3 && < 5, array, deepseq >= 1.2 && < 1.5
44     if impl(ghc)
45         build-depends: ghc-prim
46
47     ghc-options: -O2 -Wall
48
49     other-extensions: CPP, BangPatterns
50
51     exposed-modules:
52         Data.IntMap
53         Data.IntMap.Lazy
54         Data.IntMap.Strict
55         Data.IntMap.Internal
56         Data.IntMap.Internal.Debug
57         Data.IntMap.Merge.Lazy
58         Data.IntMap.Merge.Strict
59         Data.IntSet.Internal
60         Data.IntSet
61         Data.Map
62         Data.Map.Lazy
63         Data.Map.Lazy.Merge
64         Data.Map.Merge.Lazy
65         Data.Map.Strict.Internal
66         Data.Map.Strict
67         Data.Map.Strict.Merge
68         Data.Map.Merge.Strict
69         Data.Map.Internal
70         Data.Map.Internal.Debug
71         Data.Set.Internal
72         Data.Set
73         Data.Graph
74         Data.Sequence
75         Data.Sequence.Internal
76         Data.Sequence.Internal.Sorting
77         Data.Tree
78         Utils.Containers.Internal.BitUtil
79         Utils.Containers.Internal.BitQueue
80         Utils.Containers.Internal.StrictPair
81
82     other-modules:
83         Utils.Containers.Internal.State
84         Utils.Containers.Internal.StrictFold
85         Utils.Containers.Internal.StrictMaybe
86         Utils.Containers.Internal.PtrEquality
87         Utils.Containers.Internal.Coercions
88         Data.Map.Internal.DeprecatedShowTree
89         Data.IntMap.Internal.DeprecatedDebug
90
91     include-dirs: include
92
93 -----------------------------
94 -- B E N C H M A R K I N G --
95 -----------------------------
96
97 benchmark intmap-benchmarks
98   type: exitcode-stdio-1.0
99   hs-source-dirs: benchmarks
100   main-is: IntMap.hs
101   ghc-options: -O2
102   build-depends:
103     base >= 4.2 && < 5,
104     containers,
105     criterion >= 0.4.0 && < 1.3,
106     deepseq >= 1.1.0.0 && < 1.5
107
108 benchmark intset-benchmarks
109   type: exitcode-stdio-1.0
110   hs-source-dirs: benchmarks
111   main-is: IntSet.hs
112   ghc-options: -O2
113   build-depends:
114     base >= 4.2 && < 5,
115     containers,
116     criterion >= 0.4.0 && < 1.3,
117     deepseq >= 1.1.0.0 && < 1.5
118
119 benchmark map-benchmarks
120   type: exitcode-stdio-1.0
121   hs-source-dirs: benchmarks
122   main-is: Map.hs
123   ghc-options: -O2
124   build-depends:
125     base >= 4.2 && < 5,
126     containers,
127     criterion >= 0.4.0 && < 1.3,
128     deepseq >= 1.1.0.0 && < 1.5,
129     transformers
130
131 benchmark sequence-benchmarks
132   type: exitcode-stdio-1.0
133   hs-source-dirs: benchmarks
134   main-is: Sequence.hs
135   ghc-options: -O2
136   build-depends:
137     base >= 4.2 && < 5,
138     containers,
139     criterion >= 0.4.0 && < 1.3,
140     deepseq >= 1.1.0.0 && < 1.5,
141     random < 1.2,
142     transformers
143
144 benchmark set-benchmarks
145   type: exitcode-stdio-1.0
146   hs-source-dirs: benchmarks
147   main-is: Set.hs
148   ghc-options: -O2
149   build-depends:
150     base >= 4.2 && < 5,
151     containers,
152     criterion >= 0.4.0 && < 1.3,
153     deepseq >= 1.1.0.0 && < 1.5
154
155 benchmark set-operations-intmap
156   type: exitcode-stdio-1.0
157   hs-source-dirs: benchmarks/SetOperations
158   main-is: SetOperations-IntMap.hs
159   other-modules: SetOperations
160   ghc-options: -O2
161   build-depends:
162     base >= 4.2 && < 5,
163     containers,
164     criterion >= 0.4.0 && < 1.3
165
166 benchmark set-operations-intset
167   type: exitcode-stdio-1.0
168   hs-source-dirs: benchmarks/SetOperations
169   main-is: SetOperations-IntSet.hs
170   other-modules: SetOperations
171   ghc-options: -O2
172   build-depends:
173     base >= 4.2 && < 5,
174     containers,
175     criterion >= 0.4.0 && < 1.3
176
177 benchmark set-operations-map
178   type: exitcode-stdio-1.0
179   hs-source-dirs: benchmarks/SetOperations
180   main-is: SetOperations-Map.hs
181   other-modules: SetOperations
182   ghc-options: -O2
183   build-depends:
184     base >= 4.2 && < 5,
185     containers,
186     criterion >= 0.4.0 && < 1.3
187
188 benchmark set-operations-set
189   type: exitcode-stdio-1.0
190   hs-source-dirs: benchmarks/SetOperations
191   main-is: SetOperations-Set.hs
192   other-modules: SetOperations
193   ghc-options: -O2
194   build-depends:
195     base >= 4.2 && < 5,
196     containers,
197     criterion >= 0.4.0 && < 1.3
198
199 benchmark lookupge-intmap
200   type: exitcode-stdio-1.0
201   hs-source-dirs: benchmarks/LookupGE, .
202   main-is: IntMap.hs
203   other-modules:
204       Data.IntMap
205       Data.IntMap.Internal.DeprecatedDebug
206       Data.IntMap.Lazy
207       Data.IntMap.Strict
208       Data.IntSet.Internal
209       LookupGE_IntMap
210       Utils.Containers.Internal.BitUtil
211       Utils.Containers.Internal.StrictFold
212       Utils.Containers.Internal.StrictPair
213   ghc-options: -O2
214   cpp-options: -DTESTING
215   other-modules:
216     Data.IntMap.Internal
217   build-depends:
218     base >= 4.2 && < 5,
219     containers,
220     criterion >= 0.4.0 && < 1.3,
221     deepseq >= 1.1.0.0 && < 1.5,
222     ghc-prim
223
224 benchmark lookupge-map
225   type: exitcode-stdio-1.0
226   hs-source-dirs: benchmarks/LookupGE, .
227   main-is: Map.hs
228   other-modules:
229       Data.Map
230       Data.Map.Internal.Debug
231       Data.Map.Internal.DeprecatedShowTree
232       Data.Map.Lazy
233       Data.Map.Strict
234       Data.Map.Strict.Internal
235       Data.Set.Internal
236       LookupGE_Map
237       Utils.Containers.Internal.BitQueue
238       Utils.Containers.Internal.BitUtil
239       Utils.Containers.Internal.PtrEquality
240       Utils.Containers.Internal.StrictFold
241       Utils.Containers.Internal.StrictMaybe
242       Utils.Containers.Internal.StrictPair
243   ghc-options: -O2
244   cpp-options: -DTESTING
245   other-modules:
246     Data.Map.Internal
247   build-depends:
248     base >= 4.2 && < 5,
249     containers,
250     criterion >= 0.4.0 && < 1.3,
251     deepseq >= 1.1.0.0 && < 1.5,
252     ghc-prim
253
254 -------------------
255 -- T E S T I N G --
256 -------------------
257
258 -- Every test-suite contains the build-depends and options of the library,
259 -- plus the testing stuff.
260
261 Test-suite map-lazy-properties
262     hs-source-dirs: tests, .
263     main-is: map-properties.hs
264     other-modules:
265         Data.Map.Internal
266         Data.Map.Internal.Debug
267         Data.Map.Internal.DeprecatedShowTree
268         Data.Map.Lazy
269         Data.Map.Merge.Lazy
270         Data.Set
271         Data.Set.Internal
272         Utils.Containers.Internal.BitQueue
273         Utils.Containers.Internal.BitUtil
274         Utils.Containers.Internal.PtrEquality
275         Utils.Containers.Internal.StrictFold
276         Utils.Containers.Internal.StrictMaybe
277         Utils.Containers.Internal.StrictPair
278     type: exitcode-stdio-1.0
279     cpp-options: -DTESTING
280
281     build-depends: base >= 4.3 && < 5, array, deepseq >= 1.2 && < 1.5, ghc-prim
282     ghc-options: -O2
283     other-extensions: CPP, BangPatterns
284     include-dirs: include
285
286     build-depends:
287         HUnit,
288         QuickCheck >= 2.7.1,
289         test-framework,
290         test-framework-hunit,
291         test-framework-quickcheck2,
292         transformers
293
294 Test-suite map-strict-properties
295     hs-source-dirs: tests, .
296     main-is: map-properties.hs
297     other-modules:
298         Data.Map.Internal
299         Data.Map.Internal.Debug
300         Data.Map.Internal.DeprecatedShowTree
301         Data.Map.Merge.Strict
302         Data.Map.Strict
303         Data.Map.Strict.Internal
304         Data.Set
305         Data.Set.Internal
306         Utils.Containers.Internal.BitQueue
307         Utils.Containers.Internal.BitUtil
308         Utils.Containers.Internal.PtrEquality
309         Utils.Containers.Internal.StrictFold
310         Utils.Containers.Internal.StrictMaybe
311         Utils.Containers.Internal.StrictPair
312     type: exitcode-stdio-1.0
313     cpp-options: -DTESTING -DSTRICT
314
315     build-depends: base >= 4.3 && < 5, array, deepseq >= 1.2 && < 1.5, ghc-prim
316     ghc-options: -O2
317     other-extensions: CPP, BangPatterns
318     include-dirs: include
319
320     build-depends:
321         HUnit,
322         QuickCheck >= 2.7.1,
323         test-framework,
324         test-framework-hunit,
325         test-framework-quickcheck2,
326         transformers
327
328 Test-suite bitqueue-properties
329     hs-source-dirs: tests, .
330     main-is: bitqueue-properties.hs
331     other-modules:
332         Utils.Containers.Internal.BitQueue
333         Utils.Containers.Internal.BitUtil
334     type: exitcode-stdio-1.0
335     cpp-options: -DTESTING
336
337     build-depends: base >= 4.3 && < 5, ghc-prim
338     ghc-options: -O2
339     other-extensions: CPP, BangPatterns
340     include-dirs: include
341
342     build-depends:
343         QuickCheck >= 2.7.1,
344         test-framework,
345         test-framework-quickcheck2
346
347 Test-suite set-properties
348     hs-source-dirs: tests, .
349     main-is: set-properties.hs
350     other-modules:
351         Data.IntSet
352         Data.IntSet.Internal
353         Data.Set
354         Data.Set.Internal
355         Utils.Containers.Internal.BitUtil
356         Utils.Containers.Internal.PtrEquality
357         Utils.Containers.Internal.StrictFold
358         Utils.Containers.Internal.StrictPair
359     type: exitcode-stdio-1.0
360     cpp-options: -DTESTING
361
362     build-depends: base >= 4.3 && < 5, array, deepseq >= 1.2 && < 1.5, ghc-prim
363     ghc-options: -O2
364     other-extensions: CPP, BangPatterns
365     include-dirs: include
366
367     build-depends:
368         HUnit,
369         QuickCheck >= 2.7.1,
370         test-framework,
371         test-framework-hunit,
372         test-framework-quickcheck2,
373         transformers
374
375 Test-suite intmap-lazy-properties
376     hs-source-dirs: tests, .
377     main-is: intmap-properties.hs
378     other-modules:
379         Data.IntMap.Internal
380         Data.IntMap.Internal.Debug
381         Data.IntMap.Internal.DeprecatedDebug
382         Data.IntMap.Lazy
383         Data.IntSet
384         Data.IntSet.Internal
385         IntMapValidity
386         Utils.Containers.Internal.BitUtil
387         Utils.Containers.Internal.StrictFold
388         Utils.Containers.Internal.StrictPair
389     type: exitcode-stdio-1.0
390     cpp-options: -DTESTING
391
392     build-depends: base >= 4.3 && < 5, array, deepseq >= 1.2 && < 1.5, ghc-prim
393     ghc-options: -O2
394     other-extensions: CPP, BangPatterns
395     include-dirs: include
396
397     build-depends:
398         HUnit,
399         QuickCheck >= 2.7.1,
400         test-framework,
401         test-framework-hunit,
402         test-framework-quickcheck2
403
404 Test-suite intmap-strict-properties
405     hs-source-dirs: tests, .
406     main-is: intmap-properties.hs
407     other-modules:
408         Data.IntMap.Internal
409         Data.IntMap.Internal.Debug
410         Data.IntMap.Internal.DeprecatedDebug
411         Data.IntMap.Strict
412         Data.IntSet
413         Data.IntSet.Internal
414         IntMapValidity
415         Utils.Containers.Internal.BitUtil
416         Utils.Containers.Internal.StrictFold
417         Utils.Containers.Internal.StrictPair
418     type: exitcode-stdio-1.0
419     cpp-options: -DTESTING -DSTRICT
420
421     build-depends: base >= 4.3 && < 5, array, deepseq >= 1.2 && < 1.5, ghc-prim
422     ghc-options: -O2
423     other-extensions: CPP, BangPatterns
424     include-dirs: include
425
426     build-depends:
427         HUnit,
428         QuickCheck >= 2.7.1,
429         test-framework,
430         test-framework-hunit,
431         test-framework-quickcheck2
432
433 Test-suite intset-properties
434     hs-source-dirs: tests, .
435     main-is: intset-properties.hs
436     other-modules:
437         Data.IntSet
438         Data.IntSet.Internal
439         Data.Set
440         Data.Set.Internal
441         IntSetValidity
442         Utils.Containers.Internal.BitUtil
443         Utils.Containers.Internal.PtrEquality
444         Utils.Containers.Internal.StrictFold
445         Utils.Containers.Internal.StrictPair
446     type: exitcode-stdio-1.0
447     cpp-options: -DTESTING
448
449     build-depends: base >= 4.3 && < 5, array, deepseq >= 1.2 && < 1.5, ghc-prim
450     ghc-options: -O2
451     other-extensions: CPP, BangPatterns
452     include-dirs: include
453
454     build-depends:
455         HUnit,
456         QuickCheck >= 2.7.1,
457         test-framework,
458         test-framework-hunit,
459         test-framework-quickcheck2
460
461 Test-suite deprecated-properties
462     hs-source-dirs: tests, .
463     main-is: deprecated-properties.hs
464     other-modules:
465         Data.IntMap
466         Data.IntMap.Internal
467         Data.IntMap.Internal.DeprecatedDebug
468         Data.IntMap.Lazy
469         Data.IntMap.Strict
470         Data.IntSet.Internal
471         Data.Map
472         Data.Map.Internal
473         Data.Map.Internal.Debug
474         Data.Map.Internal.DeprecatedShowTree
475         Data.Map.Lazy
476         Data.Map.Strict
477         Data.Map.Strict.Internal
478         Data.Set.Internal
479         Utils.Containers.Internal.BitQueue
480         Utils.Containers.Internal.BitUtil
481         Utils.Containers.Internal.PtrEquality
482         Utils.Containers.Internal.StrictFold
483         Utils.Containers.Internal.StrictMaybe
484         Utils.Containers.Internal.StrictPair
485     type: exitcode-stdio-1.0
486     cpp-options: -DTESTING
487
488     build-depends: base >= 4.3 && < 5, array, deepseq >= 1.2 && < 1.5, ghc-prim
489     ghc-options: -O2
490     other-extensions: CPP, BangPatterns
491     include-dirs: include
492
493     build-depends:
494         QuickCheck >= 2.7.1,
495         test-framework,
496         test-framework-quickcheck2
497
498 Test-suite seq-properties
499     hs-source-dirs: tests, .
500     main-is: seq-properties.hs
501     other-modules:
502         Data.Sequence
503         Data.Sequence.Internal
504         Utils.Containers.Internal.StrictPair
505     type: exitcode-stdio-1.0
506     cpp-options: -DTESTING
507
508     build-depends: base >= 4.3 && < 5, array, deepseq >= 1.2 && < 1.5, ghc-prim
509     ghc-options: -O2
510     other-extensions: CPP, BangPatterns
511     include-dirs: include
512
513     build-depends:
514         QuickCheck >= 2.7.1,
515         test-framework,
516         test-framework-quickcheck2,
517         transformers
518
519 Test-suite tree-properties
520     hs-source-dirs: tests, .
521     main-is: tree-properties.hs
522     other-modules:
523         Data.Tree
524     type: exitcode-stdio-1.0
525     cpp-options: -DTESTING
526
527     build-depends: base >= 4.3 && < 5, array, deepseq >= 1.2 && < 1.5, ghc-prim
528     ghc-options: -O2
529     other-extensions: CPP, BangPatterns
530     include-dirs: include
531
532     build-depends:
533         QuickCheck >= 2.7.1,
534         test-framework,
535         test-framework-quickcheck2,
536         transformers
537
538 test-suite map-strictness-properties
539   hs-source-dirs: tests, .
540   main-is: map-strictness.hs
541   other-modules:
542       Data.Map.Internal
543       Data.Map.Internal.Debug
544       Data.Map.Internal.DeprecatedShowTree
545       Data.Map.Strict
546       Data.Map.Strict.Internal
547       Data.Set.Internal
548       Utils.Containers.Internal.BitQueue
549       Utils.Containers.Internal.BitUtil
550       Utils.Containers.Internal.PtrEquality
551       Utils.Containers.Internal.StrictFold
552       Utils.Containers.Internal.StrictMaybe
553       Utils.Containers.Internal.StrictPair
554   type: exitcode-stdio-1.0
555
556   build-depends:
557     array,
558     base >= 4.3 && < 5,
559     ChasingBottoms,
560     deepseq >= 1.2 && < 1.5,
561     QuickCheck >= 2.7.1,
562     ghc-prim,
563     test-framework >= 0.3.3,
564     test-framework-quickcheck2 >= 0.2.9
565
566   ghc-options: -Wall
567   other-extensions: CPP, BangPatterns
568   include-dirs: include
569
570 test-suite intmap-strictness-properties
571   hs-source-dirs: tests, .
572   main-is: intmap-strictness.hs
573   other-modules:
574       Data.IntMap.Internal
575       Data.IntMap.Internal.DeprecatedDebug
576       Data.IntMap.Strict
577       Data.IntSet.Internal
578       Utils.Containers.Internal.BitUtil
579       Utils.Containers.Internal.StrictFold
580       Utils.Containers.Internal.StrictPair
581   type: exitcode-stdio-1.0
582   other-extensions: CPP, BangPatterns
583
584   build-depends:
585     array,
586     base >= 4.3 && < 5,
587     ChasingBottoms,
588     deepseq >= 1.2 && < 1.5,
589     QuickCheck >= 2.7.1,
590     ghc-prim,
591     test-framework >= 0.3.3,
592     test-framework-quickcheck2 >= 0.2.9
593
594   ghc-options: -Wall
595   include-dirs: include
596
597 test-suite intset-strictness-properties
598   hs-source-dirs: tests, .
599   main-is: intset-strictness.hs
600   other-modules:
601       Data.IntSet
602       Data.IntSet.Internal
603       Utils.Containers.Internal.BitUtil
604       Utils.Containers.Internal.StrictFold
605       Utils.Containers.Internal.StrictPair
606   type: exitcode-stdio-1.0
607   other-extensions: CPP, BangPatterns
608
609   build-depends:
610     array,
611     base >= 4.3 && < 5,
612     ChasingBottoms,
613     deepseq >= 1.2 && < 1.5,
614     QuickCheck >= 2.7.1,
615     ghc-prim,
616     test-framework >= 0.3.3,
617     test-framework-quickcheck2 >= 0.2.9
618
619   ghc-options: -Wall
620   include-dirs: include