Skip to content

Commit

Permalink
remove dead code
Browse files Browse the repository at this point in the history
  • Loading branch information
stefan-aws committed Mar 4, 2024
1 parent 3e681d1 commit 87b8829
Show file tree
Hide file tree
Showing 23 changed files with 43 additions and 1,974 deletions.
24 changes: 5 additions & 19 deletions audit.log
Original file line number Diff line number Diff line change
@@ -1,23 +1,9 @@
src/DafnyVMC.dfy(28,6): UniformPowerOfTwoSample: Definition has `assume {:axiom}` statement in body.
src/Distributions/Uniform/Correctness.dfy(34,17): UniformFullCorrectness: Declaration has explicit `{:axiom}` attribute.
src/Distributions/Uniform/Model.dfy(21,33): Sample: Declaration has explicit `{:axiom}` attribute.
src/Math/Analysis/Limits.dfy(126,17): Sandwich: Declaration has explicit `{:axiom}` attribute.
src/Math/Analysis/Reals.dfy(35,17): LeastUpperBoundProperty: Declaration has explicit `{:axiom}` attribute.
src/Math/Measures.dfy(125,17): ProbabilityLe1: Declaration has explicit `{:axiom}` attribute.
src/Math/Measures.dfy(130,17): IsMonotonic: Declaration has explicit `{:axiom}` attribute.
src/ProbabilisticProgramming/Independence.dfy(105,17): BindIsIndep: Declaration has explicit `{:axiom}` attribute.
src/Distributions/Uniform/Correctness.dfy(31,17): UniformFullCorrectness: Declaration has explicit `{:axiom}` attribute.
src/Distributions/Uniform/Model.dfy(19,33): Sample: Declaration has explicit `{:axiom}` attribute.
src/Distributions/UniformPowerOfTwo/Model.dfy(19,20): Sample: Declaration has explicit `{:axiom}` attribute.
src/ProbabilisticProgramming/Independence.dfy(30,27): IsIndep: Declaration has explicit `{:axiom}` attribute.
src/ProbabilisticProgramming/Independence.dfy(55,6): ResultsIndependent: Definition has `assume {:axiom}` statement in body.
src/ProbabilisticProgramming/Independence.dfy(59,17): IsIndepImpliesMeasurableBool: Declaration has explicit `{:axiom}` attribute.
src/ProbabilisticProgramming/Independence.dfy(77,17): IsIndepImpliesMeasurableNat: Declaration has explicit `{:axiom}` attribute.
src/ProbabilisticProgramming/Independence.dfy(82,17): IsIndepImpliesIsIndepFunction: Declaration has explicit `{:axiom}` attribute.
src/ProbabilisticProgramming/Independence.dfy(87,17): CoinIsIndep: Declaration has explicit `{:axiom}` attribute.
src/ProbabilisticProgramming/Independence.dfy(91,17): ReturnIsIndep: Declaration has explicit `{:axiom}` attribute.
src/ProbabilisticProgramming/Loops.dfy(361,17): EnsureWhileTerminates: Declaration has explicit `{:axiom}` attribute.
src/ProbabilisticProgramming/Loops.dfy(371,17): UntilProbabilityFraction: Declaration has explicit `{:axiom}` attribute.
src/ProbabilisticProgramming/Loops.dfy(404,4): EnsureUntilTerminatesAndForAll: Definition has `assume {:axiom}` statement in body.
src/ProbabilisticProgramming/Loops.dfy(427,4): WhileIsIndep: Definition has `assume {:axiom}` statement in body.
src/ProbabilisticProgramming/Independence.dfy(60,17): IsIndepImpliesIsIndepFunction: Declaration has explicit `{:axiom}` attribute.
src/ProbabilisticProgramming/Independence.dfy(64,17): MapIsIndep: Declaration has explicit `{:axiom}` attribute.
src/ProbabilisticProgramming/RandomSource.dfy(50,17): ProbIsProbabilityMeasure: Declaration has explicit `{:axiom}` attribute.
src/ProbabilisticProgramming/RandomSource.dfy(54,17): CoinHasProbOneHalf: Declaration has explicit `{:axiom}` attribute.
src/ProbabilisticProgramming/RandomSource.dfy(61,17): MeasureHeadDrop: Declaration has explicit `{:axiom}` attribute.
src/ProbabilisticProgramming/RandomSource.dfy(67,17): TailIsMeasurePreserving: Declaration has explicit `{:axiom}` attribute.
2 changes: 1 addition & 1 deletion src/DafnyVMC.dfy
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ module {:extern "DafnyVMCPart"} DafnyVMC {

method UniformPowerOfTwoSample(n: nat) returns (u: nat)
requires n >= 1
modifies this
modifies `s
ensures UniformPowerOfTwo.Model.Sample(n)(old(s)) == Monad.Result(u, s)
{
u := DafnyVMCPartMaterial.Random.ExternUniformPowerOfTwoSample(n);
Expand Down
2 changes: 1 addition & 1 deletion src/DafnyVMCTrait.dfy
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ module DafnyVMCTrait {

import opened Pos

trait {:termination false} RandomTrait extends UniformPowerOfTwo.Implementation.Trait, FisherYates.Implementation.Trait {
trait {:termination false} RandomTrait extends UniformPowerOfTwo.Interface.Trait, FisherYates.Implementation.Trait {

method {:verify false} UniformSample (n: pos)
returns (o: nat)
Expand Down
12 changes: 12 additions & 0 deletions src/Distributions/Bitstream/Interface.dfy
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
/*******************************************************************************
* Copyright by the contributors to the Dafny Project
* SPDX-License-Identifier: MIT
*******************************************************************************/

module Bitstream.Interface {
import Rand

trait {:termination false} Trait {
ghost var s: Rand.Bitstream
}
}
3 changes: 1 addition & 2 deletions src/Distributions/Coin/Implementation.dfy
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,8 @@ module Coin.Implementation {
{
var x := UniformPowerOfTwoSample(2);
b := if x == 1 then true else false;
reveal UniformPowerOfTwo.Model.Sample();
}

}

}
}
2 changes: 1 addition & 1 deletion src/Distributions/Coin/Interface.dfy
Original file line number Diff line number Diff line change
Expand Up @@ -16,4 +16,4 @@ module Coin.Interface {
ensures Model.Sample(old(s)) == Monad.Result(b, s)

}
}
}
3 changes: 0 additions & 3 deletions src/Distributions/Uniform/Correctness.dfy
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,7 @@ module Uniform.Correctness {
import Monad
import Independence
import Rand
import Quantifier
import Loops
import Measures
import UniformPowerOfTwo
import Model

/************
Expand Down
5 changes: 2 additions & 3 deletions src/Distributions/Uniform/Interface.dfy
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,11 @@

module Uniform.Interface {
import Monad
import Coin
import Model
import UniformPowerOfTwo
import Pos
import Bitstream

trait {:termination false} Trait extends UniformPowerOfTwo.Interface.Trait {
trait {:termination false} Trait extends Bitstream.Interface.Trait {

method UniformSample(n: Pos.pos) returns (u: nat)
modifies `s
Expand Down
2 changes: 0 additions & 2 deletions src/Distributions/Uniform/Model.dfy
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,8 @@ module Uniform.Model {
import Measures
import NatArith
import Rand
import Quantifier
import Monad
import Independence
import Loops
import UniformPowerOfTwo

/************
Expand Down
Loading

0 comments on commit 87b8829

Please sign in to comment.