Comments (6)
If we specify other-extensions: UnboxedTuples
, than cabal-doctest
can detect that.
Alternatively, is there a reason not to use -fobject-code
always?
from cabal-doctest.
If we specify
other-extensions: UnboxedTuples
, thancabal-doctest
can detect that.
Ah, interesting idea.
Alternatively, is there a reason not to use
-fobject-code
always?
I don't think we'd want to do this, since we'd be significantly increasing the time it takes for doctest
to process each file, since it now has to compile each one. And in the end, doctest
would (IIRC) still run the tests themselves in interpreted mode, so I don't think you'd even get any performance benefits from using object code.
from cabal-doctest.
I see, slowing doctest
is quite bad, they are slow to begin with.
I can take a look on structs
tomorrow.
from cabal-doctest.
I think we have to use -fobject-code in this case, as we can't construct 'foo' from ghci, no?
from cabal-doctest.
This is how I've had to work around this in the past anyways. We're asking doctest to build in a very different manner to support a feature that isn't available to the bytecode compiler. It seems reasonable to have to ask.
from cabal-doctest.
I think we have to use -fobject-code in this case, as we can't construct 'foo' from ghci, no?
Certainly. The question is: what is the best way to inform cabal-doctest
that -fobject-code
should be used in this specific instance? Currently, we have to hack it in to doctests.hs
directly, but we're moving towards being able to specify x-doctest-options: -fobject-code
in structs.cabal
soon.
from cabal-doctest.
Related Issues (20)
- Make a release HOT 3
- Build_doctests isn't generated unless Cabal file defines a library HOT 8
- Should use doctest's --no-magic to stop it from interfering HOT 3
- running cabal-doctest on code that does FFI HOT 7
- Failure with GHC 8.8 / Cabal 2.5 HOT 8
- Add a motivation for this library to readme.
- Getting can't find soure for Build_doctests error. HOT 12
- Build error with GHC-8.8.1 HOT 2
- Work better with Haskell.nix? HOT 2
- Deprecation plan HOT 1
- Consider generating `Build_*` modules for more than just test-suite targets HOT 3
- cabal install <packages> fails with "Could not find module ‘Distribution.Extra.Doctest’" HOT 2
- Readme and description mention closed issue HOT 1
- Dyplicate symbol definition failure HOT 3
- Add constraint `Cabal >=1.24` to example in README HOT 2
- Support for mixins HOT 6
- "Attempting to use module .. which is not loaded" error HOT 4
- Build failure with GHC 9.2 alpha-2 HOT 8
- Publish a version that accepts Cabal 3.6 HOT 3
- Dropping maintenance, takeovers welcome HOT 12
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from cabal-doctest.