Comments (2)
Another approach is McBride universe, which is introducing a lift operator ^
. When we need a corresponding type level, use ^
to get a proper inference.
(def (map {i @ Level}
{A B : Type i}
[l : (List A)]
[f : A -> B])
: (List B)
[nil nil]
[(cons head l) (cons (f head) (map l f))])
Here, I use @
to notate Level
since Level
is not a type. When we are using map
with i
and i+1
expressions, use ^map
to handle i+1
expression.
from k.
Based on HoTT's idea
(def (is-prop {i @ Level} [A : Type i])
: Type i
(x y : A) -> x = y)
(def (×-is-prop {i j @ Level}
{A : Type i}
{B : Type j}
[PA : is-prop A]
[PB : is-prop B])
: is-prop (A × B)
...)
(def (∧ {i j @ Level}
[A : Type i]
[B : Type j])
: Type (lmax i j)
A × B)
from k.
Related Issues (20)
- simpler index type HOT 1
- path
- unknown reason crashed on pkgs.racket-lang.org HOT 1
- covering check
- turn to multi-collection project
- Real
- implement pi type correctly HOT 5
- bug(`Nat=?` cannot type check now)
- nested pattern won't work currently
- postulate definition for later reuse it in `data`
- improve pattern transformation HOT 1
- try merge `#:postulate` and `#:constructor`
- redundant `begin`
- Bad type should work without strict positivity
- Abbreviation for `Pi`
- without-K
- Observational equality
- Quantitative type theory
- Fix implicit definition's expansion HOT 1
- Show test coverage badge with cover-badge 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 k.