text
stringlengths
4
690k
{-# OPTIONS --safe --warning=error --without-K #-} open import LogicalFormulae open import Orders.Total.Definition open import Orders.Partial.Definition open import Setoids.Setoids open import Setoids.Orders.Partial.Definition open import Setoids.Orders.Total.Definition open import Functions.Definition open import Set...
-- {-# OPTIONS -v tc.lhs.shadow:30 #-} module PatternShadowsConstructor3 where data Bool : Set where true false : Bool module A where data B : Set where x : B data C : Set where c : B → C open A using (C; c) T : Bool → Set T true = C → C T false = Bool f : (b : Bool) → T b f true (c x) = x f false...
{-# OPTIONS --without-K #-} open import homotopy.3x3.PushoutPushout open import homotopy.3x3.Transpose import homotopy.3x3.To as To import homotopy.3x3.From as From open import homotopy.3x3.Common module homotopy.3x3.Commutes {i} (d : Span^2 {i}) where open Span^2 d open M using (Pushout^2) open To d open From d o...
module Data.ListSized.Proofs where import Lvl open import Data.ListSized open import Data.ListSized.Functions open import Functional open import Function.Equals open import Numeral.Finite open import Numeral.Natural open import Numeral.Natural.Function open import Numeral.Natural.Oper open import Numeral.Natural....
module functions where open import level open import eq open import product {- Note that the Agda standard library has an interesting generalization of the following basic composition operator, with more dependent typing. -} _∘_ : ∀{ℓ ℓ' ℓ''}{A : Set ℓ}{B : Set ℓ'}{C : Set ℓ''} → (B → C) → (A → B) → (A → C)...
{-# OPTIONS --without-K --exact-split --allow-unsolved-metas #-} module 06-universes where import 05-identity-types open 05-identity-types public -- Section 6.3 Pointed types -- Definition 6.3.1 UU-pt : (i : Level) → UU (lsuc i) UU-pt i = Σ (UU i) (λ X → X) type-UU-pt : {i : Level} → UU-pt i → UU i type-UU-pt = p...
module PatternSynonymMutualBlock where data D : Set where c : D mutual pattern p = c
{-# OPTIONS --without-K --safe #-} module Categories.Category.CartesianClosed.Properties where open import Level open import Data.Product using (Σ; _,_; Σ-syntax; proj₁; proj₂) open import Categories.Category open import Categories.Category.CartesianClosed module _ {o ℓ e} {𝒞 : Category o ℓ e} (𝓥 : CartesianClose...
------------------------------------------------------------------------------ -- The gcd program is correct ------------------------------------------------------------------------------ {-# OPTIONS --exact-split #-} {-# OPTIONS --no-sized-types #-} {-# OPTIONS --no-universe-polymorphism #-} {-...
-- Andreas, 2013-05-02 This ain't a bug, it is a feature. -- {-# OPTIONS -v scope.name:10 #-} module Issue836 where open import Common.Equality module M where record R : Set₁ where field X : Set open M using (R) X : R → Set X = R.X -- The open directive did not mention the /module/ R, so (I think -- t...
module AnyBoolean where open import Data.Bool open import Data.Nat open import Data.List hiding (any) open import Relation.Binary.PropositionalEquality even : ℕ → Bool even zero = true even (suc zero) = false even (suc (suc n)) = even n test-6-even : even 6 ≡ true test-6-even = refl odd : ℕ → Bool odd zero = false o...
------------------------------------------------------------------------------ -- Definition of the gcd of two natural numbers using the Euclid's algorithm ------------------------------------------------------------------------------ {-# OPTIONS --exact-split #-} {-# OPTIONS --no-sized-types #-...
{-# OPTIONS --without-K #-} module Interval where open import Pitch open import Data.Bool using (Bool; true; false; _∨_; _∧_; not; if_then_else_) open import Data.Integer using (+_; _-_; sign; ∣_∣) open import Data.Fin using (toℕ) open import Data.Nat using (ℕ; _≡ᵇ_) open import Data.Nat.DivMo...
------------------------------------------------------------------------------ -- All the LTC-PCF modules ------------------------------------------------------------------------------ {-# OPTIONS --exact-split #-} {-# OPTIONS --no-sized-types #-} {-# OPTIONS --no-universe-polymorphism #-} {-# O...
module Tactic.Nat where open import Prelude open import Tactic.Nat.Generic (quote _≤_) (quote id) (quote id) public {- All tactics know about addition, multiplication and subtraction of natural numbers, and can prove equalities and inequalities (_<_). The available tactics are: * auto Prove an equation or i...
module cantor where data Empty : Set where data One : Set where one : One data coprod (A : Set1) (B : Set1) : Set1 where inl : ∀ (a : A) -> coprod A B inr : ∀ (b : B) -> coprod A B postulate exmid : ∀ (A : Set1) -> coprod A (A -> Empty) data Eq1 {A : Set1} (x : A) : A -> Set1 where refle...
------------------------------------------------------------------------ -- Precedence-correct expressions ------------------------------------------------------------------------ module Mixfix.Expr where open import Data.Vec using (Vec) open import Data.List using (List; []; _∷_) open import Data.List.Membership.Pr...
{-# OPTIONS --cubical --no-import-sorts --safe #-} module Cubical.Algebra.Semigroup.Subsemigroup where open import Cubical.Core.Everything open import Cubical.Foundations.Prelude open import Cubical.Foundations.HLevels open import Cubical.Data.Sigma open import Cubical.Algebra open import Cubical.Algebra.Semigroup.Mo...
{-# OPTIONS --safe --experimental-lossy-unification #-} module Cubical.ZCohomology.CohomologyRings.Unit where open import Cubical.Foundations.Prelude open import Cubical.Foundations.Function open import Cubical.Foundations.Isomorphism open import Cubical.Data.Nat renaming (_+_ to _+n_ ; _·_ to _·n_) open import Cubic...
-- Andreas, 2016-12-30, issue #1886 -- Make sure we do not duplicate types of parameters. -- {-# OPTIONS --allow-unsolved-metas #-} -- {-# OPTIONS -v tc.data:40 -v scope.data.def:40 -v tc.decl:10 -v tc:20 #-} data D {A : Set} (x y : {!!}) : Set where -- Expected: only one type and one sort meta.
-- 2014-08-25 reported by Wolfram Kahl, test case shrunk by Ulf, fixed by Andreas and Ulf -- {-# OPTIONS --show-implicit -v tc.cover.splittree:10 -v tc.with:40 -v tc.cc:12 #-} postulate K : Set data SUList : K → Set where cons : ∀ {k} (es : SUList k) → SUList k data Tri : Set where tri< tri> : Tri postulate k ...
------------------------------------------------------------------------ -- The Agda standard library -- -- Properties of pointwise equality for containers ------------------------------------------------------------------------ {-# OPTIONS --without-K --safe #-} module Data.Container.Relation.Binary.Pointwise.Proper...
{-# OPTIONS --safe --warning=error --without-K #-} open import LogicalFormulae open import Setoids.Setoids open import Groups.Definition open import Groups.Homomorphisms.Definition open import Groups.SymmetricGroups.Definition open import Groups.Actions.Definition open import Sets.EquivalenceRelations module Groups.A...
module tests.Arith where open import Prelude.IO open import Prelude.Nat open import Prelude.Unit test : Nat test = 4 foobar : Nat -> Nat foobar Z = Z foobar (S n) = S (S n) main : IO Unit main = -- n <- readNat , printNat 0 ,, printNat (0 + 1) ,, printNat (1 * 2) ,, printNat (S (S (S (S Z))) - S Z) ,, pr...
------------------------------------------------------------------------ -- The Agda standard library -- -- Lists ------------------------------------------------------------------------ module Data.List where open import Data.Nat open import Data.Sum as Sum using (_⊎_; inj₁; inj₂) open import Data.Bool open import D...
open import Everything module Test.Transassociativity where test-transassociativity-≡ : ∀ {𝔬} {𝔒 : Ø 𝔬} {𝔯} {_∼_ : 𝔒 → 𝔒 → Ø 𝔯} ⦃ _ : Transitivity.class _∼_ ⦄ ⦃ _ : Transassociativity!.class _∼_ Proposequality ⦄ → ∀ {w x y z} (f : w ∼ x) (g : x ∼ y) (h : y ∼ z) → (h ∙ g) ∙ f ≡ h ∙ g ∙ f test-transas...
{-# OPTIONS --allow-unsolved-metas #-} open import Agda.Builtin.Unit open import Agda.Builtin.Equality data Unit : Set where unit : Unit A : Unit → Set A unit = ⊤ postulate a b : (u : Unit) → A u mutual _X : Unit _X = {!unit!} test : a _X ≡ b _X test = refl
module Issue289 where data D : Set where d : D record ⊤ : Set where foo : (x y : D) → ⊤ foo d y = {!y!} -- WAS: -- Right hand side must be a single hole when making a case -- distinction. -- when checking that the expression ? has type ⊤ -- NOW: (Andreas, 2013-03-22) -- Since goal is solved, further case distinc...
{-# OPTIONS --without-K --exact-split --safe #-} module 04-inductive-types where import 03-natural-numbers open 03-natural-numbers public -------------------------------------------------------------------------------- -- Section 4.2 The unit type -- Definition 4.2.1 data unit : UU lzero where star : unit 𝟙...
-- Andreas, 2016-12-30, issues #555 and #1886, reported by nad -- Hidden parameters can be omitted in the repetition -- of the parameter list. record R {a} (A : Set a) : Set a record R A where field f : A data D {a} (A : Set a) : Set a data D A where c : A → D A
module BuiltinSucWarning where data Nat : Set where zero : Nat suc : (n : Nat) → Nat {-# BUILTIN NATURAL Nat #-} {-# BUILTIN ZERO zero #-} {-# BUILTIN SUC suc #-} foo : Nat foo = 13
------------------------------------------------------------------------------ -- Non-intuitionistic logic theorems ------------------------------------------------------------------------------ {-# OPTIONS --exact-split #-} {-# OPTIONS --no-sized-types #-} {-# OPTIONS --no-universe-polymorphism...
------------------------------------------------------------------------ -- Subtyping defined in terms of finite approximations ------------------------------------------------------------------------ module RecursiveTypes.Subtyping.Semantic.Inductive where open import Data.Nat open import Data.Fin open import Codata...
module Computability.Data.Nat.Iteration where open import Computability.Prelude iterate : {A : Set} → (A → A) → ℕ → A → A iterate f zero a = a iterate f (suc n) a = f (iterate f n a) split-iterate : {A : Set}(f : A → A)(a : A) → (n m : ℕ) → iterate f (n + m) a ≡ iterate f n (iterate f m a...
------------------------------------------------------------------------ -- The Agda standard library -- -- Coprimality ------------------------------------------------------------------------ {-# OPTIONS --without-K --safe #-} module Data.Nat.Coprimality where open import Data.Empty open import Data.Fin using (toℕ;...
{-# OPTIONS --without-K --safe #-} open import Categories.Category -- a zero object is both terminal and initial. module Categories.Object.Zero {o ℓ e} (C : Category o ℓ e) where open import Level using (_⊔_) open import Categories.Object.Terminal C open import Categories.Object.Initial C open import Categories.Mo...
-- Andreas, 2014-01-21, Issue 1209 reported by Andrea {-# OPTIONS --cubical-compatible #-} {-# OPTIONS --copatterns #-} {-# OPTIONS --sized-types #-} open import Common.Size record R (i : Size) : Set where coinductive field force : (j : Size< i) → R j postulate f : ∀ {i} → R i → R i t : (i : Size) → R i ...
------------------------------------------------------------------------ -- The Agda standard library -- -- Some algebraic structures (not packed up with sets, operations, -- etc.) ------------------------------------------------------------------------ {-# OPTIONS --without-K --safe #-} open import Relation.Binary u...
-- Andreas, 2014-09-02 module _ where module Data where data D : Set where A : D module _ (A : Set) where open Data using (D; A) x : D x = A
-- Andreas, 2011-04-07 module IrrelevantFamilyIndex where data Nat : Set where zero : Nat suc : Nat -> Nat -- irrelevant index data Fin : .Nat -> Set where zero : .(n : Nat) -> Fin (suc n) suc : .(n : Nat) -> Fin n -> Fin (suc n) t : Fin zero t = zero zero -- the following is ok, since Fin _ is really ju...
{- Copyright © 2015 Benjamin Barenblat Licensed under the Apache License, Version 2.0 (the ‘License’); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, so...
------------------------------------------------------------------------ -- The Agda standard library -- -- N-ary products ------------------------------------------------------------------------ -- Vectors (as in Data.Vec) also represent n-ary products, so what is -- the point of this module? The n-ary products below...
{- Byzantine Fault Tolerant Consensus Verification in Agda, version 0.9. Copyright (c) 2020 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.Concrete.System.Parameters import LibraBFT.Concrete.Proper...
-- Andreas, 2016-11-03, issue #2291, reported by Aerate -- {-# OPTIONS -v interaction.helper:100 #-} record Foo : Set where coinductive field one : Foo open Foo someFoo : Foo someFoo .one = {! {R} -> Foo.one R !} -- WAS: C-c C-h gives: -- An internal error has occurred. Please report this as a bug. -- Location ...
{-# OPTIONS --cubical --safe #-} module Cubical.Data.Unit.Properties where open import Cubical.Core.Everything open import Cubical.Foundations.Prelude open import Cubical.Foundations.HLevels open import Cubical.Data.Nat open import Cubical.Data.Unit.Base open import Cubical.Data.Prod.Base isContrUnit : isContr Unit...
module Axiom.FunctionExtensionality where open import Level using (zero) open import Relation.Binary.PropositionalEquality postulate fun-ext : Extensionality zero zero
{-# OPTIONS --allow-unsolved-metas #-} {-# OPTIONS --show-implicit #-} open import Oscar.Prelude open import Oscar.Class -- classes open import Oscar.Class.Transitivity -- data open import Oscar.Data.Substitunction open import Oscar.Data.Term module Test.EquivalentCandidates where module _ {a} where instanc...
{-# OPTIONS --allow-unsolved-metas #-} open import MultiSorted.AlgebraicTheory import MultiSorted.Interpretation as Interpretation import MultiSorted.SyntacticCategory as SyntacticCategory import MultiSorted.Substitution as Substitution import Agda.Builtin.Equality as Eq open import Relation.Binary.PropositionalEqual...
import Level open import Relation.Binary using (Decidable ; Rel ; IsStrictTotalOrder ; Tri) open import Relation.Binary.PropositionalEquality using (_≡_ ; refl ; cong ; sym ; module ≡-Reasoning ; inspect ; subst) open import Data.Nat as Nat using (ℕ ; suc ; zero ; _≤′_ ; _≤_ ; _+_ ; s≤s ; z≤n ; ≤′-refl ; ...
------------------------------------------------------------------------------ -- Testing the class AgdaInternal.RemoveProofTerms.RemoveVar: Lam term ------------------------------------------------------------------------------ {-# OPTIONS --exact-split #-} {-# OPTIONS --no-sized-types #-} {-# ...
module modal-lob-reduced where data TYP : Set where ARR : TYP → TYP → TYP -- the type of implications, or function types BOX : TYP → TYP -- the modal □ operator, denoted to TERM LӦB-SENTENCE : TYP → TYP -- the Lӧbian sentence "If this sentence is provable, then A" -- this is the modal f...
------------------------------------------------------------------------ -- The Agda standard library -- -- Notation for freely adding an infimum to any set ------------------------------------------------------------------------ {-# OPTIONS --without-K --safe #-} module Relation.Nullary.Construct.Add.Infimum where ...
{- Copyright © 1992–2002 The University of Glasgow Copyright © 2015 Benjamin Barenblat Licensed under the Apache License, Version 2.0 (the ‘License’); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless requir...
------------------------------------------------------------------------ -- Up-to techniques via ------------------------------------------------------------------------ {-# OPTIONS --sized-types #-} module Up-to.Via where open import Equality.Propositional open import Logical-equivalence using (_⇔_) open import Pre...
{- Byzantine Fault Tolerant Consensus Verification in Agda, version 0.9. Copyright (c) 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.Base.Types open import LibraBFT.Concrete.System.Paramete...
------------------------------------------------------------------------------ -- Propositional equality without using pattern matching on refl ------------------------------------------------------------------------------ {-# OPTIONS --exact-split #-} {-# OPTIONS --no-sized-types #-} {-# OPTION...
-- Andreas, 2015-11-17, issue reported by Martin Stone Davis module _ where module Sub (let open import oops) where -- WAS: internal error -- EXPECTED: Not a valid let-declaration -- when scope checking the declaration -- module Sub (let open import oops) where
------------------------------------------------------------------------ -- The Agda standard library -- -- Equality over lists parameterised by some setoid ------------------------------------------------------------------------ {-# OPTIONS --without-K --safe #-} open import Relation.Binary using (Setoid) module Da...
module plfa.part1.Midterm where import Relation.Binary.PropositionalEquality as Eq open Eq using (_≡_; refl; cong; sym) -- you can add any import definitions that you need open Eq.≡-Reasoning using (begin_; _≡⟨⟩_; _≡⟨_⟩_; _∎) open import Data.Nat using (ℕ; zero; suc; _+_; _*_; _≤_; _>_; z≤n; s≤s; _≤?_; _<?_; _^_) ope...
-- Andreas, 2016-12-30, issue #1886, reported by nad -- -- Change of parameter names is an error. -- Reason: the parameter names become names of hidden arguments -- in the constructors. There should be no ambiguity. data D (X : Set) : Set data D (Y : Set) where c : Y → D Y
module Categories.Object.Zero where
module Loop where {- data _=>_ (A, B : Set) : Set where lam : (A -> B) -> A => B app : {A, B : Set} -> (A => B) -> A -> B app (lam f) = f delta = lam (\x -> app x x) loop = app delta delta -} lam : (A, B : Set) -> (A -> B) -> A -> B lam A B f = f app : (A, B : Set) -> (A -> B) -> A -> B app A B f = f postulat...
------------------------------------------------------------------------------ -- Properties of the divisibility relation ------------------------------------------------------------------------------ {-# OPTIONS --exact-split #-} {-# OPTIONS --no-sized-types #-} {-# OPTIONS --no-universe-polymo...
------------------------------------------------------------------------ -- Unary and binary relations ------------------------------------------------------------------------ {-# OPTIONS --safe #-} module Relation where open import Equality.Propositional open import Prelude open import Bijection equality-with-J as...
{-# OPTIONS --universe-polymorphism #-} module LevelWithBug where open import Common.Level postulate take : ∀ a → Set a → Set a : Level A : Set a Goal : Set → Set goal : ∀ X → Goal X -- The meta got solved by Level (Max [Plus 0 (NeutralLevel a)]) which -- didn't match the argument in the with expression w...
module Structure.Operator.Ring.Rings where import Lvl open import Structure.Operator.Ring open import Structure.Setoid open import Type open import Type.Properties.Singleton private variable ℓ ℓₑ : Lvl.Level private variable T U : Type{ℓ} postulate trivialRing : ∀{_+_ _⋅_ : U → U → U} → ⦃ equiv : Equiv{ℓₑ}(U) ⦄...
{-# OPTIONS --cubical --no-import-sorts --safe #-} module Cubical.Data.Bool.Properties where open import Cubical.Core.Everything open import Cubical.Foundations.Prelude open import Cubical.Foundations.Equiv open import Cubical.Foundations.Isomorphism open import Cubical.Foundations.Univalence open import Cubical.Dat...
------------------------------------------------------------------------------ -- Agda-Prop Library. -- Theorems of ∧ connective. ------------------------------------------------------------------------------ open import Data.Nat using ( ℕ ) module Data.PropFormula.Theorems.Conjunction ( n : ℕ ) where --------------...
------------------------------------------------------------------------ -- Descending lists -- -- Anders Mörtberg and Chuangjie Xu, October 2019 -- -- We define descending lists via simultaneous definitions and show -- that they are isomorphic to finite multisets. The conversion from -- finite multisets to descending...
module main where open import lib import string-format -- for parser for Cedille open import cedille-types -- for parser for options files import options-types import cedille-options -- for parser for Cedille comments & whitespace import cws-types open import constants open import general-util createOptionsFile ...
{-# OPTIONS --without-K #-} module Story where {-- PiCat level 0: Objects: Finite sets viewed as discrete-groupoids Morphisms: Permutations between finite sets viewed as permutation-groupoids Equivalence: Strong Equivalence of categories Discrete-Groupoids: Objects: Parameterized Morphisms: O...
------------------------------------------------------------------------------ -- Testing the existential quantifier ------------------------------------------------------------------------------ {-# OPTIONS --exact-split #-} {-# OPTIONS --no-sized-types #-} {-# OPTIONS --no-universe-polymorphis...
{-# OPTIONS --without-K #-} module Homotopy where open import GroupoidStructure open import PathOperations open import Types infix 1 _∼_ _∼_ : ∀ {a b} {A : Set a} {B : Set b} (f g : A → B) → Set _ f ∼ g = ∀ x → f x ≡ g x naturality : ∀ {a b} {A : Set a} {B : Set b} {x y : A} (f g : A → B) (H : f ∼ g) (p : x ≡ ...
{-# OPTIONS --without-K --rewriting #-} open import lib.Basics open import lib.Equivalence2 open import lib.Relation2 open import lib.types.Paths open import lib.types.Pi open import lib.types.Sigma open import lib.types.TLevel module lib.NType2 where module _ {i} {A : Type i} where abstract has-dec-onesided-e...
{-# OPTIONS --without-K --safe #-} module RealsRefactored where open import Algebra open import Data.Bool.Base using (Bool; if_then_else_) open import Function.Base using (_∘_) open import Data.Integer.Base as ℤ using (ℤ; +_; +0; +[1+_]; -[1+_]) import Data.Integer.Properties as ℤP open import Data.Integer.DivMod a...
module Singleton where open import Level open import Data.Unit open import Data.Product open import Function open import Relation.Binary open import Function.Inverse open import Function.Equality as FE open import Relation.Binary.PropositionalEquality as P open import Pi using (⟦_⟧; _⟷_ ) embed₁ : Set → Set embed₁ ...
{-# OPTIONS --copatterns #-} module HighlightCopattern where record WrapSet : Set₂ where field wrapped : Set₁ open WrapSet my : WrapSet wrapped my = Set -- 'wrapped' should be highlighted in projection color proj : WrapSet → Set₁ proj w = wrapped w -- 'wrapped' should be highlighted in projection color
------------------------------------------------------------------------ -- The Agda standard library -- -- Some derivable properties ------------------------------------------------------------------------ {-# OPTIONS --without-K --safe #-} open import Algebra module Algebra.Properties.Lattice {l₁ l₂} (L : Lattice ...
{-# OPTIONS --without-K --safe #-} module Categories.Object.Subobject.Properties where open import Level open import Data.Product open import Data.Unit open import Function using (_$_) open import Relation.Binary using (_=[_]⇒_) open import Relation.Binary.Bundles open import Relation.Binary.OrderMorphism open imp...
module Issue2217.M where
------------------------------------------------------------------------ -- The Agda standard library -- -- Properties of binary relations ------------------------------------------------------------------------ -- The contents of this module should be accessed via `Relation.Binary`. {-# OPTIONS --without-K --safe #-...
module equational where open import lib postulate A : Set a : A b : A c : A d : A f : A → A g : A → A h : A → A → A p : a ≡ b q : b ≡ c r : f a ≡ a s : h a a ≡ a t : ∀ x → f (g x) ≡ g (f x) u : ∀ {x} → f x ≡ x → g (g x) ≡ x -- {x} means x is implicit, so you do not ...
module libbijection where open import Level renaming ( zero to Zero ; suc to Suc ) open import Data.Nat open import Data.Maybe open import Data.List hiding ([_] ; sum ) open import Data.Nat.Properties open import Relation.Nullary open import Data.Empty open import Data.Unit hiding ( _≤_ ) open import Relation.Binary....
{- A parameterized family of structures S can be combined into a single structure: X ↦ (a : A) → S a X -} {-# OPTIONS --cubical --no-import-sorts --safe #-} module Cubical.Structures.Parameterized where open import Cubical.Foundations.Prelude open import Cubical.Foundations.Equiv open import Cubical.Functions.FunExt...
{-# OPTIONS --allow-unsolved-metas --guardedness #-} import Tutorials.Monday-Complete as Mon import Tutorials.Tuesday-Complete as Tue import Tutorials.Wednesday-Complete as Wed open Mon using (⊤; tt; ℕ; zero; suc) open Mon.Simple using (_⊎_; inl; inr) open Tue.Product using (Σ; _,_; fst; snd; _×_) module Tutorials.Th...
{- Copyright © 1992–2002 The University of Glasgow Copyright © 2015 Benjamin Barenblat Licensed under the Apache License, Version 2.0 (the ‘License’); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless requir...
{-# OPTIONS --show-implicit #-} module BottomUp where open import Foundation.Primitive open import Foundation.Bottom open import Foundation.Equivalence open import Agda.Builtin.List open import Agda.Builtin.Equality open import Agda.Builtin.Unit module NegEquiv {ℓ'} (⊥ : Set ℓ') ⦃ _ : ∀ {b} → IsBottom ⊥ b ⦄ where ...
{- Example by Guillaume Brunerie, 17-11-2015 -} {-# OPTIONS --rewriting --cubical-compatible #-} open import Agda.Primitive postulate _↦_ : ∀ {i} {A : Set i} → A → A → Set i idr : ∀ {i} {A : Set i} {a : A} → a ↦ a {-# BUILTIN REWRITE _↦_ #-} infixr 3 _==_ data _==_ {i} {A : Set i} (a : A) : A → Set i where i...
-- Andreas, 2014-09-03 -- Test explanation of local shadowed by import. module _ where module M where A = Set1 test : (A : Set) → let open M in {!A!} test A = Set -- The A exported by M is in competition with the local A. -- Ambiguous name should be reported.
module Transducer where open import Data.Unit open import Data.Product open import Data.Sum open import Data.List _* = List -- | Finite and infinite sequences (constructively useful variant) record Seq (A : Set) : Set where coinductive field out : (A ⊎ ⊤) × Seq A open Seq -- | Functor that allows us to capt...
{-# OPTIONS --cubical --safe --no-import-sorts #-} module Cubical.Algebra.Module where open import Cubical.Algebra.Module.Base public
------------------------------------------------------------------------------ -- Test the consistency of FOTC.Base ------------------------------------------------------------------------------ {-# OPTIONS --exact-split #-} {-# OPTIONS --no-sized-types #-} {-# OPTIONS --no-universe-polymorphism...
module Slice where open import Logic.Relations open import Logic.Equivalence open import Logic.Base open import Category module SliceCat (ℂ : Cat)(Γ : Category.Obj ℂ) where open module CC = Category.Category ℂ record SlObj : Set1 where field dom : Obj arr : dom ─→ Γ record _Sl→_ (f f' : Sl...
{-# OPTIONS --without-K --safe #-} module Algebra.Structures.Bundles.Field where open import Algebra open import Level using (suc; _⊔_) open import Relation.Binary using (Rel) open import Algebra.Structures.Field record Field c ℓ : Set (suc (c ⊔ ℓ)) where field Carrier : Set c _≈_ : Rel Carrier ℓ ...
{-# OPTIONS --safe --warning=error --without-K #-} open import LogicalFormulae open import Groups.Groups open import Groups.Homomorphisms.Definition open import Groups.Definition open import Numbers.Naturals.Naturals open import Setoids.Setoids open import Functions.Definition open import Sets.EquivalenceRelations op...
import Relation.Binary.PropositionalEquality as Eq open Eq using (_≡_; refl; sym; trans; cong; cong₂; _≢_) open import Data.Empty using (⊥; ⊥-elim) open import Data.List using (List; []; _∷_; takeWhile; dropWhile) open import Data.List.All using (All; []; _∷_) open import Data.Bool using (Bool; true; false; T) open imp...
{-# OPTIONS --without-K --rewriting #-} open import HoTT open import homotopy.DisjointlyPointedSet module groups.DisjointlyPointedSet where diff-and-separate : ∀ {i j} {X : Ptd i} (G : Group j) → (de⊙ X → Group.El G) → Group.El G × (MinusPoint X → Group.El G) diff-and-separate {X = X} G f = f (pt X) , λ ...
-- See also test/Succeed/InlineCompiled.agda module _ where id : {A : Set} → A → A id x = x {-# INLINE id #-} -- this is pointless and should generate a warning in the info buffer {-# COMPILE GHC id = \ _ x -> x #-}
{-# OPTIONS --without-K #-} open import lib.Basics open import lib.NConnected open import lib.types.TLevel open import lib.NType2 open import lib.types.Pi open import lib.types.Sigma open import lib.types.Pointed open import lib.types.LoopSpace open import lib.types.Truncation open import lib.types.PathSet module lib...
{-# OPTIONS --safe #-} module Cubical.Algebra.Semilattice where open import Cubical.Algebra.Semilattice.Base public