aboutsummaryrefslogtreecommitdiff
path: root/libcpp
diff options
context:
space:
mode:
authorYannick Moy <moy@adacore.com>2021-11-19 10:34:21 +0100
committerPierre-Marie de Rodat <derodat@adacore.com>2021-12-02 16:26:19 +0000
commit40b180995ab1b2b6748d5eb217d8fbfd21b4a51b (patch)
tree22b9957fc7805dda51811c7b8ec3a37302ca5dec /libcpp
parent6df3ec0e7e070fec09e0cd1f8064300cb3a1d402 (diff)
downloadgcc-40b180995ab1b2b6748d5eb217d8fbfd21b4a51b.zip
gcc-40b180995ab1b2b6748d5eb217d8fbfd21b4a51b.tar.gz
gcc-40b180995ab1b2b6748d5eb217d8fbfd21b4a51b.tar.bz2
[Ada] Proof of System.Val_Util utilities for 'Value support
gcc/ada/ * libgnat/s-valboo.adb (First_Non_Space_Ghost): Move to utilities. (Value_Boolean): Prefix call to First_Non_Space_Ghost. * libgnat/s-valboo.ads (First_Non_Space_Ghost): Move to utilities. (Is_Boolean_Image_Ghost, Value_Boolean): Prefix call to First_Non_Space_Ghost. * libgnat/s-valuer.adb (Scan_Raw_Real): Adapt to change of function Scan_Exponent to procedure. * libgnat/s-valueu.adb (Scan_Raw_Unsigned): Adapt to change of function Scan_Exponent to procedure. * libgnat/s-valuti.adb (First_Non_Space_Ghost): Function moved here. (Last_Number_Ghost): New ghost query function. (Scan_Exponent): Change function with side-effects into procedure, to mark in SPARK. Prove procedure wrt contract. Change type of local P to avoid possible range check failure (it is not known whether this can be activated by callers). (Scan_Plus_Sign, Scan_Sign): Change type of local P to avoid possible range check failure. Add loop invariants and assertions for proof. (Scan_Trailing_Blanks): Add loop invariant. (Scan_Underscore): Remove SPARK_Mode Off. * libgnat/s-valuti.ads (First_Non_Space_Ghost): Function moved here. (Last_Number_Ghost, Only_Number_Ghost, Is_Natural_Format_Ghost, Scan_Natural_Ghost): New ghost query functions. (Scan_Plus_Sign, Scan_Sign, Scan_Exponent, Scan_Trailing_Blanks, Scan_Underscore): Add functional contracts.
Diffstat (limited to 'libcpp')
0 files changed, 0 insertions, 0 deletions