]> gcc.gnu.org Git - gcc.git/commit
[Ada] Contracts written for the Ada.Strings.Bounded library
authorPierre-Alexandre Bazin <bazin@adacore.com>
Fri, 2 Jul 2021 13:43:44 +0000 (15:43 +0200)
committerPierre-Marie de Rodat <derodat@adacore.com>
Wed, 22 Sep 2021 15:01:48 +0000 (15:01 +0000)
commit1647bc2a78b2182007f011ff0a43f872086ee512
tree670c2c96daf0797b252ea5787c729194d78a676a
parent5f325f5e6fd091f73f5be6ef30d27e22e4b59a74
[Ada] Contracts written for the Ada.Strings.Bounded library

gcc/ada/

* libgnat/a-strbou.adb: Turn SPARK_Mode on.
* libgnat/a-strbou.ads: Write contracts.
* libgnat/a-strfix.ads (Index): Fix grammar error in a comment.
* libgnat/a-strsea.ads (Index): Likewise.
* libgnat/a-strsup.adb: Rewrite the body to take into account
the new definition of Super_String using Relaxed_Initialization
and a predicate.
(Super_Replicate, Super_Translate, Times): Added loop
invariants, and ghost lemmas for Super_Replicate and Times.
(Super_Trim): Rewrite the body using search functions to
determine the cutting points.
(Super_Element, Super_Length, Super_Slice, Super_To_String):
Remove (now written as expression functions in a-strsup.ads).
* libgnat/a-strsup.ads: Added contracts.
(Super_Element, Super_Length, Super_Slice, Super_To_String):
Rewrite as expression functions.
gcc/ada/libgnat/a-strbou.adb
gcc/ada/libgnat/a-strbou.ads
gcc/ada/libgnat/a-strfix.ads
gcc/ada/libgnat/a-strsea.ads
gcc/ada/libgnat/a-strsup.adb
gcc/ada/libgnat/a-strsup.ads
This page took 0.073709 seconds and 6 git commands to generate.