Comments (4)
I am closing this as duplicate of #1270.
from agda.
Yes, that's why we have a termination checker. But it does not run until the mutual block is complete. Your example opens an implicit mutual block with the data signature Flip'
which is only closed until the data definition Flip'
is provided.
Workaround is to use the {-# NON_TERMINATING #-}
pragma (insert before Flip
). This stops Flip
from being unfolded.
from agda.
Ah, so this is the intended (unavoidable) behavior? Are definitions lifted out of mutual blocks if there isn't an actual dependency? Because the following terminates just fine:
data Unit : Set where
data Flip' (x : Unit) : (y : Unit) -> Set
Flip : Unit -> Unit -> Set
Flip x y = Flip y x
data Flip' a where
EDIT: Nevermind, we don't use Flip
here so when the termination checker runs, it doesn't get stuck trying to evaluate Flip
since it's never used.
from agda.
Ah, so this is the intended (unavoidable) behavior?
Yes, somewhat unfortunately it is hard to fix:
Are definitions lifted out of mutual blocks if there isn't an actual dependency?
They formally stay in the mutual block, but the termination checker computes the actual dependencies.
Because the following terminates just fine:
Yes here you get the expected termination error for Flip
.
from agda.
Related Issues (20)
- Citation.cff HOT 1
- Prune the `Makefile` HOT 7
- Delete the GitHub Wiki HOT 3
- Migrate the Chalmers Wiki HOT 4
- Prune `Setup.hs` HOT 5
- Reorganize `HACKING.md`
- Merge `.authorspellings` and `.mailmap` HOT 1
- Mimer internal error when querying `recRecursive` HOT 1
- Interactive highlighting remnants with lambda-where
- Pattern synonyms with named arguments can be defined but not used HOT 3
- Automatically create names for syntax
- Mangled trX/Con clause for indexed type with green slime
- Why do we `reduce` and `instantiateFull` constraints? HOT 2
- Misprinted domain-free parameters with cohesion attribute HOT 1
- Regression in 2.6.4.2 concerning `with` HOT 6
- Regression in 2.6.4 in `rewrite` with instances
- Feature request: Allow for overloading function application (the 'whitespace' operator) HOT 3
- Future: cabal build-type `Setup` will be phased out in favor of `Hooks`
- Non-sensical error since 2.5.4 when applying a non-function HOT 5
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 agda.