@@ -34,14 +34,13 @@ package body Instrument.C_Utils is
34
34
-- --------
35
35
36
36
function Sloc (Loc : Source_Location_T) return Source_Location is
37
- Line : aliased Interfaces.C.unsigned;
38
- Column : aliased Interfaces.C.unsigned;
37
+ Line, Column : aliased Interfaces.C.unsigned;
39
38
begin
40
39
Get_Presumed_Location (Location => Loc,
41
40
Filename => null ,
42
41
Line => Line'Access ,
43
42
Column => Column'Access );
44
- return (Line => Langkit_Support.Slocs.Line_Number (Line),
43
+ return (Line => Langkit_Support.Slocs.Line_Number (Line),
45
44
Column => Langkit_Support.Slocs.Column_Number (Column));
46
45
end Sloc ;
47
46
@@ -50,16 +49,15 @@ package body Instrument.C_Utils is
50
49
-- --------------
51
50
52
51
function Start_Sloc (N : Cursor_T) return Source_Location is
53
- Line : aliased Interfaces.C.unsigned;
54
- Column : aliased Interfaces.C.unsigned;
55
- Loc : constant Source_Location_T :=
52
+ Line, Column : aliased Interfaces.C.unsigned;
53
+ Loc : constant Source_Location_T :=
56
54
Get_Range_Start (Get_Cursor_Extent (N));
57
55
begin
58
56
Get_Presumed_Location (Location => Loc,
59
57
Filename => null ,
60
58
Line => Line'Access ,
61
59
Column => Column'Access );
62
- return (Line => Langkit_Support.Slocs.Line_Number (Line),
60
+ return (Line => Langkit_Support.Slocs.Line_Number (Line),
63
61
Column => Langkit_Support.Slocs.Column_Number (Column));
64
62
end Start_Sloc ;
65
63
@@ -68,9 +66,8 @@ package body Instrument.C_Utils is
68
66
-- ------------
69
67
70
68
function End_Sloc (N : Cursor_T) return Source_Location is
71
- Line : aliased Interfaces.C.unsigned;
72
- Column : aliased Interfaces.C.unsigned;
73
- Loc : Source_Location_T :=
69
+ Line, Column : aliased Interfaces.C.unsigned;
70
+ Loc : Source_Location_T :=
74
71
Get_Range_End (Get_Cursor_Extent (N));
75
72
begin
76
73
if Is_Macro_Location (Loc) then
0 commit comments