aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorArnaud Charlet <charlet@adacore.com>2020-06-08 10:10:29 +0200
committerPierre-Marie de Rodat <derodat@adacore.com>2020-07-16 05:18:01 -0400
commit4211ccbbaed452f0363cf257b98f3236f442bfca (patch)
treec0d3062086e070e7ddc394e58a551ab76978884a
parentb5a05dc501aab8cd35122c98a161ddcb15facb9b (diff)
downloadgcc-4211ccbbaed452f0363cf257b98f3236f442bfca.zip
gcc-4211ccbbaed452f0363cf257b98f3236f442bfca.tar.gz
gcc-4211ccbbaed452f0363cf257b98f3236f442bfca.tar.bz2
[Ada] Disable Initialize_Scalars on runtime files
gcc/ada/ * frontend.adb: Disable Initialize_Scalars on runtime files.
-rw-r--r--gcc/ada/frontend.adb10
1 files changed, 10 insertions, 0 deletions
diff --git a/gcc/ada/frontend.adb b/gcc/ada/frontend.adb
index 0fd3424..b194741 100644
--- a/gcc/ada/frontend.adb
+++ b/gcc/ada/frontend.adb
@@ -382,6 +382,16 @@ begin
Warn_On_Non_Local_Exception := True;
end if;
+ -- Disable Initialize_Scalars for runtime files to avoid circular
+ -- dependencies.
+
+ if Initialize_Scalars
+ and then Fname.Is_Predefined_File_Name (File_Name (Main_Source_File))
+ then
+ Initialize_Scalars := False;
+ Init_Or_Norm_Scalars := Normalize_Scalars;
+ end if;
+
-- Now on to the semantics. Skip if in syntax only mode
if Operating_Mode /= Check_Syntax then