aboutsummaryrefslogtreecommitdiff
path: root/gcc/ada/switch-c.adb
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/ada/switch-c.adb')
-rw-r--r--gcc/ada/switch-c.adb14
1 files changed, 14 insertions, 0 deletions
diff --git a/gcc/ada/switch-c.adb b/gcc/ada/switch-c.adb
index 0da8f66..a7299ab 100644
--- a/gcc/ada/switch-c.adb
+++ b/gcc/ada/switch-c.adb
@@ -279,6 +279,13 @@ package body Switch.C is
when 'D' =>
Ptr := Ptr + 1;
+ -- Scan option integer line limit value
+
+ if Ptr <= Max and then Switch_Chars (Ptr) in '0' .. '9' then
+ Scan_Nat (Switch_Chars, Max, Ptr, Sprint_Line_Limit, 'D');
+ Sprint_Line_Limit := Nat'Max (Sprint_Line_Limit, 40);
+ end if;
+
-- Note: -gnatD also sets -gnatx (to turn off cross-reference
-- generation in the ali file) since otherwise this generation
-- gets confused by the "wrong" Sloc values put in the tree.
@@ -522,6 +529,13 @@ package body Switch.C is
Ptr := Ptr + 1;
Print_Generated_Code := True;
+ -- Scan option integer line limit value
+
+ if Ptr <= Max and then Switch_Chars (Ptr) in '0' .. '9' then
+ Scan_Nat (Switch_Chars, Max, Ptr, Sprint_Line_Limit, 'G');
+ Sprint_Line_Limit := Nat'Max (Sprint_Line_Limit, 40);
+ end if;
+
-- Processing for h switch
when 'h' =>