Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
why3
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
125
Issues
125
List
Boards
Labels
Service Desk
Milestones
Merge Requests
16
Merge Requests
16
Operations
Operations
Incidents
Packages & Registries
Packages & Registries
Container Registry
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Why3
why3
Commits
f428b633
Commit
f428b633
authored
Jan 31, 2019
by
François Bobot
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Adds Peano.Int63 in ocaml64 driver
and renames to_int63 into to_int63_partial
parent
06c4cb7c
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
15 additions
and
0 deletions
+15
-0
drivers/ocaml64.drv
drivers/ocaml64.drv
+6
-0
stdlib/mach/peano.mlw
stdlib/mach/peano.mlw
+9
-0
No files found.
drivers/ocaml64.drv
View file @
f428b633
...
...
@@ -302,6 +302,12 @@ module mach.peano.MinMax
syntax val min "min %1 %2" prec 4 3 3
end
module mach.peano.Int63
syntax val defensive_to_int63 "%1"
syntax val to_int63 "%1"
syntax val of_int63 "%1"
end
module mach.onetime.OneTime
syntax type t "int"
syntax val to_int "Z.of_int %1" prec 4 3
...
...
stdlib/mach/peano.mlw
View file @
f428b633
...
...
@@ -102,10 +102,19 @@ module MinMax
end
module Int63
use int.Int
use mach.int.Int63
use Peano
val defensive_to_int63 (x:t) : int63
requires { Int63.in_bounds x.v }
ensures { result = x.v }
val partial to_int63 (x:t) : int63
ensures { result = x.v }
val of_int63 (x:int63) (low high: t) : t
requires { low.v <= x <= high.v }
ensures { result.v = x }
end
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment