0

I'm trying to use the function extract defined in Development.Shake.FilePattern but it's hidden. Why? It's not used internally either from what I can gather.

$ ghci
GHCi, version 7.6.3: http://www.haskell.org/ghc/  :? for help
Loading package ghc-prim ... linking ... done.
Loading package integer-gmp ... linking ... done.
Loading package base ... linking ... done.
Prelude> import Development.Shake.FilePattern

<no location info>: 
    Could not find module `Development.Shake.FilePattern'
    it is a hidden module in the package `shake-0.15.10'
Prelude> 

extract would be really handy. Currently I have to resort to custom string manipulations instead.

1 Answer 1

1

extract is used internally to implement the user-visible &%> function.

Shake deliberately tries to avoid leaking internal implementation details - for example it contains a thread-pool implementation, which it keeps quiet. That said, clearly FilePattern are useful, so:

  • Since Shake v0.16 there is a function filePattern, which does what is requested above.
  • The FilePattern functionality in Shake has been released as the filepattern library, which Shake will use for all its functionality.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.