[Ada] Remove obsolete Is_For_Access_Subtype machinery
authorEric Botcazou <ebotcazou@adacore.com>
Mon, 22 Jul 2019 13:57:31 +0000 (13:57 +0000)
committerPierre-Marie de Rodat <pmderodat@gcc.gnu.org>
Mon, 22 Jul 2019 13:57:31 +0000 (13:57 +0000)
commitff9d220ede29dc7d0d40933733180f12cba54f17
tree3ec00f65614d971bf36399e4d7f7e854943b7a91
parent78e92e11d4a96e0cd2ee9d9b1af9382133cd11b5
[Ada] Remove obsolete Is_For_Access_Subtype machinery

This change removes the Is_For_Access_Subtype machinery from the
compiler.  This machinery was devised a long time ago to deal with a
peculiarity of the freezing for access-to-record subtypes but has been
degenerate for quite some time now and does not seem to serve any useful
purpose at this point.

Morever it has an annoying side effect whereby it causes Underlying_Type
to return the (unconstrained) base record type when invoked on the
designated record subtype, which is very problematic for GNATprove.

There should be no functional changes.

2019-07-22  Eric Botcazou  <ebotcazou@adacore.com>

gcc/ada/

* einfo.ads (Is_For_Access_Subtype): Delete.
(Set_Is_For_Access_Subtype): Likewise.
* einfo.adb (Is_For_Access_Subtype): Likewise.
(Set_Is_For_Access_Subtype): Likewise.
(Write_Entity_Flags): Do not write Is_For_Access_Subtype.
* exp_ch4.adb (Expand_N_Selected_Component): Do not deal with
it.
* exp_spark.adb (Expand_SPARK_N_Selected_Component): Likewise.
* sem_ch4.adb (Analyze_Explicit_Dereference): Likewise.
* sem_ch3.adb (Build_Discriminated_Subtype): Do not build a
special private subtype for access-to-record subtypes.

From-SVN: r273682
gcc/ada/ChangeLog
gcc/ada/einfo.adb
gcc/ada/einfo.ads
gcc/ada/exp_ch4.adb
gcc/ada/exp_spark.adb
gcc/ada/sem_ch3.adb
gcc/ada/sem_ch4.adb