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
c95c2dd3
Commit
c95c2dd3
authored
1 year ago
by
Thibault Martin
Browse files
Options
Downloads
Patches
Plain Diff
Do not display ghost code in proto/fun args when empty
parent
d329832e
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/kernel_services/ast_printing/cprint.ml
+6
-0
6 additions, 0 deletions
src/kernel_services/ast_printing/cprint.ml
with
6 additions
and
0 deletions
src/kernel_services/ast_printing/cprint.ml
+
6
−
0
View file @
c95c2dd3
...
@@ -253,6 +253,9 @@ and print_decl (n: string) fmt = function
...
@@ -253,6 +253,9 @@ and print_decl (n: string) fmt = function
|
ARRAY
(
d
,
al
,
e
)
->
|
ARRAY
(
d
,
al
,
e
)
->
fprintf
fmt
"%a[@[%a%a@]]"
fprintf
fmt
"%a[@[%a%a@]]"
(
print_decl
n
)
d
print_attributes
al
print_expression
e
(
print_decl
n
)
d
print_attributes
al
print_expression
e
|
PROTO
(
d
,
args
,
[]
,
isva
)
->
fprintf
fmt
"@[%a@;(%a) @]"
(
print_decl
n
)
d
print_params
(
args
,
isva
)
|
PROTO
(
d
,
args
,
ghost_args
,
isva
)
->
|
PROTO
(
d
,
args
,
ghost_args
,
isva
)
->
fprintf
fmt
"@[%a@;(%a) /*@@@ ghost (%a) */ @]"
fprintf
fmt
"@[%a@;(%a) /*@@@ ghost (%a) */ @]"
(
print_decl
n
)
d
print_params
(
args
,
isva
)
print_params
(
ghost_args
,
false
)
(
print_decl
n
)
d
print_params
(
args
,
isva
)
print_params
(
ghost_args
,
false
)
...
@@ -380,6 +383,9 @@ and print_expression_level (lvl: int) fmt (exp : expression) =
...
@@ -380,6 +383,9 @@ and print_expression_level (lvl: int) fmt (exp : expression) =
[
arg
;
{
expr_node
=
TYPE_SIZEOF
(
bt
,
dt
)
}
]
,
_
)
->
[
arg
;
{
expr_node
=
TYPE_SIZEOF
(
bt
,
dt
)
}
]
,
_
)
->
fprintf
fmt
"__builtin_va_arg(@[%a,@ %a@])"
fprintf
fmt
"__builtin_va_arg(@[%a,@ %a@])"
(
print_expression_level
0
)
arg
print_onlytype
(
bt
,
dt
)
(
print_expression_level
0
)
arg
print_onlytype
(
bt
,
dt
)
|
CALL
(
exp
,
args
,
[]
)
->
fprintf
fmt
"%a(@[@;%a@])"
print_expression
exp
print_comma_exps
args
|
CALL
(
exp
,
args
,
ghost_args
)
->
|
CALL
(
exp
,
args
,
ghost_args
)
->
fprintf
fmt
"%a(@[@;%a@]) /*@@@ ghost (@[@;%a@]) */"
fprintf
fmt
"%a(@[@;%a@]) /*@@@ ghost (@[@;%a@]) */"
print_expression
exp
print_comma_exps
args
print_comma_exps
ghost_args
print_expression
exp
print_comma_exps
args
print_comma_exps
ghost_args
...
...
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