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
Snippets
Deploy
Releases
Package registry
Container Registry
Model registry
Operate
Terraform modules
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
Charles Southerland
frama-c
Commits
f64db051
Commit
f64db051
authored
5 years ago
by
Julien Signoles
Browse files
Options
Downloads
Patches
Plain Diff
[e-acsl:archi] better error message
parent
e76a0b77
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/libraries/functions.ml
+10
-3
10 additions, 3 deletions
src/plugins/e-acsl/src/libraries/functions.ml
with
10 additions
and
3 deletions
src/plugins/e-acsl/src/libraries/functions.ml
+
10
−
3
View file @
f64db051
...
...
@@ -181,7 +181,7 @@ module Libc = struct
|
FLongDouble
->
"E"
(* [long double] *)
in
(* get a character representing a pointer type *)
let
get_pkind_str
ty
=
match
ty
with
let
get_pkind_str
a
ty
=
match
ty
with
|
TInt
(
IChar
,_
)
|
TInt
(
ISChar
,_
)
->
"s"
(* [char*] *)
|
TInt
(
IUChar
,_
)
->
"S"
(* [unsigned char*] *)
|
TInt
(
IShort
,_
)
->
"q"
(* [short*] *)
...
...
@@ -194,8 +194,9 @@ module Libc = struct
|
TInt
(
IULongLong
,_
)
->
"W"
(* [unsigned long int*] *)
|
TVoid
_
->
"p"
(* [void*] *)
|
_
->
Options
.
fatal
"
U
nexpected argument type in printf: %a
@."
Options
.
fatal
"
u
nexpected argument type in printf:
type %a of arg
%a@."
Printer
.
pp_typ
ty
Printer
.
pp_exp
a
in
let
exps
=
drop
(
printf_fmt_position
fn
)
args
in
let
param_str
=
...
...
@@ -203,7 +204,7 @@ module Libc = struct
(
fun
exp
acc
->
match
Cil
.
unrollType
(
Cil
.
typeOf
exp
)
with
|
TInt
(
k
,
_
)
->
get_ikind_str
k
^
acc
|
TFloat
(
k
,
_
)
->
get_fkind_str
k
^
acc
|
TPtr
(
ty
,
_
)
->
get_pkind_str
(
Cil
.
unrollType
ty
)
^
acc
|
TPtr
(
ty
,
_
)
->
get_pkind_str
exp
(
Cil
.
unrollType
ty
)
^
acc
|
TVoid
_
|
TArray
_
|
TFun
_
|
TNamed
_
|
TComp
_
|
TEnum
_
|
TBuiltin_va_list
_
->
assert
false
)
exps
...
...
@@ -244,3 +245,9 @@ let instrument kf =
Options
.
Instrument
.
mem
gen_kf
with
Not_found
->
false
))
(*
Local Variables:
compile-command: "make -C ../../../../.."
End:
*)
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