Comments (6)
Does not check for me as well:
I'm investigating.
from minitt-rs.
I've found the problem. It's because when I'm generating a Val
to instantiate the pi type's closure:
Line 247 in 2dcae72
When generating an instance of
One
, we're still "generating" a variable (instead of using the only possible instance Unit
).
Same problem also occurs in:
Line 103 in 2dcae72
Line 113 in 2dcae72
from minitt-rs.
It checks in my implementation now:
minitt-rs/samples/sum-split/bool.minitt
Lines 21 to 31 in f35f6b6
from minitt-rs.
Your fix is smart!
- But why it is enough to only do it for Unit ?
- Is it also right (or sound) to use unification to compare
readback
ed norm exps?
from minitt-rs.
But why it is enough to only do it for Unit ?
'cus in Mini-TT your Sum { True | False }
are desugared to Sum { True 1 | False 1 }
, note the 1
.
from minitt-rs.
Is it also right (or sound) to use unification to compare readbacked norm exps?
It is, but not necessary. Theoretically, we're supposed to eject beta-normal eta-long normal forms. By eta-long I mean terms like (\ x -> x) : Record { label: Ty } -> Record { label: Ty }
are translated to (\ { label } -> { label })
, in case the record is empty it becomes \ {} -> {}
. The readback function in Mini-TT is not aware of the eta-long property.
from minitt-rs.
Related Issues (20)
- Backend framework
- Generalized algebraic data types (indexed inductive families) HOT 22
- The ability to attach builtin definitions (like Agda BUILTIN pragma
- Sum/Pi/Sigma with levels?
- Merge two sums HOT 1
- Improve `split` pretty printer
- Sum's each branch should have its own telescope
- Universe polymorphism HOT 1
- Entering empty expressions in REPL mode should not trigger parsing
- Use KaTeX in rustdoc HOT 1
- Create `minitt-util` HOT 1
- Try apply `id` to `id` HOT 2
- Infer type of constructor call as a "minimum sum"
- `const` parser
- Default placeholder for constructor parameter/pattern
- Subtyping check on sum types
- Type universe and (possibly) universal subtyping HOT 9
- Positivity check for sum types
- Termination check (structural induction) HOT 2
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 minitt-rs.