[Ada] Make -gnatRj output strictly conforming JSON
This changes the -gnatRj output from a concatenation of entities to an
array of entities, thus making it strictly conforming JSON and easier to
be parsed by means of GNATColl or Python.
2019-07-09 Eric Botcazou <ebotcazou@adacore.com>
gcc/ada/
* repinfo.ads (JSON format): Adjust.
* repinfo.adb (Need_Blank_Line): Rename to...
(Need_Separator): ...this.
(Blank_Line): Rename to...
(Write_Separator): ...this and add JSON specific handling.
(List_Array_Info): Adjust to above renaming.
(List_Object_Info): Likewise.
(List_Record_Info): Likewise.
(List_Subprogram_Info): Likewise.
(List_Type_Info): Likewise.
(List_Entities): Do not set Need_Blank_Line.
(List_Rep_Info): Set Need_Separator and add JSON specific
handling. Output a single JSON stream in the normal case.
From-SVN: r273265