text stringlengths 4 690k |
|---|
module Generic.Lib.Reflection.Core where
open import Agda.Builtin.Reflection using (withNormalisation; Relevance; Visibility; clause) public
open import Reflection
renaming (visible to expl; hidden to impl; instance′ to inst;
relevant to rel; irrelevant to irr; pi to absPi; lam to absLam; def to appDef)
hiding... |
{-# OPTIONS --cubical --no-import-sorts --safe #-}
module Cubical.Data.DiffInt where
open import Cubical.Data.DiffInt.Base public
open import Cubical.Data.DiffInt.Properties public
|
{-# OPTIONS --without-K --safe #-}
module Categories.Category.Instance.Globe where
open import Level using (Level; zero)
open import Relation.Binary using (IsEquivalence; module IsEquivalence)
open import Relation.Binary.PropositionalEquality using (isEquivalence)
open import Data.Nat using (ℕ; zero; suc; _<_; _≤_; z≤... |
{-# OPTIONS --prop --rewriting #-}
open import Examples.Sorting.Sequential.Comparable
module Examples.Sorting.Sequential.MergeSort.Split (M : Comparable) where
open Comparable M
open import Examples.Sorting.Sequential.Core M
open import Calf costMonoid
open import Calf.Types.Nat
open import Calf.Types.List
open imp... |
{-# OPTIONS --cubical --safe #-}
module Cubical.Data.Group where
open import Cubical.Data.Group.Base public
|
{-# OPTIONS --without-K --rewriting #-}
open import lib.Basics
open import lib.types.Group
open import lib.types.Pi
open import lib.NType2
open import lib.types.EilenbergMacLane1.Core
module lib.types.EilenbergMacLane1.DoubleElim where
private
emloop-emloop-helper : ∀ {i j k} {A : Type i} {B : Type j} {C : A → B ... |
------------------------------------------------------------------------
-- The Agda standard library
--
-- Results concerning double negation elimination.
------------------------------------------------------------------------
{-# OPTIONS --without-K --safe #-}
module Axiom.DoubleNegationElimination where
open imp... |
------------------------------------------------------------------------------
-- Group theory base
------------------------------------------------------------------------------
{-# OPTIONS --exact-split #-}
{-# OPTIONS --no-sized-types #-}
{-# OPTIONS --no-universe-polymorphism #-}
{-# OPTIONS... |
module ProcessAlgebra where
open import Data.Nat
open import Data.Nat.Properties
open import Data.List
data Channel : Set where
ℂ_ : ℕ → Channel
data ℙ : Set₁ where
ν_[_] : List Channel → (Channel → ℙ) → ℙ
B_,_ : Channel → ℙ → ℙ
Send_[_],_ : ∀ {A : Set} → Channel → A → ℙ → ℙ
Recv_,_ : ∀ {A : Set} → Channel... |
-- Andreas, 2018-06-10, issue #3124
-- Wrong context for error IrrelevantDatatype in the coverage checker.
data Squash (A : Set) : Prop where
squash : A → Squash A
test : ∀{A} → Squash (Squash A → A)
test = squash λ{ (squash y) → y }
-- WAS: de Bruijn index in error message
-- Expected error:
-- Cannot split on a... |
module Categories.Topos where
|
{-# OPTIONS --universe-polymorphism #-}
module NoBlockOnLevel where
open import Common.Level
infixr 0 _,_
record ∃ {a b} {A : Set a} (B : A → Set b) : Set (a ⊔ b) where
constructor _,_
field
proj₁ : A
proj₂ : B proj₁
open ∃
BSetoid : ∀ c → Set (lsuc c)
BSetoid c = Set c
infixr 0 _⟶_
postulate
_⟶_ : ... |
-- Andreas, 2017-01-01, issue #2372, reported by m0davis
-- {-# OPTIONS -v tc.def.alias:100 -v tc.decl.instance:100 #-}
-- Expected error:
-- Terms marked as eligible for instance search should end with a name
-- when checking the definition of i
postulate
D : Set
instance
i = D -- NOW: Error given here (as ex... |
-- {-# OPTIONS -v tc.conv:10 #-}
-- 2013-11-03 Reported by sanzhiyan
module Issue933 where
record RGraph : Set₁ where
field
O : Set
R : Set
refl : O -> R
module Families (Γ : RGraph) where
module Γ = RGraph Γ
record RG-Fam : Set₁ where
field
O : Γ.O -> Set
refl : ∀ {γo} -> (o : O γo) → O... |
{-# OPTIONS --rewriting #-}
module Luau.StrictMode.ToString where
open import FFI.Data.String using (String; _++_)
open import Luau.StrictMode using (Warningᴱ; Warningᴮ; UnallocatedAddress; UnboundVariable; FunctionCallMismatch; FunctionDefnMismatch; BlockMismatch; app₁; app₂; BinOpMismatch₁; BinOpMismatch₂; bin₁; bi... |
{-
This second-order term syntax was created from the following second-order syntax description:
syntax CommGroup | CG
type
* : 0-ary
term
unit : * | ε
add : * * -> * | _⊕_ l20
neg : * -> * | ⊖_ r40
theory
(εU⊕ᴸ) a |> add (unit, a) = a
(εU⊕ᴿ) a |> add (a, unit) = a
(⊕A) a b c |> add (add(a, b),... |
module Categories.Normalise where
-- Experiments on using computation to simplify equalities
open import Level
open import Function renaming (id to idᶠ; _∘_ to _©_)
open import Data.Product
open import Categories.Support.PropositionalEquality
open import Categories.Category
import Categories.Morphisms as Mor
open i... |
-- The bug appeared since I forgot to keep the constraint when trying to unify
-- a blocked term (I just didn't instantiate).
module LostConstraint where
infixr 10 _==>_ _=>_
data Setoid : Set1 where
setoid : Set -> Setoid
El : Setoid -> Set
El (setoid A) = A
eq : (A : Setoid) -> El A -> El A -> Set
... |
{-# OPTIONS --universe-polymorphism #-}
module Categories.Functor.Diagonal where
open import Data.Product
open import Categories.Category
open import Categories.Functor
open import Categories.Product
open import Categories.FunctorCategory
open import Categories.Functor.Constant
import Categories.Power as Power
Δ : ... |
record R : Set₁ where
field
A : Set
B : Set
B = A
field
C : Set
D : Set
D = A → B → C
|
module Extended.FunRetRec where
open import Function
open import Data.Nat
open import Data.Nat.Properties.Simple
open import Relation.Binary.PropositionalEquality hiding ([_])
open import Data.String
open import Data.Product
open import Data.Bool renaming (not to bnot) hiding (if_then_else_)
open import Relation.Nul... |
-- We define ZigZag-complete relations and prove that quasi equivalence relations
-- give rise to equivalences on the set quotients.
{-# OPTIONS --cubical --no-import-sorts --safe #-}
module Cubical.Relation.ZigZag.Base where
open import Cubical.Core.Everything
open import Cubical.Foundations.Prelude
open import Cubic... |
module Numeral.Natural.Sequence.Proofs where
import Lvl
open import Data
open import Data.Either as Either using (_‖_)
open import Data.Either.Equiv as Either
open import Data.Either.Equiv.Id
open import Data.Either.Proofs as Either
open import Data.Tuple as Tuple using (_⨯_ ; _,_)
open import Data.Tuple.Equiv as... |
module Issue347 where
import Common.Irrelevance
{- Dan Doel, 2010-10-09
This is a boiling down of a problem encountered by Eric Mertens. It
seems the unifier will make up values for records without bothering
with irrelevant fields: -}
data ⊥ : Set where
⊥-elim : {A : Set} → ⊥ → A
⊥-elim ()
⊥-elimⁱ : {A : Set} → .⊥... |
data ⊤ : Set where
t : ⊤
data ⊤⊤ : Set where
tt : ⊤⊤
module M (x : ⊤⊤) where
instance
top : ⊤
top = t
search : ∀ {ℓ} {t : Set ℓ} {{_ : t}} → t
search {{p}} = p
-- no instance is in scope, and none is found
-- correct : ⊤
-- correct = search
someDef : ⊤
someDef = top
where
open M tt
-- incorr... |
module IsLiteralSequent where
open import OscarPrelude
open import Sequent
open import IsLiteralFormula
record IsLiteralSequent (Φ : Sequent) : Set
where
constructor _╱_
field
isLiteralStatement : IsLiteralFormula (statement Φ)
isLiteralSuppositions : All IsLiteralFormula (suppositions Φ)
open IsLitera... |
------------------------------------------------------------------------------
-- Totality properties respect to OrdTree
------------------------------------------------------------------------------
{-# OPTIONS --exact-split #-}
{-# OPTIONS --no-sized-types #-}
{-# OPTIONS --no-universe-polymor... |
{-# OPTIONS --universe-polymorphism #-}
module Categories.Functor.Equivalence.Strong where
open import Level
open import Relation.Binary using (IsEquivalence)
open import Relation.Nullary using (¬_)
open import Data.Product using (Σ; ∃; _,_; proj₁; proj₂)
open import Function using () renaming (_∘_ to _∙_)
open impor... |
{-# OPTIONS --cubical --no-import-sorts --safe #-}
module Cubical.HITs.Sn.Properties where
open import Cubical.Data.Int hiding (_+_)
open import Cubical.Data.Bool
open import Cubical.Foundations.Pointed
open import Cubical.Foundations.Function
open import Cubical.Foundations.Equiv
open import Cubical.Foundations.HLeve... |
record SemiRing : Set1 where
field
R : Set
_+_ : R -> R -> R
zero : R
_*_ : R -> R -> R
one : R
module Vectors (S : SemiRing) where
open SemiRing S
open import Data.Nat renaming (ℕ to Nat; zero to z; _*_ to times; _+_ to plus)
open import Data.Fin renaming (zero to z) hiding (_+_)
... |
module BBHeap.DropLast {A : Set}(_≤_ : A → A → Set) where
open import BBHeap _≤_
open import BBHeap.Compound _≤_
open import BBHeap.Properties _≤_
open import Bound.Lower A
open import Bound.Lower.Order _≤_
open import Data.Empty
open import Data.Sum renaming (_⊎_ to _∨_)
mutual
dropLast : {b : Bound} → BBHeap b →... |
module Data.Bin.Props where
open import Data.Bin
import Data.Nat
import Data.Nat.Properties
open Data.Nat using (ℕ)
open import Data.List
open import Relation.Binary.PropositionalEquality
open import Function using (_⟨_⟩_)
open import Algebra.Structures using (IsCommutativeMonoid; module IsCommutativeM... |
import cedille-options
open import general-util
module classify (options : cedille-options.options) {mF : Set → Set} {{_ : monad mF}} where
open import lib
open import cedille-types
open import constants
open import conversion
open import ctxt
open import is-free
open import lift
open import rename
open import rewrit... |
open import Relation.Binary.Core
module Heapsort.Impl2 {A : Set}
(_≤_ : A → A → Set)
(tot≤ : Total _≤_)
(trans≤ : Transitive _≤_) where
open import BBHeap _≤_ hiding (flatten)
open import BBHeap.Compound _≤_
open import BBHeap.Drop _≤_ tot≤ trans≤
open import BB... |
------------------------------------------------------------------------------
-- Equality reasoning on axiomatic PA
------------------------------------------------------------------------------
{-# OPTIONS --exact-split #-}
{-# OPTIONS --no-sized-types #-}
{-# OPTIONS --no-universe-polymorphis... |
module MJ.Examples.Integer where
open import Prelude
open import Data.Maybe
open import Data.Vec
import Data.Vec.All as Vec∀
open import Data.Star
open import Data.Bool
open import Data.List
open import Data.List.Any
open import Data.List.Membership.Propositional
open import Data.List.All hiding (lookup)
open import D... |
{-# OPTIONS --sized-types #-}
module SBList.Properties {A : Set}(_≤_ : A → A → Set) where
open import Data.List
open import List.Permutation.Base A
open import SBList _≤_
lemma-unbound-bound : (xs : List A) → xs ∼ unbound (bound xs)
lemma-unbound-bound [] = ∼[]
lemma-unbound-bound (x ∷ xs) = ∼x /head /head (lemma-u... |
------------------------------------------------------------------------
-- The Agda standard library
--
-- Lexicographic products of binary relations
------------------------------------------------------------------------
-- The definition of lexicographic product used here is suitable if
-- the left-hand relation i... |
data _×_ (A B : Set) : Set where
_,_ : A → B → A × B
postulate
M : Set → Set
_>>=_ : ∀{A B : Set} → M A → (A → M B) → M B
infixr 1 bind
bind : _
bind = _>>=_
infix 0 id
id : ∀{A : Set} → A → A
id = λ x → x
syntax id x = do x
syntax bind ma (λ x → f) = x ← ma , f
swapM′ : ∀ {A B} → M (A × B) →... |
{-# OPTIONS --cubical --no-import-sorts --allow-unsolved-metas #-}
module Number.Instances.QuoInt where
open import Agda.Primitive renaming (_⊔_ to ℓ-max; lsuc to ℓ-suc; lzero to ℓ-zero)
open import Cubical.Foundations.Everything renaming (_⁻¹ to _⁻¹ᵖ; assoc to ∙-assoc)
open import Cubical.Foundations.Logic renaming ... |
open import Oscar.Prelude
open import Oscar.Data.Maybe
open import Oscar.Class
open import Oscar.Class.Fmap
open import Oscar.Class.Pure
open import Oscar.Class.Apply
open import Oscar.Class.Bind
open import Oscar.Class.IsFunctor
open import Oscar.Class.IsPrefunctor
open import Oscar.Class.IsPrecategory
open import Os... |
{-# OPTIONS --without-K --rewriting #-}
open import HoTT
module homotopy.FiberOfWedgeToProduct {i j} (X : Ptd i) (Y : Ptd j) where
private
X⊙×Y = X ⊙× Y
private
to-glue-template : ∀ {x y}
{p p' : (pt X , pt Y) == (x , y)}
(q : p == p' [ (λ w → ∨-to-× w == (x , y)) ↓ wglue ])
→ jright (... |
{-# OPTIONS --without-K --safe #-}
open import Relation.Binary
module Algorithms.List.Sort.IsSort {c l₁ l₂} (DTO : DecTotalOrder c l₁ l₂) where
-- agda-stdlib
open import Level
import Relation.Binary.Reasoning.Setoid as SetoidReasoning
open import Data.List
import Data.List.Relation.Binary.Equality.Setoid as Se... |
module WithInParModule (A : Set) where
data Nat : Set where
zero : Nat
suc : Nat -> Nat
data Bool : Set where
true : Bool
false : Bool
isZero : Nat -> Bool
isZero zero = true
isZero (suc _) = false
f : Nat -> Nat
f n with isZero n
f n | true = zero
f n | false = suc zero
g : Nat -> Nat
g zero = zero
g (s... |
open import Level using (_⊔_)
open import Function using (_$_)
open import Data.Empty using (⊥)
open import Relation.Nullary using (yes; no)
open import Relation.Nullary.Negation using (contradiction)
open import Relation.Binary using (Rel; Reflexive; Transitive; Antisymmetric; _Respects₂_; _Respectsʳ_; _Respectsˡ_; ... |
------------------------------------------------------------------------
-- A semantics which uses continuation-passing style
------------------------------------------------------------------------
module TotalParserCombinators.Semantics.Continuation where
open import Algebra
open import Codata.Musical.Notation
open... |
open import FRP.JS.Behaviour using ( Beh ; [_] )
open import FRP.JS.DOM using ( DOM ; element ; attr ; text ; _++_ )
open import FRP.JS.RSet using ( ⟦_⟧ )
module FRP.JS.Demo.HRef where
main : ∀ {w} → ⟦ Beh (DOM w) ⟧
main = element ("a")
( attr "href" ["http://bell-labs.com/"] ++
text ["A hyperlink."] )
|
open import Prelude
module Implicits.Resolution.Scala.Terminates where
open import Implicits.Syntax
open import Implicits.Substitutions
open import Implicits.Resolution.Infinite.Algorithm
open import Implicits.Resolution.Scala.Type
open import Category.Monad.Partiality
open import Category.Monad.Partiality as P
ope... |
-- {-# OPTIONS -v term:10 -v tc.pos:10 -v tc.decl:10 #-}
-- Andreas, 2018-02-26, issue #2975
-- Problem history:
--
-- The example below crashed with an internal error.
-- The problem is that the termination checker needs to know
-- whether force is the projection of a recursive coinductive
-- record. However, the po... |
{-# OPTIONS --universe-polymorphism #-}
module Categories.2-Category where
open import Level
open import Data.Product using (curry; _,_)
open import Function using () renaming (_∘_ to _·_)
open import Categories.Support.PropositionalEquality
open import Categories.Category
open import Categories.Categories
open impo... |
{-# OPTIONS --exact-split #-}
{-# OPTIONS --no-sized-types #-}
{-# OPTIONS --no-universe-polymorphism #-}
{-# OPTIONS --without-K #-}
-- Tested with the development version of the Agda standard library on
-- 27 May 2011.
-- Nils' idea about databases in the Agda mailing list.
-- ... |
------------------------------------------------------------------------
-- The Agda standard library
--
-- A categorical view of List⁺
------------------------------------------------------------------------
{-# OPTIONS --without-K --safe #-}
module Data.List.NonEmpty.Categorical where
open import Agda.Builtin.List... |
{-# OPTIONS --safe #-}
module Definition.Conversion.Transitivity where
open import Definition.Untyped
open import Definition.Untyped.Properties
open import Definition.Typed
open import Definition.Typed.Properties
open import Definition.Typed.RedSteps
open import Definition.Conversion
open import Definition.Conversion... |
------------------------------------------------------------------------
-- Mixfix operator grammars, and parsing of mixfix operators
--
-- Nils Anders Danielsson
------------------------------------------------------------------------
module Mixfix where
-- There are two separate developments here. One is very close... |
import Lvl
open import Functional
open import Logic.Propositional{Lvl.𝟎}
open import Logic.Predicate{Lvl.𝟎}{Lvl.𝟎}
open import Logic.Propositional.Theorems{Lvl.𝟎}
open import Relator.Equals{Lvl.𝟎}{Lvl.𝟎} renaming (_≡_ to _≡ₑ_)
open import Type{Lvl.𝟎}
-- Based on https://plato.stanford.edu/entries/set-theor... |
{-# OPTIONS --without-K --safe #-}
module Math.NumberTheory.Product.Generic.Properties where
-- agda-stdlib
open import Algebra
-- agda-misc
open import Math.NumberTheory.Summation.Generic.Properties
-- TODO add renamaings
module CommutativeMonoidProductProperties {c e} (CM : CommutativeMonoid c e) =
CommutativeM... |
-- Andreas, 2015-10-26, issue reported by Wolfram Kahl
-- {-# OPTIONS -v scope.mod.inst:30 -v tc.mod.check:10 -v tc.mod.apply:80 #-}
module _ where
module ModParamsRecord (A : Set) where
record R (B : Set) : Set where
field F : A → B
module ModParamsToLoose (A : Set) where
open ModParamsRecord
... |
{-# OPTIONS --without-K --safe #-}
open import Relation.Binary.Core
module Quasigroup.Definitions
{a ℓ} {A : Set a} -- The underlying set
(_≈_ : Rel A ℓ) -- The underlying equality
where
open import Algebra.Core
open import Data.Product
LatinSquareProperty₁ : Op₂ A → Set _
LatinSquareProperty₁ _*_ = ∀ a... |
{-# OPTIONS --cubical --safe #-}
module Cubical.Data.Universe.Properties where
open import Cubical.Core.Everything
open import Cubical.Foundations.Prelude
open import Cubical.Foundations.Equiv
open import Cubical.Foundations.HLevels
open import Cubical.Foundations.Univalence
isInjectiveTransport : ∀ {ℓ : Level} {A B ... |
{-# OPTIONS --without-K --safe #-}
open import Definition.Typed.EqualityRelation
module Definition.LogicalRelation.Substitution.Reflexivity {{eqrel : EqRelSet}} where
open EqRelSet {{...}}
open import Definition.LogicalRelation.Properties
open import Definition.LogicalRelation.Substitution
open import Tools.Product... |
{-# OPTIONS --safe #-}
module Cubical.Algebra.RingSolver.RawRing where
open import Cubical.Foundations.Prelude
private
variable
ℓ : Level
record RawRing ℓ : Type (ℓ-suc ℓ) where
constructor rawring
field
Carrier : Type ℓ
0r : Carrier
1r : Carrier
_+_ : Carrier → Carrier → Ca... |
module Issue1760f where
-- Skipping a single record definition in an abstract block.
abstract
{-# NO_POSITIVITY_CHECK #-}
record U : Set where
field ap : U → U
|
{-# OPTIONS --verbose=10 #-}
module inorderF where
open import Data.Nat
open import Data.Vec
open import Agda.Builtin.Sigma
open import Data.Product
open import Data.Fin using (fromℕ)
open import trees
open import optics
open import lemmas
inorderTreeF : {A : Set} -> (t : Tree A) -> Vec A (#no... |
open import Common.Prelude
open import Common.Reflection
module TermSplicing1 where
x = unquote (give Set)
|
------------------------------------------------------------------------
-- The Agda standard library
--
-- Some properties related to Data.Star
--
-- This module is DEPRECATED. Please use the
-- Relation.Binary.Construct.Closure.ReflexiveTransitive.Properties
-- module directly.
---------------------------------------... |
------------------------------------------------------------------------------
-- Well-founded induction on the relation _◁_
------------------------------------------------------------------------------
{-# OPTIONS --exact-split #-}
{-# OPTIONS --no-sized-types #-}
{-# OPTIONS --no-universe-pol... |
------------------------------------------------------------------------
-- The Agda standard library
--
-- Lists defined in terms of the reflexive-transitive closure, Star
------------------------------------------------------------------------
{-# OPTIONS --without-K --safe #-}
module Data.Star.List where
open imp... |
module triple where
|
-- Syntactic kits from Conor McBride's
-- "Type-Preserving Renaming and Substitution"
module Syntax.Substitution.Kits where
open import Syntax.Types
open import Syntax.Context
open import Syntax.Terms
open import CategoryTheory.Categories
open import Relation.Binary.PropositionalEquality using (_≡_ ; refl ; sym)
-... |
------------------------------------------------------------------------
-- The Agda standard library
--
-- This module constructs the zero R-module, and similar for weaker
-- module-like structures.
-- The intended universal property is that, given any R-module M, there
-- is a unique map into and a unique map out of ... |
{-# OPTIONS --guardedness #-}
module Stream.Iterable where
open import Data
open import Data.Boolean
open import Functional
open import Logic.Propositional
open import Logic.Predicate
import Lvl
open import Relator.Equals
open import Stream as Stream
open import Structure.Container.Iterable
open import Type
pri... |
open import Mockingbird.Forest using (Forest)
-- To Mock a Mockingbird
module Mockingbird.Problems.Chapter09 {b ℓ} (forest : Forest {b} {ℓ}) where
open import Data.Product using (_,_; proj₁; proj₂; ∃-syntax)
open import Function using (_$_)
open import Level using (_⊔_)
open import Relation.Nullary using (¬_)
open i... |
module Web.URI.Scheme.Primitive where
postulate Scheme? : Set
{-# COMPILED_TYPE Scheme? String #-}
postulate http: : Scheme?
{-# COMPILED http: "http:" #-}
postulate https: : Scheme?
{-# COMPILED https: "https:" #-}
postulate ε : Scheme?
{-# COMPILED ε "" #-}
|
{- Byzantine Fault Tolerant Consensus Verification in Agda, version 0.9.
Copyright (c) 2020, 2021, Oracle and/or its affiliates.
Licensed under the Universal Permissive License v 1.0 as shown at https://opensource.oracle.com/licenses/upl
-}
open import LibraBFT.Prelude
open import LibraBFT.Lemmas
open import Lib... |
{-# OPTIONS --no-positivity-check --no-termination-check #-}
module Homogenous.Base where
-- module Homogenous.Base(Arity, Sig, T, Intro) where
import TYPE
import PolyDepPrelude
open PolyDepPrelude using
( Absurd
; Unit; unit
; Nat; zero; suc
; List; nil; _::_
; Either; left; right
; Pair; pair)
-- A hom... |
{-
This second-order term syntax was created from the following second-order syntax description:
syntax Naturals | Nat
type
N : 0-ary
term
ze : N
su : N -> N
nrec : N α (α,N).α -> α
theory
(zeβ) z : α s : (α,N).α |> nrec (ze, z, r m. s[r,m]) = z
(suβ) z : α s : (α,N).α n : N ... |
module Data.Option.Iterable where
open import Data
open import Data.Option
import Data.Option.Functions as Option
open import Functional
open import Logic.Propositional
open import Logic.Predicate
import Lvl
open import Relator.Equals
open import Structure.Container.Iterable
open import Type
private variabl... |
{-# OPTIONS --safe #-}
open import Definition.Typed.EqualityRelation
module Definition.LogicalRelation.Properties.Conversion {{eqrel : EqRelSet}} where
open EqRelSet {{...}}
open import Definition.Untyped
open import Definition.Typed
open import Definition.Typed.RedSteps
open import Definition.Typed.Reduction
import... |
-- Useless private
module Issue476a where
A : Set₁
private
A = Set
|
-- Andreas, 2015-05-06
module Issue1484 where
data ⊥ : Set where
-- Smörgåsbord of legal absurd lambdas
-- non-hidden
abs esabs eabs eabs2 eabs3 : ⊥ → Set
abs = λ()
esabs = λ{ ()}
eabs = λ{()}
eabs2 = λ{(())}
eabs3 = λ{((()))}
-- hidden
habs eshabs eshpabs eshpabs2 : {_ : ⊥} → Set
habs = λ{}
eshabs = λ{... |
------------------------------------------------------------------------
-- The Agda standard library
--
-- Component functions of permutations found in `Data.Fin.Permutation`
------------------------------------------------------------------------
{-# OPTIONS --without-K --safe #-}
module Data.Fin.Permutation.Compon... |
open import Common.Prelude
instance
tti : ⊤
tti = record{}
NonZero : Nat → Set
NonZero zero = ⊥
NonZero (suc _) = ⊤
pred′ : (n : Nat) .{{_ : NonZero n}} → Nat
pred′ zero {{}}
pred′ (suc n) = n
test : (n : Nat) {{x y : NonZero n}} → Nat
test n = pred′ n
_<_ : Nat → Nat → Set
m < zero = ⊥
zero < suc n = ⊤
suc... |
open import Agda.Builtin.Nat
open import Agda.Builtin.Equality
test : (x : Nat) (f : {n : Nat} → Nat) → f {0} ≡ x → Nat
test x f p = {!p!}
|
{-# OPTIONS --safe --warning=error --without-K #-}
open import LogicalFormulae
open import Groups.Abelian.Definition
open import Groups.Definition
open import Groups.Lemmas
open import Rings.Definition
open import Setoids.Setoids
open import Sets.EquivalenceRelations
open import Numbers.Naturals.Semiring
open import N... |
{-# OPTIONS --without-K --safe --overlapping-instances #-}
-- Reference to check out
--
-- Simply Typed Lambda Calculus in Agda, without Shortcuts
-- https://gergo.erdi.hu/blog/2013-05-01-simply_typed_lambda_calculus_in_agda,_without_shortcuts/
module InterpreterWithConstants where
open import Data.Char hiding (_≤... |
{-# OPTIONS --without-K --rewriting #-}
open import HoTT hiding (left; right)
import homotopy.WedgeExtension as WedgeExt
module homotopy.blakersmassey.CoherenceData {i j k}
{A : Type i} {B : Type j} (Q : A → B → Type k)
m (f-conn : ∀ a → is-connected (S m) (Σ B (λ b → Q a b)))
n (g-conn : ∀ b → is-connected (S ... |
module examplesPaperJFP.StateDependentIO where
open import Size
open import NativeIO
open import Function
open import Agda.Primitive
open import Level using (_⊔_) renaming (suc to lsuc)
module _ {σ γ ρ} where
record IOInterfaceˢ : Set (lsuc (σ ⊔ γ ⊔ ρ )) where
field Stateˢ : Set σ
Commandˢ ... |
module Tree where
open import Data.Vec
open import Data.Nat
data Head : Set where
H : Head
infixr 5 _⇒_
data Expr : Set where
S : Expr -- something
_⇒_ : Expr → Expr → Expr -- "->" expression
E : Head → ∀{n} → Vec Expr n → Expr -- arbitrary expression
-- the te... |
{-# OPTIONS --without-K --safe #-}
module Categories.NaturalTransformation.NaturalIsomorphism where
open import Level
open import Data.Product using (_×_; _,_; map; zip)
open import Function using (flip)
open import Categories.Category
open import Categories.Functor as ℱ renaming (id to idF)
import Categories.Natura... |
module Point where
open import Nat
open import Bool
-- A record can be seen as a one constructor datatype. In this case:
data Point' : Set where
mkPoint : (x : Nat)(y : Nat) -> Point'
getX : Point' -> Nat
getX (mkPoint x y) = x
getY : Point' -> Nat
getY (mkPoint x y) = y
|
{-# OPTIONS --safe --warning=error --without-K --guardedness #-}
open import Agda.Primitive using (Level; lzero; lsuc; _⊔_)
open import Setoids.Setoids
open import Rings.Definition
open import Rings.Orders.Partial.Definition
open import Rings.Orders.Total.Definition
open import Sets.EquivalenceRelations
open import S... |
{-# OPTIONS --without-K #-}
module Ch2-2 where
open import Ch2-1
open import Level
-- Lemma 2.2.1 (ap)
ap : ∀ {a b} {A : Set a} {B : Set b} {x y : A}
→ (f : A → B)
→ (p : x ≡ y)
→ f x ≡ f y
ap {a} {b} {A} {B} {x} {y} f p = J {a} {a ⊔ b} A D d x y p f
where
-- the predicate
D : (x y : A) (p : x ≡ y) ... |
------------------------------------------------------------------------
-- Well-typed binary relations lifted to substitutions
------------------------------------------------------------------------
{-# OPTIONS --safe --without-K #-}
module Data.Fin.Substitution.TypedRelation where
open import Data.Context hiding ... |
------------------------------------------------------------------------
-- The Agda standard library
--
-- Properties of interleaving using propositional equality
------------------------------------------------------------------------
{-# OPTIONS --without-K --safe #-}
module Data.List.Relation.Ternary.Interleaving... |
-- Andreas, 2012-07-01, issue reported by patrickATparcs.ath...
-- {-# OPTIONS -v tc.term.let.pattern:20 #-}
module Issue671 where
open import Common.Prelude
record Foo : Set where
constructor foo
field
foo₁ : Nat
bar : Nat → Nat
bar a = let
b = a
c = b
foo x = foo 5
in b
-- should succeed,... |
-- Andreas, 2020-02-15, issue #4447, reported by zraffer
record Wrap : Set₁ where
constructor ↑
field ↓ : Set
open Wrap public
data Unit : Set
-- The type checker sees through this definition,
-- thus, the positivity checker should as well:
𝕌nit = ↑ Unit
data Unit where
unit : ↓ 𝕌nit
-- WAS: internal error... |
{-# OPTIONS --without-K #-}
open import HoTT
module homotopy.OneSkeleton {i} {A : Type i} {j} {B : Type j} where
private
module _ (map : A → B) where
data #OneSkeleton-aux : Type i where
#point : A → #OneSkeleton-aux
data #OneSkeleton : Type i where
#one-skeleton : #OneSkeleton-aux... |
{-# OPTIONS --without-K --safe #-}
module Categories.NaturalTransformation.Extranatural where
-- Although there is a notion of Extranatural in Categories.NaturalTransformation.Dinatural,
-- it isn't the most general form, thus the need for this as well.
open import Level
open import Data.Product
open import Relation.... |
open import Data.Nat as N using (ℕ; zero; suc; _<_; _≤_; _>_; z≤n; s≤s; _∸_)
open import Data.Nat.Properties as N
open import Data.Vec as V using (Vec; []; _∷_)
open import Data.Vec.Properties as V
open import Data.Fin as F using (Fin; zero; suc)
import Data.Fin.Properties as F
open import Data.List as L using (Li... |
------------------------------------------------------------------------
-- The Agda standard library
--
-- Results concerning uniqueness of identity proofs, with axiom K
------------------------------------------------------------------------
{-# OPTIONS --with-K --safe #-}
module Axiom.UniquenessOfIdentityProofs.Wi... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.