text stringlengths 4 690k |
|---|
-- Product of type-many categories
{-# OPTIONS --safe #-}
module Cubical.Categories.Constructions.Product where
open import Cubical.Categories.Category.Base
open import Cubical.Categories.Functor.Base
open import Cubical.Foundations.HLevels
open import Cubical.Foundations.Prelude
private
variable
ℓA ℓC ℓC' : L... |
{-# OPTIONS --cubical --no-import-sorts --safe #-}
module Cubical.Categories.Category.Properties where
open import Cubical.Core.Glue
open import Cubical.Foundations.Prelude
open import Cubical.Foundations.HLevels
open import Cubical.Categories.Category.Base hiding (isSetHom)
open Precategory
private
variable
... |
module Assume where
postulate
assume : ∀ {a} {A : Set a} → A |
{-# OPTIONS --sized-types #-}
module BinTree where
open import Data.Nat
open import Data.List
open import Data.List.Properties
open import Size
data Bin {T : Set} {i : Size} : Set where
Leaf : Bin {T} {i}
Node : T → Bin {T} {i} → Bin {T} {i} → Bin {T} {i}
data Rose {T : Set} {i : Size} : Set where
Empty : Rose... |
{-# OPTIONS --without-K --safe #-}
open import Algebra.Structures.Bundles.Field
module Algebra.Structures.Field.Utils
{k ℓ} (K : Field k ℓ)
where
open Field K hiding (zero)
open import Data.Fin
import Data.Nat as Nat
private
K' : Set k
K' = Carrier
δ : ∀ {n p} -> Fin n -> Fin p -> K'
δ zero zero = 1#
δ (s... |
module Data.Num.Bij where
open import Data.List hiding ([_])
open import Relation.Binary
open import Relation.Binary.PropositionalEquality as PropEq
using (_≡_; _≢_)
import Level
--------------------------------------------------------------------------------
-- Bijective Numeration
--
-- A numeral system which h... |
{-# OPTIONS --without-K #-}
module NTypes.HedbergsTheorem where
open import GroupoidStructure
open import NTypes
open import NTypes.Negation
open import PathOperations
open import Transport
open import Types
stable : ∀ {a} → Set a → Set a
stable A = ¬ ¬ A → A
dec : ∀ {a} → Set a → Set a
dec A = A ⊎ ¬ A
dec→stable :... |
{-# OPTIONS --safe --experimental-lossy-unification #-}
module Cubical.Algebra.Polynomials.Multivariate.EquivCarac.AB-An[X]Bn[X] where
open import Cubical.Foundations.Prelude
open import Cubical.Foundations.Equiv
open import Cubical.Foundations.Isomorphism
open import Cubical.Foundations.HLevels
open import Cubical.D... |
module Imports.Issue5357-D where
A : Set₁
A = Set₁
|
{-# OPTIONS --rewriting #-}
data _≅_ {ℓ} {A : Set ℓ} (x : A) : {B : Set ℓ} → B → Set where
refl : x ≅ x
{-# BUILTIN REWRITE _≅_ #-}
|
-- Andreas, 2011-04-07
module IrrelevantTelescopeRecord where
record Wrap .(A : Set) : Set where
field
out : A
-- cannot use A, because it is declared irrelevant
|
{-# BUILTIN STRING String #-}
record ⊤ : Set where
constructor tt
data Bool : Set where
true false : Bool
nonEmpty : String → Set
nonEmpty "" = Bool
nonEmpty _ = ⊤
foo : ∀ s → nonEmpty s → Bool
foo "" true = true
foo "" false = false
foo s p = false
|
{-# OPTIONS --universe-polymorphism #-}
module Categories.Functor.Representable where
open import Level
open import Categories.Category
open import Categories.Agda
open import Categories.Functor using (Functor)
open import Categories.Functor.Hom
open import Categories.NaturalIsomorphism
record Representable {o ℓ e} ... |
-- Define the integers as a HIT by identifying +0 and -0
{-# OPTIONS --cubical --safe #-}
module Cubical.HITs.Ints.QuoInt.Base where
open import Cubical.Core.Everything
open import Cubical.Foundations.Prelude
open import Cubical.Foundations.Equiv
open import Cubical.Foundations.Transport
open import Cubical.Foundatio... |
module examplesPaperJFP.exampleFinFun where
open import examplesPaperJFP.finn
open import Data.Nat
toℕ : ∀ {n} → Fin n → ℕ
toℕ zero = 0
toℕ (suc n) = suc (toℕ n)
mutual
_+e_ : ∀ {n m} → Even n → Even m → Even (n + m)
0p +e p = p
sucp p +e q = sucp (p +o q)
_+o_ : ∀ {n m} → Od... |
module Singleton where
open import Data.List
using (List ; [] ; _∷_)
open import Data.List.All
using (All ; [] ; _∷_)
open import Membership
using (_∈_; _⊆_ ; _∷_ ; [])
[_]ˡ : ∀{a}{A : Set a} → A → List A
[ a ]ˡ = a ∷ []
[_]ᵃ : ∀{a p} {A : Set a} {P : A → Set p} {x : A} → P x → All P (x ∷ [])
[ p ]ᵃ = p ∷ []
... |
-- Coalgebraic strength over an endofunctor
module SOAS.Coalgebraic.Strength {T : Set} where
open import SOAS.Common
open import SOAS.Context
open import SOAS.Variable
open import SOAS.Families.Core {T}
open import SOAS.Abstract.Hom {T}
import SOAS.Abstract.Coalgebra {T} as →□ ; open →□.Sorted
open import SOAS.Coalg... |
{-# OPTIONS --without-K --safe #-}
open import Categories.Category
module Categories.Functor.Core where
open import Level
private
variable
o ℓ e o′ ℓ′ e′ : Level
record Functor (C : Category o ℓ e) (D : Category o′ ℓ′ e′) : Set (o ⊔ ℓ ⊔ e ⊔ o′ ⊔ ℓ′ ⊔ e′) where
eta-equality
private module C = Category C
... |
{-# OPTIONS --cubical --no-import-sorts #-}
open import Bundles
module Properties.ConstructiveField {ℓ ℓ'} (F : ConstructiveField {ℓ} {ℓ'}) where
open import Agda.Primitive renaming (_⊔_ to ℓ-max; lsuc to ℓ-suc; lzero to ℓ-zero)
private
variable
ℓ'' : Level
open import Cubical.Foundations.Everything renaming... |
{-# OPTIONS --without-K #-}
module sets.bool where
open import sets.empty using (⊥)
open import sets.unit using (⊤)
open import decidable using (Dec; yes; no)
open import equality.core using (_≡_; refl)
open import level using (Level)
infixr 6 _∧_
infixr 5 _∨_ _xor_
infix 0 if_then_else_
data ... |
open import Relation.Binary.Core
module BBHeap.Everything {A : Set}
(_≤_ : A → A → Set)
(tot≤ : Total _≤_)
(trans≤ : Transitive _≤_) where
open import BBHeap.Complete.Base _≤_
open import BBHeap.Drop _≤_ tot≤ trans≤
open import BBHeap.DropLast _≤_
open import BBHe... |
------------------------------------------------------------------------
-- The Agda standard library
--
-- List-related properties
------------------------------------------------------------------------
-- Note that the lemmas below could be generalised to work with other
-- equalities than _≡_.
{-# OPTIONS --witho... |
{-# OPTIONS --cubical --safe #-}
module Cardinality.Finite.ManifestEnumerable.Isomorphism where
open import Prelude
import Cardinality.Finite.ManifestEnumerable.Container as ℒ
import Cardinality.Finite.ManifestEnumerable.Inductive as 𝕃
open import Container.List.Isomorphism
open import Data.Fin
open import HITs.Pr... |
data Tree : Set where
leaf : Tree
_∣_ : Tree → Tree → Tree
{-# FOREIGN GHC data Tree = Leaf | Tree :| Tree #-}
{-# COMPILE GHC Tree = data Tree (Leaf | (:|)) #-}
|
------------------------------------------------------------------------
-- The Agda standard library
--
-- Finite sets
------------------------------------------------------------------------
{-# OPTIONS --without-K --safe #-}
module Data.Fin where
open import Relation.Nullary.Decidable.Core
open import Data.Nat.Ba... |
{-# OPTIONS --without-K --safe #-}
module Definition.Conversion.Universe where
open import Definition.Untyped hiding (_∷_)
open import Definition.Typed
open import Definition.Typed.Properties
open import Definition.Typed.RedSteps
open import Definition.Conversion
open import Definition.Conversion.Reduction
open impor... |
------------------------------------------------------------------------
-- Morphisms between algebraic structures
------------------------------------------------------------------------
module Algebra.Morphism where
open import Relation.Binary
open import Algebra
open import Algebra.FunctionProperties
open import D... |
{-# OPTIONS --type-in-type #-} -- yes, there will be some cheating in this lecture
module Lec3Done where
open import Lec1Done
open import Lec2Done
postulate
extensionality : {S : Set}{T : S -> Set}
{f g : (x : S) -> T x} ->
((x : S) -> f x == g x) ->
f == g... |
{-# OPTIONS --safe --experimental-lossy-unification #-}
module Cubical.Algebra.CommAlgebra.Properties where
open import Cubical.Foundations.Prelude
open import Cubical.Foundations.Equiv
open import Cubical.Foundations.HLevels
open import Cubical.Foundations.Isomorphism
open import Cubical.Foundations.Equiv.HalfAdjoint... |
module Krivine (Atom Const : Set) where
open import Data.Nat
open import Data.Sum
open import Data.Vec as Vec using (Vec; _∷_; [])
data Type : Set where
atom : Atom → Type
_⇒_ : Type → Type → Type
Basis : ℕ → Set
Basis = Vec Type
data Var : ∀ {n} → Basis n → Type → Set where
vzero : ∀ {n} {Γ : Basis n} {τ}... |
{-# OPTIONS --safe --warning=error --without-K #-}
open import Sets.EquivalenceRelations
open import Functions.Definition
open import Agda.Primitive using (Level; lzero; lsuc; _⊔_; Setω)
open import Setoids.Setoids
open import Groups.Definition
open import LogicalFormulae
open import Orders.WellFounded.Definition
open... |
open import Data.Product using ( _,_ )
open import Web.Semantic.DL.ABox using ( ε )
open import Web.Semantic.DL.Category.Object using ( Object ; _,_ )
open import Web.Semantic.DL.Signature using ( Signature )
open import Web.Semantic.DL.TBox using ( TBox )
open import Web.Semantic.Util using ( False ; False∈Fin )
modu... |
-- Andreas, 2016-07-29 issue #707, comment of 2012-10-31
data Bool : Set where true false : Bool
mutual
data D : Bool → Set where
c d : D ?
fixIx : (b : Bool) → D b → D b
fixIx true c = c
fixIx false d = d
-- Works, but maybe questionable.
-- The _ is duplicated into two different internal metas.
|
{-# OPTIONS --without-K --safe #-}
module TypeTheory.HoTT.Relation.Nullary.Negation.Properties where
-- agda-stdlib
open import Axiom.Extensionality.Propositional
open import Level renaming (zero to lzero)
open import Relation.Nullary
-- agda-misc
open import TypeTheory.HoTT.Base
open import TypeTheory.HoTT.Data.Emp... |
module Function.Inverse where
open import Data.Tuple as Tuple using (_⨯_ ; _,_)
import Lvl
open import Logic
open import Logic.Propositional
open import Logic.Predicate
open import Functional
open import Function.Equals
open import Function.Equals.Proofs
open import Function.Inverseₗ
open import Function.Inverseᵣ... |
module Luau.Value where
open import Luau.Addr using (Addr)
open import Luau.Syntax using (Block; Expr; nil; addr; function⟨_⟩_end)
open import Luau.Var using (Var)
data Value : Set where
nil : Value
addr : Addr → Value
val : Value → Expr
val nil = nil
val (addr a) = addr a
|
{-# OPTIONS --cubical --no-import-sorts --safe #-}
module Cubical.Relation.Binary.Raw.Construct.Constant where
open import Cubical.Core.Everything
open import Cubical.Foundations.Prelude
open import Cubical.Foundations.HLevels using (hProp)
open import Cubical.Relation.Binary.Raw
------------------------------------... |
{-# OPTIONS --allow-unsolved-metas #-}
module MGU-revised where
--open import Agda.Builtin.Nat using () renaming (Nat to ℕ)
open import Agda.Primitive
open import Agda.Builtin.Equality
open import Prelude.Product using (Σ; _,_; fst; snd; _×_; curry; uncurry)
open import Prelude.Equality using (eqReasoningStep; _∎; sy... |
open import Prelude
open import Nat
open import core
open import contexts
open import weakening
open import exchange
open import lemmas-disjointness
open import binders-disjoint-checks
module lemmas-subst-ta where
-- this is what makes the binders-unique assumption below good enough: it
-- tells us that we can pic... |
open import OutsideIn.Prelude
open import OutsideIn.X
module OutsideIn(x : X) where
open X (x) public
open import OutsideIn.Prelude public
open import Data.Vec public hiding ([_])
import OutsideIn.Constraints as C
import OutsideIn.TypeSchema as TS
import OutsideIn.Expressions as E
import OutsideIn.Enviro... |
{-# OPTIONS --cubical --postfix-projections --safe #-}
module Karatsuba where
open import Prelude
open import Data.List
open import Data.List.Syntax
open import TreeFold
open import Data.Integer
import Data.Nat as ℕ
open import Literals.Number
open import Data.Integer.Literals
Diff : Type a → Type a
Diff A = Li... |
open import Level using (Level; suc; zero; _⊔_)
open import Algebra.Structures
open import Algebra.FunctionProperties as FunctionProperties using (Op₁; Op₂)
open import Relation.Binary
-- Definition of an ordered monoid, which adds the law that ∙ must
-- preserve the partial order ≤ (or, equivalently, that an ordering... |
module Tools where
import PolyDepPrelude
-- import Sigma
-- import And
open PolyDepPrelude using(Datoid; Bool; true; false; _&&_; Nat; True; Taut; unit)
liftAnd : (a : Bool)(b : Bool)(ta : True a)(tb : True b) -> True (a && b)
liftAnd (true) (true) ta tb = unit
liftAnd (true) (false) ta () -- empty
liftAnd (fa... |
{-# OPTIONS --without-K #-}
module Leftovers.TraverseTerm where
open import Data.List
-- We only need the writer monad, but as far as I can tell
-- it's not in the Agda stdlib
open import Category.Monad.State
open import Reflection using (Term ; Meta ; Name ; Arg)
import Leftovers.Everywhere
open import Relation.Bin... |
{-# OPTIONS --without-K --safe #-}
open import Categories.Category using (Category)
open import Categories.Category.Monoidal using (Monoidal)
open import Categories.Category.Monoidal.Closed using (Closed)
module Categories.Category.Monoidal.Closed.IsClosed.L
{o ℓ e} {C : Category o ℓ e} {M : Monoidal C} (Cl : Close... |
-- Andreas, 2011-10-02
module IrrelevantLambdasDoNotNeedDotsAlways where
bla : ((.Set → Set1) → Set1) -> Set1
bla f = f (λ x → Set)
-- here, the lambda does not need a dot, like in (λ .x → Set)
-- because the dot from the function space can be taken over |
open import Data.Empty using ( ⊥ )
open import Data.Nat using ( ℕ ; zero ; suc ; _+_ ; _≤_ ; z≤n ; s≤s )
open import Relation.Binary.PropositionalEquality using ( _≡_ ; refl ; sym ; cong )
open import Relation.Binary.PropositionalEquality.TrustMe using ( trustMe )
open import Relation.Nullary using ( ¬_ )
module FRP.L... |
open import Coinduction using ( ♭ )
open import Data.Empty using ( ⊥-elim )
open import Data.Sum using ( _⊎_ ; inj₁ ; inj₂ )
open import System.IO.Transducers.Lazy
using ( _⇒_ ; inp ; out ; done ; ⟦_⟧ ; _≃_ ; out' ; out* ;
_⟫_ ;_[&]_ ; unit₁ ; unit₂ ; assoc ; assoc⁻¹ ; swap'' ; swap' ; swap )
open import System... |
{-# OPTIONS --cubical --no-import-sorts #-}
open import Agda.Primitive renaming (_⊔_ to ℓ-max; lsuc to ℓ-suc; lzero to ℓ-zero)
module Number.Inclusions where
open import Cubical.Foundations.Everything renaming (_⁻¹ to _⁻¹ᵖ; assoc to ∙-assoc)
open import Cubical.Relation.Nullary.Base -- ¬_
open import Cubical.Relatio... |
{-# OPTIONS --safe #-}
module Cubical.Algebra.CommAlgebra.Kernel where
open import Cubical.Foundations.Prelude
open import Cubical.Foundations.Equiv
open import Cubical.Algebra.CommRing.Base
open import Cubical.Algebra.CommRing.Ideal using (Ideal→CommIdeal)
open import Cubical.Algebra.Ring.Kernel using () renaming (k... |
module Prelude.Ord.Reasoning where
open import Prelude.Equality
open import Prelude.Ord
open import Prelude.Function
module _ {a} {A : Set a} {{OrdA : Ord/Laws A}} where
private
lt/leq-trans : ∀ {x y z : A} → x < y → y ≤ z → x < z
lt/leq-trans x<y y≤z =
case leq-to-lteq {A = A} y≤z of λ where
... |
module ModuleInfix where
open import Data.List using (List; _∷_; [])
open import Data.Bool using (Bool; true; false)
module Sort(A : Set)(_≤_ : A → A → Bool)(_⊝_ : A → A → A)(zero : A) where
infix 1 _≤_
infix 2 _⊝_
insert : A → List A → List A
insert x [] = x ∷ []
insert x (y ∷ ys) with zero ≤ (y ⊝ x)
i... |
{- 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
-}
module Optics.All where
open import Optics.Functorial public
open import Op... |
open import Relation.Binary.PropositionalEquality using (_≡_; refl; sym; trans; subst; cong)
open import Syntax
import Renaming
-- Substitutions
module Substitution where
module _ {𝕊 : Signature} where
open Expression 𝕊
open Renaming
open Equality
infix 5 _∥_→ˢ_
-- the set of substitutions... |
{-# OPTIONS --without-K #-}
--
-- This module defines/proves some basic functions/theorem using only
-- the induction principle of the equality types the way they are done
-- in the HoTT book. The functions defined/theorems proved in this
-- module is often exposed in a better way from the main equality
-- module, th... |
{-# OPTIONS --without-K --exact-split #-}
module rational-numbers where
import integers
open integers public
--------------------------------------------------------------------------------
{- We introduce the type of non-zero integers. -}
ℤ\0 : UU lzero
ℤ\0 = Σ ℤ (λ k → ¬ (Id zero-ℤ k))
int-ℤ\0 : ℤ\0 → ℤ
int-ℤ\0... |
-- Christian Sattler, 2013-12-31
-- Testing eta-expansion of bound record metavars, as implemented by Andreas.
module Issue376-2 where
{- A simple example. -}
module example-0 {A B : Set} where
record Prod : Set where
constructor _,_
field
fst : A
snd : B
module _ (F : (Prod → Set) → Set) wher... |
module _ where
module M where
data D : Set where
c : D
private
pattern c′ = c
open M
x : D
x = c′
|
open import Nat
open import Prelude
open import dynamics-core
module lemmas-progress-checks where
-- boxed values don't have an instruction transition
boxedval-not-trans : ∀{d d'} → d boxedval → d →> d' → ⊥
boxedval-not-trans (BVVal VNum) ()
boxedval-not-trans (BVVal VLam) ()
boxedval-not-trans (BVArrCast x ... |
module Structure.Category.Functor where
open import Functional using (_on₂_)
open import Lang.Instance
import Lvl
open import Logic.Predicate
open import Structure.Category
open import Structure.Function
open import Structure.Function.Multi
import Structure.Relator.Names as Names
open import Structure.Setoid... |
-- exercises-03-wednesday.agda
open import mylib
{-
Part 1 : Recursion via patterns
Define the following functions using pattern matching and structural
recursion on the natural numbers.
-}
-- Define a function even that determines wether its input is even.
even : ℕ → Bool
{-
even zero = true
even (suc n)... |
{-
Agda file from the exercise session(s).
-}
{-# OPTIONS --without-K #-}
open import Agda.Primitive
{-
Two inductive implementations of the
Martin-Löf identity type
aka
equality type
aka
identification type
aka
path type.
-}
data _≡_ {A : Set} (a : A) : A → Set where
refl : a ≡ a
i... |
module par-swap.dpg-pot where
open import Data.Empty
open import Data.Product
open import Data.Sum
open import Data.Bool
open import Data.List using ([] ; [_] ; _∷_ ; List ; _++_)
open import Relation.Binary.PropositionalEquality
using (_≡_ ; refl ; sym)
open import Data.Maybe using ()
open import Data.List.Any usin... |
module Pi.NoRepeat where
open import Data.Empty
open import Data.Unit
open import Data.Sum
open import Data.Product
open import Relation.Binary.PropositionalEquality
open import Pi.Syntax
open import Pi.Opsem
open import Pi.AuxLemmas
import RevNoRepeat
-- Forward deterministic
deterministic : ∀ {st st₁ st₂} → st ↦ st₁... |
module examplesPaperJFP.BasicIO where
open import Data.Maybe hiding ( _>>=_ )
open import Data.Sum renaming (inj₁ to left; inj₂ to right; [_,_]′ to either)
open import Function
open import examplesPaperJFP.NativeIOSafe
open import examplesPaperJFP.triangleRightOperator
module _ where -- for indentation
record IOI... |
module _ where
data Nat : Set where
zero : Nat
suc : Nat → Nat
data L : Nat → Set where
nil : L zero
cons : ∀ n → L n → L (suc n)
pattern one = cons .zero nil
|
------------------------------------------------------------------------
-- The Agda standard library
--
-- Integer division
------------------------------------------------------------------------
module Data.Nat.DM where
open import Data.Fin as Fin using (Fin; toℕ)
import Data.Fin.Properties as FinP
open import Dat... |
{-# OPTIONS --without-K #-}
{- Our goal in this file is to observe some structure possessed by the
universes of types, reflexive graphs, type families, and so on. Somewhat
more precisely, we develop an imperfect structure of internal model of type
theory, with enough ingredients to get some type theoretic dev... |
-- An ATP local hint can be only a postulate, function or a data
-- constructor.
-- This error is detected by Syntax.Translation.ConcreteToAbstract.
module ATPBadLocalHint3 where
postulate
D : Set
_≡_ : D → D → Set
zero : D
succ : D → D
data N : D → Set where
zN : N zero
sN : ∀ {n} → N... |
------------------------------------------------------------------------
-- The reader monad transformer
------------------------------------------------------------------------
-- The interface is based on that used by the "mtl" package on
-- Hackage.
{-# OPTIONS --without-K --safe #-}
open import Equality
module ... |
open import Agda.Builtin.Equality
open import Agda.Primitive
record R a : Set (lsuc a) where
field
P : {A : Set a} → A → A → Set a
r : ∀ ℓ → R ℓ
R.P (r _) = _≡_
postulate
cong : ∀ {a b} {A : Set a} {B : Set b} {x y : A}
(f : A → B) → R.P (r a) x y → R.P (r b) (f x) (f y)
magic : ∀ {a} {A : Set a... |
module Categories.2-Category.Categories where
open import Level
open import Data.Product
open import Categories.Category
open import Categories.2-Category
open import Categories.Functor using (module Functor) renaming (id to idF; _∘_ to _∘F_)
open import Categories.Functor.Constant
open import Categories.FunctorCateg... |
module Data.Num where
open import Data.List using (List; []; _∷_; foldr)
open import Data.Nat
open ≤-Reasoning
open import Data.Nat.Etc
open import Data.Nat.DivMod
open import Data.Nat.DivMod.Properties using (div-mono)
open import Data.Nat.Properties using (m≤m+n; n≤m+n;_+-mono_; pred-mono; ∸-mono; ≰⇒>; n∸n≡0; +-∸-... |
-- Various small test cases that failed at some point or another
-- during the development of the parameter refinement feature.
module _ where
open import Agda.Primitive
open import Agda.Builtin.Nat hiding (_<_)
open import Agda.Builtin.Bool
open import Agda.Builtin.Equality
open import Agda.Builtin.List
[_≡_] : ∀ {... |
------------------------------------------------------------------------
-- Indexed applicative functors
------------------------------------------------------------------------
-- Note that currently the applicative functor laws are not included
-- here.
module Category.Applicative.Indexed where
open import Data.Fu... |
-- Andreas, 2017-08-24, issue #2253
--
-- Better error message for matching on abstract constructor.
-- {-# OPTIONS -v tc.lhs.split:30 #-}
-- {-# OPTIONS -v tc.lhs:30 #-}
-- {-# OPTIONS -v tc.lhs.flex:60 #-}
abstract
data B : Set where
x : B
data C : Set where
c : B → C
f : C → C
f (c x) = c x
-- WAS:
--
-... |
{-# OPTIONS --without-K --safe #-}
-- Actually, we're cheating (for expediency); this is
-- Symmetric Rig, not just Rig.
open import Categories.Category
module Categories.Category.RigCategory {o ℓ e} (C : Category o ℓ e) where
open import Level
open import Data.Fin renaming (zero to 0F; suc to sucF)
open import Data.... |
{-# OPTIONS --safe #-}
module Cubical.Algebra.CommRing.QuotientRing where
open import Cubical.Foundations.Prelude
open import Cubical.Foundations.Structure
open import Cubical.Foundations.Powerset
open import Cubical.Data.Nat
open import Cubical.Data.FinData
open import Cubical.HITs.SetQuotients using ([_]; squash/;... |
{-# OPTIONS --without-K --safe #-}
module Data.Binary.Increment where
open import Data.Binary.Definition
open import Strict
inc : 𝔹 → 𝔹
inc 0ᵇ = 1ᵇ 0ᵇ
inc (1ᵇ xs) = 2ᵇ xs
inc (2ᵇ xs) = 1ᵇ inc xs
|
module Agda.Builtin.Strict where
open import Agda.Builtin.Equality
primitive
primForce : ∀ {a b} {A : Set a} {B : A → Set b} (x : A) → (∀ x → B x) → B x
primForceLemma : ∀ {a b} {A : Set a} {B : A → Set b} (x : A) (f : ∀ x → B x) → primForce x f ≡ f x
|
------------------------------------------------------------------------
-- The Agda standard library
--
-- Pointwise lifting of binary relations to sigma types
------------------------------------------------------------------------
{-# OPTIONS --without-K --safe #-}
module Data.Product.Relation.Binary.Pointwise.Dep... |
open import Mockingbird.Forest using (Forest)
module Mockingbird.Forest.Extensionality {b ℓ} (forest : Forest {b} {ℓ}) where
open import Algebra using (RightCongruent)
open import Relation.Binary using (Rel; IsEquivalence; Setoid)
open import Level using (_⊔_)
open Forest forest
-- TODO: if the arguments to the pre... |
-- 2012-02-13 Andreas: testing correct polarity of data types
-- sized types are the only source of subtyping, I think...
-- {-# OPTIONS -v tc.polarity.set:10 #-}
-- {-# OPTIONS -v tc.size.solve:20 #-}
{-# OPTIONS --show-implicit #-}
{-# OPTIONS --sized-types #-}
module DataPolarity where
open import Common.Size
dat... |
{-# OPTIONS --without-K --rewriting #-}
open import lib.Basics
open import lib.types.Bool
open import lib.types.FunctionSeq
open import lib.types.Pointed
open import lib.types.Suspension.Core
open import lib.types.Suspension.Iterated
open import lib.types.Suspension.Trunc
open import lib.types.TLevel
open import lib.t... |
{-# OPTIONS --no-sized-types --no-guardedness #-}
module Agda.Builtin.TrustMe where
open import Agda.Builtin.Equality
open import Agda.Builtin.Equality.Erase
private
postulate
unsafePrimTrustMe : ∀ {a} {A : Set a} {x y : A} → x ≡ y
primTrustMe : ∀ {a} {A : Set a} {x y : A} → x ≡ y
primTrustMe = primEraseEquali... |
{-# OPTIONS --safe #-}
module Cubical.Data.NatPlusOne.MoreNats.AssocNat.Properties where
open import Cubical.Foundations.Prelude
open import Cubical.Foundations.Function
open import Cubical.Foundations.HLevels
open import Cubical.Foundations.Isomorphism
open import Cubical.Data.Nat
open import Cubical.Data.NatPlusOne... |
module UnsolvedMetas where
foo = ?
|
------------------------------------------------------------------------
-- The Agda standard library
--
-- This module is DEPRECATED. Please use Data.List.Relation.Unary.Any
-- directly.
------------------------------------------------------------------------
{-# OPTIONS --without-K --safe #-}
module Data.List.Any w... |
module TypeTheory.Nat.AnotherMono.Structure where
open import Level renaming (zero to lzero; suc to lsuc)
open import Data.Empty using (⊥)
open import Data.Product using (Σ; _×_; _,_)
open import Relation.Binary using (Rel)
open import Relation.Binary.PropositionalEquality
open import Relation.Nullary using (¬_)
reco... |
module Main where
import univ
import cwf
import help
import proofs
|
------------------------------------------------------------------------
-- The Agda standard library
--
-- Unary relations
------------------------------------------------------------------------
module Relation.Unary where
open import Data.Empty
open import Function
open import Data.Unit hiding (setoid)
open import... |
------------------------------------------------------------------------
-- Lenses defined in terms of a getter, equivalences between the
-- getter's "preimages", and a coherence property
------------------------------------------------------------------------
{-# OPTIONS --cubical --safe #-}
import Equality.Path as ... |
{-# OPTIONS --cubical --safe #-}
module Cubical.HITs.Join where
open import Cubical.HITs.Join.Base public
-- open import Cubical.HITs.Join.Properties public
|
-- imports
open import Data.Nat as ℕ using (ℕ; suc; zero; _+_; _∸_)
open import Data.Vec as Vec using (Vec; _∷_; []; tabulate; foldr)
open import Data.Fin as Fin using (Fin; suc; zero)
open import Function using (_∘_; const; id)
open import Data.List as List using (List; _∷_; [])
open import Data.Maybe... |
-- Andreas, 2020-09-28, issue #4950
-- Ranges for missing definitions should not include
-- non-missing definitions.
A B C : Set₁ -- only B should be highlighted
A = Set
C = Set
-- The following names are declared but not accompanied by a
-- definition: B
-- Error range was:
-- line,3-13
-- The error range should... |
{-# OPTIONS --without-K --safe #-}
module Dodo.Binary.Filter where
-- Stdlib imports
import Relation.Binary.PropositionalEquality as Eq
open Eq using (_≡_; _≢_; refl; subst; cong; cong₂) renaming (sym to ≡-sym; trans to ≡-trans)
open import Level using (Level; _⊔_)
open import Data.Empty using (⊥)
open import Data.Pr... |
module _ where
open import DeadCodePatSyn.Lib
typeOf : {A : Set} → A → Set
typeOf {A} _ = A
-- Check that pattern synonyms count when computing dead code
f : typeOf not-hidden → Set₁
f not-hidden = Set
|
module Hide where
record 𝔹ottom : Set₁ where
field
⊥ : Set
open 𝔹ottom ⦃ … ⦄ public
𝔹ottomPrelude : 𝔹ottom
𝔹ottomPrelude = record { ⊥ = P.⊥ } where
open import Prelude.Empty as P
instance instance𝔹ottom : 𝔹ottom
instance𝔹ottom = 𝔹ottomPrelude
|
module All where
import Prelude
import Star
import Nat
import List
import Vec
import Elem
import Fin
import Modal
import Lambda
import Span
import MapTm
import Examples
|
-- Andreas, 2020-12-15, re PR #5020
-- Test error message "Must not specify multiple frontends"
-- See respective .flags file
-- Expected error:
-- Must not specify multiple frontends (--interaction, --interaction-json)
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.