]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
[Ada] Emit specific SCOs for decisions of quantified expressions
authorMatthieu Eyraud <eyraud@adacore.com>
Fri, 2 Jul 2021 12:37:55 +0000 (14:37 +0200)
committerPierre-Marie de Rodat <derodat@adacore.com>
Mon, 4 Oct 2021 08:45:09 +0000 (08:45 +0000)
gcc/ada/

* scos.ads: Extend the documentation.
* par_sco.adb (Process_Decisions): Emit specific SCOs for
quantified expressions.

gcc/ada/par_sco.adb
gcc/ada/scos.ads

index 9720e4764a55204797d7d45461278d2870a899d8..09e4d500249bdb7d4aed0a8fb65d8ac157f5d106 100644 (file)
@@ -827,6 +827,14 @@ package body Par_SCO is
                   return Skip;
                end;
 
+            when N_Quantified_Expression =>
+               declare
+                  Cond : constant Node_Id := Condition (N);
+               begin
+                  Process_Decisions (Cond, 'W', Pragma_Sloc);
+                  return Skip;
+               end;
+
             --  All other cases, continue scan
 
             when others =>
index d8e88dd1ab033273d0fe8ee88837d58e50c7c4f2..cdac5521e993f167ed665310e0f0e9ae24409f94 100644 (file)
@@ -257,7 +257,7 @@ package SCOs is
    --      I       decision in IF statement or if expression
    --      P       decision in pragma Assert / Check / Pre/Post_Condition
    --      A[name] decision in aspect Pre/Post (aspect name optional)
-   --      W       decision in WHILE iteration scheme
+   --      W       decision in WHILE iteration scheme or quantified expression
    --      X       decision in some other expression context
 
    --    For E, G, I, P, W, sloc is the source location of the EXIT, ENTRY, IF,