text
stringlengths
4
690k
module VariableName where open import OscarPrelude record VariableName : Set where constructor ⟨_⟩ field name : Nat open VariableName public instance EqVariableName : Eq VariableName Eq._==_ EqVariableName _ = decEq₁ (cong name) ∘ (_≟_ on name $ _)
------------------------------------------------------------------------ -- A self-interpreter (without correctness proof) ------------------------------------------------------------------------ module Self-interpreter where open import Prelude hiding (const) -- To simplify the development, let's work with actual n...
{-# OPTIONS --without-K --safe #-} module Categories.Category.Core where open import Level open import Function.Base using (flip) open import Relation.Binary using (Rel; IsEquivalence; Setoid) import Relation.Binary.Reasoning.Setoid as SetoidR -- Basic definition of a |Category| with a Hom setoid. -- Also comes with...
{-# OPTIONS --without-K --safe #-} module Categories.Adjoint.Equivalence where open import Level open import Categories.Adjoint open import Categories.Adjoint.TwoSided open import Categories.Adjoint.TwoSided.Compose open import Categories.Category.Core using (Category) open import Categories.Functor using (Functor; ...
{-# OPTIONS --without-K #-} module sets.properties where open import sum open import equality.core open import equality.calculus open import function.isomorphism open import function.overloading open import hott.level open import hott.equivalence.core open import hott.equivalence.alternative open import sets.unit mk-...
{-# OPTIONS --safe --warning=error --without-K #-} open import Agda.Primitive using (Level; lzero; lsuc; _⊔_) open import LogicalFormulae open import Sets.EquivalenceRelations open import Setoids.Setoids open import Setoids.Subset module Setoids.Union.Lemmas {a b : _} {A : Set a} (S : Setoid {a} {b} A) {c d : _} {pre...
{-# OPTIONS --cubical --safe #-} module Cubical.HITs.Susp.Base where open import Cubical.Core.Glue open import Cubical.Foundations.Prelude open import Cubical.Foundations.Equiv open import Cubical.Foundations.Isomorphism open import Cubical.Data.Bool open import Cubical.HITs.S1 open import Cubical.HITs.S2 open impo...
-- # A Reflexive Graph Model of Sized Types -- This is the formalisation of my M.Sc. thesis, available at -- https://limperg.de/paper/msc-thesis/ -- I define λST, a simply typed lambda calculus extended with sized types. I -- then give a reflexive graph model of λST which incorporates a notion of size -- irrelevan...
module New.Correctness where open import Function hiding (const) open import New.Lang open import New.Changes open import New.Derive open import New.LangChanges open import New.LangOps open import New.FunctionLemmas open import New.Unused ⟦Γ≼ΔΓ⟧ : ∀ {Γ} (ρ : ⟦ Γ ⟧Context) (dρ : ChΓ Γ) → validΓ ρ dρ → ρ ≡ ⟦ Γ≼ΔΓ ⟧≼ ...
module _ where module M (X : Set₁) where record Raw : Set₁ where field return : Set postulate fmap : Set module Fails = Raw ⦃ … ⦄ module Works ⦃ r : Raw ⦄ = Raw r open M postulate r : Raw Set fail : Set fail = Fails.fmap Set ⦃ r ⦄ -- C-c C-n fail -- M.Raw.fmap Set r good : Set good = Works.fmap Se...
------------------------------------------------------------------------ -- The Agda standard library -- -- This module is DEPRECATED. Please use Data.List.Relation.Unary.All -- directly. ------------------------------------------------------------------------ {-# OPTIONS --without-K --safe #-} module Data.List.All w...
{-# OPTIONS --safe #-} module Cubical.Categories.Limits.Initial where open import Cubical.Foundations.Prelude open import Cubical.Foundations.HLevels open import Cubical.Foundations.Isomorphism renaming (Iso to _≅_) open import Cubical.HITs.PropositionalTruncation.Base open import Cubical.Data.Sigma open import Cubi...
{-# OPTIONS --without-K #-} open import lib.Basics hiding (_⊔_) open import lib.types.Sigma open import lib.types.Bool open import lib.types.Empty open import Preliminaries open import Truncation_Level_Criteria open import Anonymous_Existence_CollSplit open import Anonymous_Existence_Populatedness module Anonymous_...
module Luau.RuntimeType where open import Luau.Syntax using (Value; nil; addr; number; bool; string) data RuntimeType : Set where function : RuntimeType number : RuntimeType nil : RuntimeType boolean : RuntimeType string : RuntimeType valueType : Value → RuntimeType valueType nil = nil valueType (addr a) =...
{-# OPTIONS --allow-unsolved-metas #-} module automaton-ex where open import Data.Nat open import Data.List open import Data.Maybe open import Relation.Binary.PropositionalEquality hiding ( [_] ) open import Relation.Binary.Definitions open import Relation.Nullary using (¬_; Dec; yes; no) open import logic open impor...
apply : ∀ {a b} {A : Set a} {B : A → Set b} → ((x : A) → B x) → (x : A) → B x apply f x = f x syntax apply f x = f x
{-# OPTIONS --rewriting --without-K #-} open import Agda.Primitive open import Prelude import GSeTT.Syntax {- Syntax for a globular type theory, with arbitrary term constructors -} module Globular-TT.Syntax {l} (index : Set l) where data Pre-Ty : Set (lsuc l) data Pre-Tm : Set (lsuc l) data Pre-Sub : Set (lsuc...
{-# OPTIONS --without-K --safe #-} module Cats.Category.Cones where open import Relation.Binary using (Rel ; IsEquivalence ; _Preserves₂_⟶_⟶_) open import Level using (_⊔_) open import Cats.Category.Base open import Cats.Category.Cat using (Cat) open import Cats.Category.Fun as Fun using (Fun ; Trans) open import Cat...
{-# OPTIONS --cubical --no-import-sorts --safe #-} module Cubical.HITs.Ints.QuoInt where open import Cubical.HITs.Ints.QuoInt.Base public open import Cubical.HITs.Ints.QuoInt.Properties public
-- Andreas, 2019-09-13, AIM XXX, test for #4050 by gallais record Wrap : Set₂ where field wrapped : Set₁ f : Wrap f = record { M } module M where wrapped : Set₁ wrapped = Set -- Should be accepted.
{-# OPTIONS --safe #-} module Cubical.Categories.Instances.Sets where open import Cubical.Foundations.Prelude open import Cubical.Foundations.HLevels open import Cubical.Foundations.Equiv open import Cubical.Foundations.Equiv.Properties open import Cubical.Foundations.Isomorphism open import Cubical.Data.Unit open im...
module Inductive.Examples.Empty where open import Inductive open import Tuple open import Data.Fin open import Data.Product open import Data.List open import Data.Vec ⊥ : Set ⊥ = Inductive [] contradiction : {A : Set} → ⊥ → A contradiction = rec []
module CS410-Prelude where open import Agda.Primitive ---------------------------------------------------------------------------- -- Zero -- the empty type (logically, a false proposition) ---------------------------------------------------------------------------- data Zero : Set where magic : forall {l}{A : Set...
{-# OPTIONS --cubical --no-import-sorts --safe #-} module Cubical.Data.Graph.Base where open import Cubical.Foundations.Prelude open import Cubical.Foundations.Function private variable ℓv ℓv' ℓv'' ℓe ℓe' ℓe'' ℓd ℓd' : Level -- The type of directed multigraphs (with loops) record Graph ℓv ℓe : Type (ℓ-suc (ℓ-max ℓv...
-- Andreas, 2017-12-16, issue #2871 -- If there is nothing to result-split, introduce trailing hidden args. -- {-# OPTIONS -v interaction.case:40 #-} data Fun (A : Set) : Set where mkFun : (A → A) → Fun A test : ∀ {A : Set} → Fun A test = {!!} -- C-c C-x C-h C-c C-c RET -- Works also with C-c C-c RET -- -- Expe...
------------------------------------------------------------------------ -- INCREMENTAL λ-CALCULUS -- -- Delta-observational equivalence - base definitions ------------------------------------------------------------------------ module Base.Change.Equivalence.Base where open import Relation.Binary.PropositionalEqualit...
{-# OPTIONS --cubical --safe #-} module Data.List.Kleene.Membership where open import Prelude open import Data.List.Kleene open import Data.List.Kleene.Relation.Unary infixr 5 _∈⋆_ _∈⁺_ _∉⋆_ _∉⁺_ _∈⋆_ _∉⋆_ : A → A ⋆ → Type _ x ∈⋆ xs = ◇⋆ (_≡ x) xs x ∉⋆ xs = ¬ (x ∈⋆ xs) _∈⁺_ _∉⁺_ : A → A ⁺ → Type _ x ∈⁺ xs = ◇⁺ (_≡...
open import Data.Product using ( _,_ ) open import FRP.LTL.ISet.Core using ( ISet ; _⇛_ ; mset ; M⟦_⟧ ; ⟦_⟧ ; [_] ; subsumM⟦_⟧ ) open import FRP.LTL.Time.Interval using ( ⊑-refl ) module FRP.LTL.ISet.Stateless where infixr 2 _⇒_ _⇒_ : ISet → ISet → ISet A ⇒ B = mset A ⇛ B -- We could define $ as -- f $ σ = i→m (λ j...
{-# OPTIONS --without-K #-} open import lib.Base open import lib.PathGroupoid open import lib.Relation open import lib.NType open import lib.types.Empty module lib.types.Nat where infixl 80 _+_ _+_ : ℕ → ℕ → ℕ 0 + n = n (S m) + n = S (m + n) {-# BUILTIN NATPLUS _+_ #-} +-unit-r : (m : ℕ) → m + 0 == m +-unit-r 0 ...
{-# OPTIONS --safe #-} -- --without-K #-} open import Relation.Binary.PropositionalEquality using (_≡_; refl; sym; subst; cong; trans) open Relation.Binary.PropositionalEquality.≡-Reasoning open import Relation.Nullary using (yes; no) open import Relation.Nullary.Decidable using (fromWitness) import Data.Product as P...
-- We can let Agda infer the parameters of the constructor target data List (A : Set) : Set where nil : List _ cons : A → List A → List _ -- 2017-01-12, Andreas: we can even omit the whole target -- (for parameterized data types, but not inductive families) data Bool : Set where true false : _ data Maybe (A ...
{- This module converts between the path equality and the inductively define equality types. - _≡c_ stands for "c"ubical equality. - _≡p_ stands for "p"ropositional equality. TODO: reconsider naming scheme. -} {-# OPTIONS --cubical --no-import-sorts --safe #-} module Cubical.Data.Equality where open import Cubical...
------------------------------------------------------------------------ -- The Agda standard library -- -- This module is DEPRECATED. Please use the -- Relation.Binary.Reasoning.Preorder module directly. ------------------------------------------------------------------------ {-# OPTIONS --without-K --safe #-} open ...
{-# OPTIONS --without-K --safe #-} open import Polynomial.Parameters -- Here, we provide proofs of homomorphism between the operations -- defined on polynomials and those on the underlying ring. module Polynomial.Homomorphism {c r₁ r₂ r₃} (homo : Homomorphism c r₁ r₂ r₃) where -- The lemmas are the general-pu...
{-# OPTIONS --cubical --no-import-sorts --no-exact-split --safe #-} module Cubical.Data.Queue.Finite where open import Cubical.Foundations.Everything open import Cubical.Foundations.SIP open import Cubical.Structures.Queue open import Cubical.Data.Maybe open import Cubical.Data.List open import Cubical.Data.Sigma op...
-- Andreas, 2015-05-28 example by Andrea Vezzosi open import Common.Size data Nat (i : Size) : Set where zero : ∀ {j : Size< i} → Nat i suc : ∀ {j : Size< i} → Nat j → Nat i {-# TERMINATING #-} -- This definition is fine, the termination checker is too strict at the moment. fix : ∀ {C : Size → Set} → (∀{i} → ...
---------------------------------------------------------------------- -- Copyright: 2013, Jan Stolarek, Lodz University of Technology -- -- -- -- License: See LICENSE file in root of the repo -- -- Repo address: https://github.com/...
import cedille-options open import general-util module meta-vars (options : cedille-options.options) {mF : Set → Set} ⦃ _ : monad mF ⦄ where open import cedille-types open import constants open import conversion open import ctxt open import free-vars open import rename open import spans options {mF} open import subst ...
{- 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 import LibraBFT.Impl.Types.EpochState ...
{-# OPTIONS --cubical --no-import-sorts --safe #-} open import Cubical.Core.Everything open import Cubical.Foundations.HLevels module Cubical.Algebra.Magma.Construct.Left {ℓ} (Aˢ : hSet ℓ) where open import Cubical.Foundations.Prelude open import Cubical.Algebra.Magma private A = ⟨ Aˢ ⟩ isSetA = Aˢ .snd _◂_ : ...
------------------------------------------------------------------------ -- A type soundness result ------------------------------------------------------------------------ {-# OPTIONS --cubical --sized-types #-} module Lambda.Partiality-monad.Inductive.Type-soundness where open import Equality.Propositional.Cubical...
module Issue1760a where -- Skipping a single record definition. {-# NO_POSITIVITY_CHECK #-} record U : Set where field ap : U → U
module StrongRMonads where open import Library open import Categories open import Functors open import MonoidalCat open import RMonads record SRMonad {a b c d}{M : Monoidal {a}{b}}{M' : Monoidal {c}{d}} (J : MonoidalFun M M') : Set (a ⊔ b ⊔ c ⊔ d) where constructor srmonad open MonoidalFun J field RM : R...
------------------------------------------------------------------------ -- The Agda standard library -- -- This module is DEPRECATED. Please use -- Data.Sum.Relation.Binary.LeftOrder directly. ------------------------------------------------------------------------ {-# OPTIONS --without-K --safe #-} module Data.Sum....
-- Andreas, 2017-02-27, issue #2477 {-# OPTIONS --show-irrelevant #-} open import Agda.Builtin.Size open import Agda.Builtin.Nat using (suc) renaming (Nat to ℕ) _+_ : Size → ℕ → Size s + 0 = s s + suc n = ↑ (s + n) data Nat : Size → Set where zero : ∀ i → Nat (i + 1) suc : ∀ i → Nat i → Nat (i + 1) -- i ...
module RMonads.SpecialCase where open import Categories open import Functors open import Naturals hiding (Iso) open import Monads open import RMonads leftM : ∀{a}{b}{C : Cat {a}{b}} → Monad C → RMonad (IdF C) leftM M = record { T = T; η = η; bind = bind; law1 = law1; law2 = law2; law3 = law3} wh...
------------------------------------------------------------------------ -- Compiler correctness ------------------------------------------------------------------------ {-# OPTIONS --erased-cubical --sized-types #-} module Lambda.Delay-monad.Compiler-correctness where import Equality.Propositional as E open import ...
{-# OPTIONS --without-K #-} open import HoTT -- Associativity of the join (work in progress) module experimental.JoinAssoc2 where import experimental.JoinAssoc as Assoc module Assoc2 {i j k} (A : Type i) (B : Type j) (C : Type k) where open Assoc A B C {- Here are the steps, without the junk around: ...
------------------------------------------------------------------------ -- The Agda standard library -- -- Some examples showing how the AVL tree module can be used ------------------------------------------------------------------------ module README.AVL where -------------------------------------------------------...
{-# OPTIONS --type-in-type --rewriting #-} module _ where postulate _≡_ : {A : Set} → A → A → Set {-# BUILTIN REWRITE _≡_ #-} record ⊤ : Set where constructor [] open ⊤ postulate ID : (Δ : Set) (δ₀ δ₁ : Δ) → Set ID⊤ : (δ₀ δ₁ : ⊤) → ID ⊤ δ₀ δ₁ ≡ ⊤ Id : {Δ : Set} (A : Δ → Set) {δ₀ δ₁ : Δ} (δ₂ : ID Δ δ₀ δ₁)...
module Data.List.Properties.Pointwise where open import Data.Nat open import Data.List open import Relation.Binary.List.Pointwise hiding (refl; map) open import Relation.Binary.PropositionalEquality pointwise-∷ʳ : ∀ {a b ℓ A B P l m x y} → Rel {a} {b} {ℓ} {A} {B} P l m → P x y → Rel {a} {b} {ℓ} {A} {B} ...
-- Pattern synonyms are now allowed in parameterised modules. module _ where module L (A : Set) where data List : Set where nil : List cons : A → List → List pattern unit x = cons x nil data Bool : Set where true false : Bool module LB = L Bool open LB init : List → List init nil = nil init (unit _) =...
{- COMPLEXITY LANGUAGE -} open import Preliminaries open import Preorder-Max module Complexity where data CTp : Set where unit : CTp nat : CTp _->c_ : CTp → CTp → CTp _×c_ : CTp → CTp → CTp list : CTp → CTp bool : CTp C : CTp -- represent a context as a list of types Ctx = List CTp...
-- Andreas, 2017-01-24, issue #2430, reported by nad -- Regression introduced by updating module parameter substitution -- when going underAbstraction (80794767db1aceaa78a72e06ad901cfa53f8346d). record Σ (A : Set) (B : A → Set) : Set where field proj₁ : A proj₂ : B proj₁ open Σ public Σ-map : {A : Set} {B...
module Generic.Lib.Intro where open import Level renaming (zero to lzero; suc to lsuc) public open import Function public open import Data.Bool.Base hiding (_<_; _≤_) public infixl 10 _% infixl 2 _>>>_ data ⊥ {α} : Set α where record ⊤ {α} : Set α where instance constructor tt ⊥₀ = ⊥ {lzero} ⊤₀ = ⊤ {lzero} tt₀ ...
{-# OPTIONS --postfix-projections #-} module UnSizedIO.Base where open import Data.Maybe.Base open import Data.Sum renaming (inj₁ to left; inj₂ to right; [_,_]′ to either) open import Function open import NativeIO record IOInterface : Set₁ where field Command : Set Response : (m : Command) → Set open IO...
{-# OPTIONS --safe #-} module Definition.Typed.Consequences.Reduction where open import Definition.Untyped open import Definition.Typed open import Definition.Typed.Properties open import Definition.Typed.EqRelInstance open import Definition.LogicalRelation open import Definition.LogicalRelation.Properties open impor...
-- Andreas, 2015-05-28 example by Andrea Vezzosi open import Common.Size data Nat (i : Size) : Set where zero : ∀ (j : Size< i) → Nat i suc : ∀ (j : Size< i) → Nat j → Nat i {-# TERMINATING #-} -- This definition is fine, the termination checker is too strict at the moment. fix : ∀ {C : Size → Set} → (∀ i → (∀ ...
------------------------------------------------------------------------ -- The Agda standard library -- -- Properties satisfied by decidable total orders ------------------------------------------------------------------------ {-# OPTIONS --without-K --safe #-} open import Relation.Binary module Relation.Binary.Pro...
{-# OPTIONS --without-K --safe #-} module Data.List.Kleene where open import Data.List.Kleene.Base public
module Dave.Algebra.Naturals.Multiplication where open import Dave.Algebra.Naturals.Addition public _*_ : ℕ → ℕ → ℕ zero * b = zero suc a * b = (a * b) + b infixl 7 _*_ *-zero : ∀ (m : ℕ) → m * zero ≡ zero *-zero zero = refl *-zero (suc m) = begin suc m * zero ≡⟨⟩ m * zero + zero ≡⟨ +-right-i...
open import Structures --using (KS; SKS; ks; TCS; Prog; monadTC; _⊕_; Err; ok; error; list-has-el; lift-state; lift-mstate) open import Reflection as RE hiding (return; _>>=_; _>>_) open import Reflection.Show module Extract (kompile-fun : Type → Term → Name → SKS Prog) where open import Reflection.Term import R...
-- WARNING: This file was generated automatically by Vehicle -- and should not be modified manually! -- Metadata -- - Agda version: 2.6.2 -- - AISEC version: 0.1.0.1 -- - Time generated: ??? {-# OPTIONS --allow-exec #-} open import Vehicle open import Data.Unit open import Data.Integer as ℤ using (ℤ) open import D...
-- Issue reported by Sergei Meshvelliani -- Simplified example by Guillaume Allais -- When adding missing absurd clauses, dot patterns were accidentally -- turned into variable patterns. {-# OPTIONS --allow-unsolved-metas #-} open import Agda.Builtin.List open import Agda.Builtin.Equality data Var (T : Set₂) (σ : ...
-- Forced constructor arguments don't count towards the size of the datatype -- (only if not --withoutK). data _≡_ {a} {A : Set a} : A → A → Set where refl : ∀ x → x ≡ x data Singleton {a} {A : Set a} : A → Set where [_] : ∀ x → Singleton x
{-# OPTIONS --without-K --safe #-} module Dodo.Unary.Disjoint where -- Stdlib imports open import Level using (Level; _⊔_) open import Data.Empty using (⊥) open import Relation.Unary using (Pred) -- Local imports open import Dodo.Unary.Empty open import Dodo.Unary.Intersection -- # Definitions Disjoint₁ : ∀ {a ℓ₁ ...
------------------------------------------------------------------------------ -- A looping (error) combinator ------------------------------------------------------------------------------ {-# OPTIONS --exact-split #-} {-# OPTIONS --no-sized-types #-} {-# OPTIONS --no-universe-polymorphism #-} ...
{-# OPTIONS --without-K #-} open import Level.NP open import Type hiding (★) open import Type.Identities open import Function.NP open import Function.Extensionality open import Data.Product open import Data.Sum open import Relation.Binary.Logical open import Relation.Binary.PropositionalEquality.NP open import Relation...
module Issue204.Dependency where open import Common.Level public renaming (lsuc to suc) record R (ℓ : Level) : Set (suc ℓ) where data D (ℓ : Level) : Set (suc ℓ) where module M {ℓ : Level} (d : D ℓ) where
------------------------------------------------------------------------ -- Coherently constant functions ------------------------------------------------------------------------ {-# OPTIONS --erased-cubical --safe #-} import Equality.Path as P module Coherently-constant {e⁺} (eq : ∀ {a p} → P.Equality-with-paths ...
{- https://serokell.io/blog/playing-with-negation Constructive and Non-Constructive Proofs in Agda (Part 3): Playing with Negation Danya Rogozin Friday, November 30th, 2018 Present an empty type to work with constructive negation. Discuss Markov’s principle and apply this principle for one use case. Declare the do...
{-# OPTIONS --without-K #-} module semisimplicial where open import Agda.Primitive open import Data.Nat open import big-endian -- N-truncated, augmented semisimplicial types. -- Universe polymorphism has not been added yet -- (should be very easy, at the cost of even more bloat of type signatures). -- T...
-- Andreas, 2020-04-15, issue #4586 -- Better error for invalid let pattern. test : Set₁ test = let () = Set in Set -- WAS: -- Set₁ should be empty, but that's not obvious to me -- when checking that the pattern () has type Set₁ -- EXPECTED: -- Not a valid let pattern -- when scope checking let () = Set in S...
{-# OPTIONS --without-K #-} module Preliminaries where open import lib.Basics hiding (_⊔_) open import lib.NType2 open import lib.types.Nat hiding (_+_) open import lib.types.Pi open import lib.types.Sigma hiding (×-comm) open import lib.types.Unit open import lib.types.TLevel open import lib.types.Paths -- Most of...
{-# OPTIONS --type-in-type #-} -- NOT SOUND! open import Data.Empty using (⊥) open import Data.Nat renaming (ℕ to Nat) open import Data.Nat.DivMod open import Data.Product hiding (map) open import Data.Unit using (⊤) module x where {- https://webspace.science.uu.nl/~swier004/publications/2019-...
module Issue228 where open import Common.Level postulate ∞ : Level data _×_ {a b} (A : Set a) (B : Set b) : Set (a ⊔ b) where _,_ : A → B → A × B data Large : Set ∞ where large : Large data Small : Set₁ where small : Set → Small P : Set P = Large × Small [_] : Set → P [ A ] = (large , small A) potentia...
{-# OPTIONS --cubical --no-import-sorts --safe #-} module Cubical.Papers.HigherGroupsViaDURG where -- Johannes Schipp von Branitz, -- "Higher Groups via Displayed Univalent Reflexive Graphs in Cubical Type Theory". import Cubical.Algebra.Group as Group import Cubical.Core.Glue as Glue import Cubical.Data.Sigma.Pro...
open import Mockingbird.Forest using (Forest) -- Aristocratic Birds module Mockingbird.Problems.Chapter19 {ℓb ℓ} (forest : Forest {ℓb} {ℓ}) where open import Data.Product using (_×_; _,_; ∃-syntax) open import Function using (_$_) open import Level using (_⊔_) open import Data.Vec using ([]; _∷_) open import Relation...
{- Define finitely generated ideals of commutative rings and show that they are an ideal. Parts of this should be reusable for explicit constructions of free modules over a finite set. -} {-# OPTIONS --safe #-} module Cubical.Algebra.CommRing.FGIdeal where open import Cubical.Foundations.Prelude open import Cu...
module Luau.Var where open import Agda.Builtin.Bool using (true; false) open import Agda.Builtin.Equality using (_≡_) open import Agda.Builtin.String using (String; primStringEquality) open import Agda.Builtin.TrustMe using (primTrustMe) open import Properties.Dec using (Dec; yes; no) open import Properties.Equality u...
------------------------------------------------------------------------------ -- Testing the translation of the propositional functions ------------------------------------------------------------------------------ {-# OPTIONS --exact-split #-} {-# OPTIONS --no-sized-types #-} {-# OPTIONS --no-...
open import Prelude module Implicits.Semantics.Term where open import Implicits.Syntax open import Implicits.WellTyped open import Implicits.Semantics.Type open import Implicits.Semantics.Context open import Implicits.Semantics.Lemmas open import Implicits.Semantics.RewriteContext open import SystemF.Everything as F ...
open import Agda.Builtin.String open import Agda.Builtin.Equality _ : primShowChar 'c' ≡ "'c'" _ = refl _ : primShowString "ccc" ≡ "\"ccc\"" _ = refl
module GGT.Bundles where open import Level open import Relation.Unary open import Relation.Binary -- using (Rel) open import Algebra.Core open import Algebra.Bundles open import GGT.Structures open import Data.Product -- do we need a left action definition? -- parametrize over Op r/l? record Action a b ℓ₁ ℓ₂ : Set (s...
------------------------------------------------------------------------ -- The Agda standard library -- -- Support for reflection ------------------------------------------------------------------------ {-# OPTIONS --without-K --safe #-} module Reflection where import Agda.Builtin.Reflection as Builtin -----------...
{-# OPTIONS --without-K --safe #-} open import Algebra module Data.FingerTree.Structures {r m} (ℳ : Monoid r m) where open import Level using (_⊔_) open import Data.Product open import Relation.Unary open import Data.FingerTree.Measures ℳ open import Data.FingerTree.Reasoning ℳ open Monoid ℳ renaming (Carrie...
postulate foo = Foo -- Error message is: -- A postulate block can only contain type signatures or instance blocks
module Haskell.Prim.Monoid where open import Agda.Builtin.Unit open import Haskell.Prim open import Haskell.Prim.Bool open import Haskell.Prim.List open import Haskell.Prim.Maybe open import Haskell.Prim.Either open import Haskell.Prim.Tuple -------------------------------------------------- -- Semigroup record Se...
module RewriteAndUniversePolymorphism where open import Common.Equality data ℕ : Set where zero : ℕ suc : ℕ → ℕ test : (a b : ℕ) → a ≡ b → b ≡ a test a b eq rewrite eq = refl
-- Basic intuitionistic logic of proofs, without ∨, ⊥, or +. -- Gentzen-style formalisation of syntax with context pairs. -- Simple terms. module BasicILP.Syntax.DyadicGentzen where open import BasicILP.Syntax.Common public -- Types, or propositions. -- [ Ψ ⁏ Ω ⊢ t ] A means t is a proof of the fact that the type A...
{- 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.Base.Types open import LibraBFT.ImplShared.Consens...
open import and-example public open import ex-andreas-abel public
{-# OPTIONS --show-irrelevant #-} postulate A : Set f : .A → A data _≡_ (x : A) : A → Set where refl : x ≡ x mutual X : .A → A X = _ Y : A → A Y = {!λ x → x!} Z : A → A Z = {!λ x → x!} test : ∀ x → X (Y x) ≡ f (Z x) test x = refl
module Adjoint where open import Level open import Data.Product open import Basic open import Category import Functor import Nat open Category.Category open Functor.Functor open Nat.Nat open Nat.Export record Adjoint {C₀ C₁ ℓ D₀ D₁ ℓ′} {C : Category C₀ C₁ ℓ} {D : Category D₀ D₁ ℓ′} (F : Functor.Functor C D) (G : Fu...
------------------------------------------------------------------------------ -- Properties for the equality on streams ------------------------------------------------------------------------------ {-# OPTIONS --exact-split #-} {-# OPTIONS --no-sized-types #-} {-# OPTIONS --no-universe-polymor...
{-# OPTIONS --safe #-} module Cubical.Categories.Limits.Terminal where open import Cubical.Foundations.Prelude open import Cubical.Data.Sigma open import Cubical.Foundations.HLevels open import Cubical.Categories.Category open import Cubical.Categories.Functor private variable ℓ ℓ' : Level module _ (C : Preca...
-- Andreas, 2017-01-13, issue #2403 open import Common.Nat postulate P : Nat → Set f : ∀{n} → P n → P (pred n) test : ∀ n → P n → Set test zero p = Nat test (suc n) p = test _ (f p) -- WAS: -- The meta-variable is solved to (pred (suc n)) -- Termination checking fails. -- NOW: If the termination checker nor...
module VecSN where open import Data.Bool infixr 20 _◎_ ------------------------------------------------------------------------------ -- fix a field F_3 = {0, 1, -1} -- types B (ZERO,ONE,PLUS,TIMES) determine the DIMENSION of a vector space over F_3 -- values of type B are INDICES for B-dimensional vectors...
{-# OPTIONS --without-K --safe #-} module Polynomial.Simple.AlmostCommutativeRing.Instances where open import Polynomial.Simple.AlmostCommutativeRing open import Level using (0ℓ) open import Agda.Builtin.Reflection module Nat where open import Data.Nat using (zero; suc) open import Relation.Binary.PropositionalE...
{-# OPTIONS --safe #-} module Issue2487.b where -- trying to import a cubical, non-safe module open import Issue2487.c