summaryrefslogtreecommitdiff
path: root/gcc/ada/par-ch10.adb
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/ada/par-ch10.adb')
-rw-r--r--gcc/ada/par-ch10.adb16
1 files changed, 12 insertions, 4 deletions
diff --git a/gcc/ada/par-ch10.adb b/gcc/ada/par-ch10.adb
index 985d9e328cc..97d4c362daa 100644
--- a/gcc/ada/par-ch10.adb
+++ b/gcc/ada/par-ch10.adb
@@ -665,11 +665,19 @@ package body Ch10 is
-- Skip tokens to end of file, so that the -gnatl listing
-- will be complete in this situation, but no need to parse
- -- the remaining units.
+ -- the remaining units; no style checking either.
- while Token /= Tok_EOF loop
- Scan;
- end loop;
+ declare
+ Save_Style_Check : constant Boolean := Style_Check;
+ begin
+ Style_Check := False;
+
+ while Token /= Tok_EOF loop
+ Scan;
+ end loop;
+
+ Style_Check := Save_Style_Check;
+ end;
return Comp_Unit_Node;