Skip to content

Commit

Permalink
Add dumpcore flag
Browse files Browse the repository at this point in the history
  • Loading branch information
ChrisPenner committed Dec 2, 2024
1 parent 91b6405 commit b04aa8b
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 1 deletion.
6 changes: 5 additions & 1 deletion unison-runtime/package.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,13 +11,17 @@ flags:
stackchecks:
manual: true
default: false
dumpcore:
manual: true
default: false

when:
- condition: flag(arraychecks)
cpp-options: -DARRAY_CHECK
- condition: flag(stackchecks)
cpp-options: -DSTACK_CHECK

- condition: flag(dumpcore)
ghc-options: -ddump-simpl -ddump-stg-final -ddump-to-file -dsuppress-coercions -dsuppress-idinfo -dsuppress-module-prefixes # -dsuppress-type-applications -dsuppress-type-signatures

library:
source-dirs: src
Expand Down
8 changes: 8 additions & 0 deletions unison-runtime/unison-runtime.cabal
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,10 @@ flag arraychecks
manual: True
default: False

flag dumpcore
manual: True
default: False

flag stackchecks
manual: True
default: False
Expand Down Expand Up @@ -142,6 +146,8 @@ library
cpp-options: -DARRAY_CHECK
if flag(stackchecks)
cpp-options: -DSTACK_CHECK
if flag(dumpcore)
ghc-options: -ddump-simpl -ddump-stg-final -ddump-to-file -dsuppress-coercions -dsuppress-idinfo -dsuppress-module-prefixes

test-suite runtime-tests
type: exitcode-stdio-1.0
Expand Down Expand Up @@ -221,3 +227,5 @@ test-suite runtime-tests
cpp-options: -DARRAY_CHECK
if flag(stackchecks)
cpp-options: -DSTACK_CHECK
if flag(dumpcore)
ghc-options: -ddump-simpl -ddump-stg-final -ddump-to-file -dsuppress-coercions -dsuppress-idinfo -dsuppress-module-prefixes

0 comments on commit b04aa8b

Please sign in to comment.