Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
F
frama-c
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Container Registry
Model registry
Monitor
Incidents
Analyze
Value stream analytics
Contributor 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
pub
frama-c
Commits
bbdfccc9
Commit
bbdfccc9
authored
1 year ago
by
Jan Rochel
Browse files
Options
Downloads
Patches
Plain Diff
[e-acsl] Translate_term: inline Extlib.flatten
parent
1c7649c3
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/plugins/e-acsl/src/code_generator/translate_terms.ml
+26
-27
26 additions, 27 deletions
src/plugins/e-acsl/src/code_generator/translate_terms.ml
with
26 additions
and
27 deletions
src/plugins/e-acsl/src/code_generator/translate_terms.ml
+
26
−
27
View file @
bbdfccc9
...
@@ -871,37 +871,36 @@ and to_exp ~adata ?inplace kf env t =
...
@@ -871,37 +871,36 @@ and to_exp ~adata ?inplace kf env t =
(
Env
.
Logic_env
.
get_profile
env
);
(
Env
.
Logic_env
.
get_profile
env
);
let
logic_env
=
Env
.
Logic_env
.
get
env
in
let
logic_env
=
Env
.
Logic_env
.
get
env
in
let
t
=
Logic_normalizer
.
get_term
t
in
let
t
=
Logic_normalizer
.
get_term
t
in
let
(
rexp
,
_
,
_
)
as
result
=
let
((
rexp
,
_
)
,
_
)
as
result
=
Extlib
.
flatten
Env
.
with_params_and_result
(
Env
.
with_params_and_result
~
rte
:
false
~
rte
:
false
~
f
:
(
fun
env
->
~
f
:
(
fun
env
->
let
e
,
adata
,
env
,
sty
,
name
=
let
e
,
adata
,
env
,
sty
,
name
=
context_insensitive_term_to_exp
?
inplace
~
adata
kf
env
t
context_insensitive_term_to_exp
?
inplace
~
adata
kf
env
t
in
in
let
env
=
let
env
=
if
generate_rte
then
!
translate_rte_exp_ref
kf
env
e
else
env
if
generate_rte
then
!
translate_rte_exp_ref
kf
env
e
else
env
in
in
let
cast
=
Typing
.
get_cast
~
logic_env
t
in
let
cast
=
Typing
.
get_cast
~
logic_env
t
in
let
name
=
if
name
=
""
then
None
else
Some
name
in
let
name
=
if
name
=
""
then
None
else
Some
name
in
Extlib
.
nest
Extlib
.
nest
adata
adata
(
Typed_number
.
add_cast
(
Typed_number
.
add_cast
~
loc
:
t
.
term_loc
~
loc
:
t
.
term_loc
?
name
?
name
env
env
kf
kf
cast
cast
sty
sty
(
Some
t
)
(
Some
t
)
e
)
e
)
)
)
env
env
)
in
in
Options
.
debug
~
dkey
~
level
:
4
"to_exp %a {%a} %a = %a"
Options
.
debug
~
dkey
~
level
:
4
"to_exp %a {%a} %a = %a"
Kernel_function
.
pretty
kf
Profile
.
pretty
(
Env
.
Logic_env
.
get_profile
env
)
Kernel_function
.
pretty
kf
Profile
.
pretty
(
Env
.
Logic_env
.
get_profile
env
)
Printer
.
pp_term
t
Printer
.
pp_exp
rexp
;
Printer
.
pp_term
t
Printer
.
pp_exp
rexp
;
result
Extlib
.
flatten
result
let
term_to_exp_without_inplace
~
adata
kf
env
t
=
to_exp
~
adata
kf
env
t
let
term_to_exp_without_inplace
~
adata
kf
env
t
=
to_exp
~
adata
kf
env
t
...
...
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