[Ada] Simplify iteration over components

Pierre-Marie de Rodat derodat@adacore.com
Fri Jun 5 12:23:38 GMT 2020


Instead of iterating with First_Entity/Next_Entity and then detecting
components with Ekind, it feels simpler to iterate with First_Component/
Next_Component.

Tested on x86_64-pc-linux-gnu, committed on trunk

2020-06-05  Piotr Trojanek  <trojanek@adacore.com>

gcc/ada/

	* einfo.adb: Minor reformatting.
	* sem_util.adb (Has_Full_Default_Initialization,
	Is_Partially_Initialized_Type, Caller_Known_Size_Record,
	Large_Max_Size_Mutable): Iterate with
	First_Component/Next_Component; rename Ent to Comp.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: patch.diff
Type: text/x-diff
Size: 8438 bytes
Desc: not available
URL: <https://gcc.gnu.org/pipermail/gcc-patches/attachments/20200605/2fc23fd1/attachment-0001.bin>


More information about the Gcc-patches mailing list