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
120
Issues
120
List
Boards
Labels
Service Desk
Milestones
Merge Requests
18
Merge Requests
18
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
95953af5
Commit
95953af5
authored
May 16, 2017
by
Mário Pereira
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Refinement of top-level constants.
parent
7beca011
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
3 deletions
+6
-3
src/mlw/pmodule.ml
src/mlw/pmodule.ml
+6
-3
No files found.
src/mlw/pmodule.ml
View file @
95953af5
...
...
@@ -935,15 +935,18 @@ let clone_pdecl inst cl uc d = match d.pd_node with
let
add
uc
d
=
add_pdecl
~
warn
:
false
~
vc
:
false
uc
d
in
List
.
fold_left
add
uc
(
create_type_decl
tdl
)
|
PDlet
(
LDsym
(
rs
,
c
))
when
Mrs
.
mem
rs
inst
.
mi_rs
->
(* refine only [val] symbols *)
if
c
.
c_node
<>
Cany
then
raise
(
BadInstance
rs
.
rs_name
);
(* refine only [val] symbols *)
let
cty
=
match
c
.
c_node
with
(* cty for [val constant] is not c.c_cty *)
|
Cany
->
c
.
c_cty
|
Cfun
{
e_node
=
Eexec
({
c_node
=
Cany
}
,
cty
)}
->
cty
|
_
->
raise
(
BadInstance
rs
.
rs_name
)
in
let
kind
=
match
rs
.
rs_logic
with
|
RLnone
->
RKnone
|
RLpv
_
->
raise
(
BadInstance
rs
.
rs_name
)
|
RLls
ls
when
ls
.
ls_value
=
None
->
RKpred
|
RLls
_
->
RKfunc
|
RLlemma
->
RKlemma
in
let
cty
=
clone_cty
cl
(
sm_of_cl
cl
)
c
.
c_c
ty
in
let
cty
=
clone_cty
cl
(
sm_of_cl
cl
)
cty
in
let
rs'
=
Mrs
.
find
rs
inst
.
mi_rs
in
(* arity and types will be checked when refinement VC is generated *)
begin
match
rs
.
rs_logic
,
rs'
.
rs_logic
with
...
...
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