Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
I
inox
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
LARA
inox
Commits
5a6ac7f4
Commit
5a6ac7f4
authored
9 years ago
by
Etienne Kneuss
Browse files
Options
Downloads
Patches
Plain Diff
Annotate proof DSL as @library
parent
7521bb50
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
library/proof/Internal.scala
+2
-0
2 additions, 0 deletions
library/proof/Internal.scala
library/proof/package.scala
+7
-0
7 additions, 0 deletions
library/proof/package.scala
with
9 additions
and
0 deletions
library/proof/Internal.scala
+
2
−
0
View file @
5a6ac7f4
...
...
@@ -2,8 +2,10 @@
package
leon.proof
import
leon.lang._
import
leon.annotation._
/** Internal helper classes and methods for the 'proof' package. */
@library
object
Internal
{
/*** Helper classes for relational reasoning ***/
...
...
This diff is collapsed.
Click to expand it.
library/proof/package.scala
+
7
−
0
View file @
5a6ac7f4
...
...
@@ -9,6 +9,7 @@ import leon.proof.Internal._
package
object
proof
{
@library
case
class
ProofOps
(
prop
:
Boolean
)
{
def
because
(
proof
:
Boolean
)
:
Boolean
=
proof
&&
prop
def
neverHolds
:
Boolean
=
{
...
...
@@ -17,13 +18,17 @@ package object proof {
}
}
@library
implicit
def
boolean2ProofOps
(
prop
:
Boolean
)
:
ProofOps
=
ProofOps
(
prop
)
@library
def
trivial
:
Boolean
=
true
@library
def
by
(
proof
:
Boolean
)(
prop
:
Boolean
)
:
Boolean
=
proof
&&
prop
@library
def
check
(
prop
:
Boolean
)
:
Boolean
=
{
require
(
prop
)
prop
...
...
@@ -39,6 +44,7 @@ package object proof {
* x
* }.qed
*/
@library
case
class
RelReasoning
[
A
](
x
:
A
,
prop
:
Boolean
)
{
def
^^
[
B
](
r
:
(
A
,
B
)
=>
Boolean
)
:
WithRel
[
A
,
B
]
=
WithRel
(
x
,
r
,
prop
)
...
...
@@ -52,6 +58,7 @@ package object proof {
def
qed
:
Boolean
=
prop
}
@library
implicit
def
any2RelReasoning
[
A
](
x
:
A
)
:
RelReasoning
[
A
]
=
RelReasoning
(
x
,
true
)
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment