Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
10
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Open sidebar
Why3
why3
Commits
75779176
Commit
75779176
authored
Jun 07, 2011
by
Andrei Paskevich
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
remove "built-in" propositions early
also preserve proposition names in split_premise when possible
parent
1e402289
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
9 additions
and
6 deletions
+9
-6
src/transform/eliminate_definition.ml
src/transform/eliminate_definition.ml
+5
-3
src/transform/split_goal.ml
src/transform/split_goal.ml
+4
-3
No files found.
src/transform/eliminate_definition.ml
View file @
75779176
...
...
@@ -32,7 +32,7 @@ let add_id q (ld,id) = function
|
ls
,
_
when
Sls
.
mem
ls
q
->
(
ls
,
None
)
::
ld
,
id
|
d
->
ld
,
d
::
id
let
elim
q
d
=
match
d
.
d_node
with
let
elim
q
spr
d
=
match
d
.
d_node
with
|
Dlogic
l
->
[
create_logic_decl
(
List
.
map
(
add_ld
q
)
l
)]
|
Dind
l
->
...
...
@@ -40,11 +40,13 @@ let elim q d = match d.d_node with
let
ld
=
if
ld
=
[]
then
[]
else
[
create_logic_decl
(
List
.
rev
ld
)]
in
let
id
=
if
id
=
[]
then
[]
else
[
create_ind_decl
(
List
.
rev
id
)]
in
ld
@
id
|
Dprop
(
Paxiom
,
pr
,_
)
when
Spr
.
mem
pr
spr
->
[]
|
_
->
[
d
]
let
eliminate_builtin
=
Trans
.
on_tagged_ls
Printer
.
meta_syntax_logic
(
fun
rem_ls
->
Trans
.
decl
(
elim
rem_ls
)
None
)
Trans
.
on_tagged_ls
Printer
.
meta_syntax_logic
(
fun
rem_ls
->
Trans
.
on_tagged_pr
Printer
.
meta_remove_prop
(
fun
rem_pr
->
Trans
.
decl
(
elim
rem_ls
rem_pr
)
None
))
let
()
=
Trans
.
register_transform
"eliminate_builtin"
eliminate_builtin
...
...
src/transform/split_goal.ml
View file @
75779176
...
...
@@ -141,9 +141,10 @@ let split_goal ro pr f =
let
split_axiom
ro
pr
f
=
let
make_prop
f
=
let
pr
=
create_prsymbol
(
id_clone
pr
.
pr_name
)
in
create_prop_decl
Paxiom
pr
f
in
List
.
map
make_prop
(
split_pos
ro
[]
f
)
create_prop_decl
Paxiom
pr
f
in
match
split_pos
ro
[]
f
with
|
[
f
]
->
[
create_prop_decl
Paxiom
pr
f
]
|
fl
->
List
.
map
make_prop
fl
let
split_all
ro
d
=
match
d
.
d_node
with
|
Dprop
(
Pgoal
,
pr
,
f
)
->
split_goal
ro
pr
f
...
...
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