sinput.ads, sinput.adb (Sloc_Range): Applies to all nodes, formal changed from Expr...
authorRobert Dewar <dewar@adacore.com>
Wed, 27 Jan 2010 11:37:20 +0000 (11:37 +0000)
committerArnaud Charlet <charlet@gcc.gnu.org>
Wed, 27 Jan 2010 11:37:20 +0000 (12:37 +0100)
2010-01-27  Robert Dewar  <dewar@adacore.com>

* sinput.ads, sinput.adb (Sloc_Range): Applies to all nodes, formal
changed from Expr to N.

From-SVN: r156278

gcc/ada/ChangeLog
gcc/ada/sinput.adb
gcc/ada/sinput.ads

index 3cc8b528c7c4ceedf018c812dad34ca83da6b5e6..814961b7a31ac5fab91845c4715c4954c04d0877 100644 (file)
@@ -1,3 +1,8 @@
+2010-01-27  Robert Dewar  <dewar@adacore.com>
+
+       * sinput.ads, sinput.adb (Sloc_Range): Applies to all nodes, formal
+       changed from Expr to N.
+
 2010-01-26  Thomas Quinot  <quinot@adacore.com>
 
        * gnat_ugn.texi: Adjust documentation of -gnatz switches.
index 9f5637d0a32c39334993d8fefd7b69972c6b1060..c2af505e5baa8280ef0a5cbb3a1b4d5135f6226d 100644 (file)
@@ -693,10 +693,10 @@ package body Sinput is
    -- Sloc_Range --
    ----------------
 
-   procedure Sloc_Range (Expr : Node_Id; Min, Max : out Source_Ptr) is
+   procedure Sloc_Range (N : Node_Id; Min, Max : out Source_Ptr) is
 
       function Process (N : Node_Id) return Traverse_Result;
-      --  Process function for traversing the expression tree
+      --  Process function for traversing the node tree
 
       procedure Traverse is new Traverse_Proc (Process);
 
@@ -722,9 +722,9 @@ package body Sinput is
    --  Start of processing for Sloc_Range
 
    begin
-      Min := Sloc (Expr);
-      Max := Sloc (Expr);
-      Traverse (Expr);
+      Min := Sloc (N);
+      Max := Sloc (N);
+      Traverse (N);
    end Sloc_Range;
 
    -------------------
index 945d26e7d4a9de6466c5faaed3d16764a780310c..4f235162c8f68470d21bae30fed822154e6d2afe 100644 (file)
@@ -595,10 +595,10 @@ package Sinput is
    --  makes sure that the lines table for the current source file has an
    --  appropriate entry for the start of the new physical line.
 
-   procedure Sloc_Range (Expr : Node_Id; Min, Max : out Source_Ptr);
-   --  Given a node for a subexpression, returns the minimum and maximum source
-   --  locations of any node in the expression subtree. This is not quite the
-   --  same as the locations of the first and last token in the expresion
+   procedure Sloc_Range (N : Node_Id; Min, Max : out Source_Ptr);
+   --  Given a node, returns the minimum and maximum source locations of any
+   --  node in the syntactic subtree for the node. This is not quite the same
+   --  as the locations of the first and last token in the node construct
    --  because parentheses at the outer level do not have a recorded Sloc.
    --
    --  Note: if the tree for the expression contains no "real" Sloc values,