Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Why3
why3
Commits
39f3a317
Commit
39f3a317
authored
Feb 09, 2011
by
Andrei Paskevich
Browse files
do not project the values of polymorphic functions
parent
83c4a93d
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/transform/encoding_enumeration.ml
View file @
39f3a317
...
...
@@ -41,12 +41,20 @@ let add_proj tenv ts =
Hts
.
add
tenv
.
projs
ts
fs
;
fs
let
proj
tenv
t
=
match
t
.
t_
ty
.
ty_node
with
let
proj
tenv
t
ty
=
match
ty
.
ty_node
with
|
Tyapp
(
ts
,_
)
when
Sts
.
mem
ts
tenv
.
enum
->
let
fs
=
Hts
.
find
tenv
.
projs
ts
in
t_app
fs
[
t
]
t
.
t_ty
|
_
->
t
let
proj
tenv
t
=
match
t
.
t_node
with
|
Tapp
(
ls
,_
)
->
proj
tenv
t
(
of_option
ls
.
ls_value
)
|
Tvar
_
|
Tconst
_
|
Teps
_
->
proj
tenv
t
t
.
t_ty
|
Tif
_
|
Tcase
_
|
Tlet
_
->
t
let
rec
rewrite_term
tenv
t
=
match
t
.
t_node
with
|
Tapp
(
fs
,
tl
)
->
let
pin
t
=
proj
tenv
(
rewrite_term
tenv
t
)
in
...
...
Write
Preview
Supports
Markdown
0%
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!
Cancel
Please
register
or
sign in
to comment